question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

stuck on startAdvertising, MacOS 10.14

See original GitHub issue
bleno.on('stateChange', function(state) {
  console.log('on -> stateChange: ' + state);

  if (state === 'poweredOn') {
	  console.log('start advertising');
    bleno.startAdvertising('echo', ['ec00']);
  } else {
    bleno.stopAdvertising();
  }
});

`

GalenZhaos-MacBook-Air:echo galenzhao$ sudo BLENO_DEVICE_NAME="custom device name" 
BLENO_ADVERTISING_INTERVAL=500 node main.js 
bleno - echo
on -> stateChange: poweredOn
start advertising

I added start event callback but never get called,

bleno.on('advertisingStartError', function(error){
    console.log('on -> advertisingStart: ' + (error ? 'error ' + error : 'success'));
	
});

bleno.on('advertisingStart', function(error) {
  console.log('on -> advertisingStart: ' + (error ? 'error ' + error : 'success'));

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:12
  • Comments:35

github_iconTop GitHub Comments

8reactions
codeofdiegocommented, Dec 19, 2018

@notjosh Thank you so much for that fix, i hope it get’s merged in the original repo soon! For now, replacing the dependencies to point to your fixes made it work “out of the box”.

"dependencies": {
    "bleno": "github:notjosh/bleno#inject-bindings",
    "bleno-mac": "github:notjosh/bleno-mac"
}

🚀

6reactions
LukasBombachcommented, Jul 4, 2019

Thanks @petrbela gathering the stuff from here I stitched up a solution:

{
  "dependencies": {
    "bleno": "github:notjosh/bleno#inject-bindings",
    "bleno-mac": "github:notjosh/bleno-mac",
    "xpc-connection": "sandeepmistry/node-xpc-connection#pull/26/head"
  },
  "resolutions": {
    "xpc-connection": "sandeepmistry/node-xpc-connection#pull/26/head"
  }
}

See my other post for more information here: https://github.com/noble/bleno/issues/416

Read more comments on GitHub >

github_iconTop Results From Across the Web

Stuck on macOS 10.14? Here's the fix to get to 10.14.1
1 arrived yesterday, I fired up Software Update–newly relocated in Mojave to a pane in System Preferences–to install it on my MacBook Air....
Read more >
Mojave 10.14.1 update stuck on installing - Apple Community
Mojave 10.14.1 update stuck on installing. I have another problem with mojave, now with the update, ... Mac Pro, macOS Sierra (10.12.6).
Read more >
How to fix your Mac that gets stuck when installing Mojave ...
Troubleshooting macOS Mojave 10.14 installation stuck, failed update error on your Mac. Note that the underlying cause of the problem is still ...
Read more >
MacOS Mojave Installation Stuck/Frozen/Failed - YouTube
You Can't install New MacOS Mojave 10.14.4 update on your Mac running on Old MacOS. Troubleshoot the issues using the quick fix guide...
Read more >
Stuck with an old version of MacOS - Apple Stack Exchange
From the looks of the details on EveryMac.com your Mac will take up to macOS 10.13.x (High Sierra). Apple's current macOS version is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found