Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Lint error in VCP example #423

Merged
merged 1 commit into from
Feb 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
11 changes: 5 additions & 6 deletions examples/run_vcp_renderer.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,11 @@
import json

from bumble.core import AdvertisingData
from bumble.device import Device
from bumble.device import Device, AdvertisingParameters, AdvertisingEventProperties
from bumble.hci import (
CodecID,
CodingFormat,
OwnAddressType,
HCI_LE_Set_Extended_Advertising_Parameters_Command,
)
from bumble.profiles.bap import (
CodecSpecificCapabilities,
Expand Down Expand Up @@ -154,11 +153,11 @@ def on_volume_state(volume_setting: int, muted: int, change_counter: int):
+ csis.get_advertising_data()
)

await device.start_extended_advertising(
advertising_properties=(
HCI_LE_Set_Extended_Advertising_Parameters_Command.AdvertisingProperties.CONNECTABLE_ADVERTISING
await device.create_advertising_set(
advertising_parameters=AdvertisingParameters(
advertising_event_properties=AdvertisingEventProperties(),
own_address_type=OwnAddressType.PUBLIC,
),
own_address_type=OwnAddressType.PUBLIC,
advertising_data=advertising_data,
)

Expand Down
6 changes: 2 additions & 4 deletions tests/vcp_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,11 @@
# -----------------------------------------------------------------------------
# Imports
# -----------------------------------------------------------------------------
import asyncio
import os
import pytest
import pytest_asyncio
import logging

from bumble import device
from bumble import gatt
from bumble.profiles import vcp
from .test_utils import TwoDevices

Expand All @@ -32,7 +30,7 @@


# -----------------------------------------------------------------------------
@pytest.fixture
@pytest_asyncio.fixture
async def vcp_client():
devices = TwoDevices()
devices[0].add_service(
Expand Down