Could not start scanning, state is unknown (not poweredOn)
See original GitHub issueHello, I’ve tried to scan for BLE devices:
noble = require('noble')
noble.startScanning();
console.log "Scanning"
this results in a error message (?):
noble: Could not start scanning, state is unknown (not poweredOn)
Scanning
Is the code wrong or is the message wrong? Is intended, that a message is printed on the screen? Shouldn’t an exception being thrown if a precondition is not met?
I’ve tried 1.1.0 on OS/X 10.10
Cheers, Torsten
Issue Analytics
- State:
- Created 8 years ago
- Comments:9
Top Results From Across the Web
How to power BLE back on using node-red-contrib-noble ...
Any ideas how to prevent or catch this error? Error scanning for devices: Error: Could not start scanning, state is poweredOff (not poweredOn)....
Read more >sandeepmistry/bleno - Gitter
hello im using bleno for a demo but i cannot get it start advertising , everytime it ... Could not start scanning, state...
Read more >noble.state is set to "poweredOff" immediately after running ...
When the state is set to "poweredOff" it stops scanning so I am never able to find devices. Here is my code: const...
Read more >@lemariva/noble - npm
Some BLE adapters cannot connect to a peripheral while they are scanning ... NOTE: noble.state must be poweredOn before scanning is started.
Read more >API misuse | Apple Developer Forums
unknown state, just as we implement the centralManagerDidUpdateState method. In any case, the state doesn't change until the scan is called. So, how...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@TorstenRobitzki: you might try waiting for the state to become
poweredOn:Im trying to read a ble char from a ble relay board from my rpi3. startScanning() simply hangs or returns error that ble device isnt powered on. Why is that?
I know the ble on the rpi3 works because I use it to write to the relay board every so often and it works fine.