Turning Bluetooth 'broadcast' off after sending #2794
Closed
toyotafj40
started this conversation in
General
Replies: 2 comments 1 reply
|
Turns out this works |
1 reply
|
Sorry, I got confusedly between broadcast and broadcast channel.
Regards
Peter
…On Mon, 24 Aug 2026, 4:03 pm Laurens Valk, ***@***.***> wrote:
The doco says 'broadcast=None' should stop the broadcast
Where did you find that? That doesn't sound right, so we should update the
docs.
The following should stop broadcasting:
radio.broadcast(None)
Did this not work?
You shouldn't have to restart the whole BLERadio.
—
Reply to this email directly, view it on GitHub
<#2794?email_source=notifications&email_token=CHL73RUIW7ARVRYWICASDA35LPLCHA5CNFSNUABIM5UWIORPF5TWS5BNNB2WEL2ENFZWG5LTONUW63SDN5WW2ZLOOQXTCOBRGMYDSMRWUZZGKYLTN5XKY43UMF2GKX3DNBQW4Z3FUVSXMZLOOSWGM33PORSXEX3DNRUWG2Y#discussioncomment-18130926>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/CHL73RSACWIC4ZXUODUI2ZL5LPLCHAVCNFSNUABIKJSXA33TNF2G64TZHMZDIOBYGAZTENJUHNCGS43DOVZXG2LPNY5TCMBWG42DANBZUF3AE>
.
Triage notifications, keep track of coding agent tasks and review pull
requests on the go with GitHub Mobile for iOS
<https://github.com/notifications/mobile/ios/CHL73RRS7KKB6F6WBZB6HOD5LPLCHA5CNFSNUABIM5UWIORPF5TWS5BNNB2WEL2ENFZWG5LTONUW63SDN5WW2ZLOOQXTCOBRGMYDSMRWUZZGKYLTN5XKY43UMF2GKX3DNBQW4Z3FUVSXMZLOOSVGM33PORSXEX3JN5ZQ>
and Android
<https://github.com/notifications/mobile/android/CHL73RWQAH6O5PE6WNDOWYT5LPLCHA5CNFSNUABIM5UWIORPF5TWS5BNNB2WEL2ENFZWG5LTONUW63SDN5WW2ZLOOQXTCOBRGMYDSMRWUZZGKYLTN5XKY43UMF2GKX3DNBQW4Z3FUVSXMZLOOSXGM33PORSXEX3BNZSHE33JMQ>.
Download it today!
You are receiving this because you modified the open/close state.Message
ID: ***@***.***>
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Currently in the debug session of the code and want to restrict the number of packets being sent by BLE and displayed in the receiver.
The doco says 'broadcast=None' should stop the broadcast, but that's not what is happening...
The broadcast does stop as soon as I stop the program execution with F6 - Stop Everything or CityHub green button press.
The receiver also immediately stops displaying data, so this is not the sniffer repeatedly showing 'last seen' data. It does actually show last 'captured' data.
I would have thought this alone should stop the BLERadio
radio = BLERadio(broadcast_channel=None, observe_channels=[])
even adding this should 'destroy' the BLERadio
radio = None
This is a small test program to broadcast and then stop sending packets
I expect to see small bursts of data then a 5 second gap.
Using the software parameters seems to be ineffective. Am I missing something?
This code was run on CityHub, Pybricks Code v3.0.1 with firmware v4.0.1
As a workaround, I am now simply changing 'broadcast=None', to 'broadcast=255' and sending the unwanted packets away.
All reactions