• I am trying to send an advertisment packet from a raspberry pi zero w using nodejs with bleno:

    var bleno = require('bleno')
    var name = 'tbd-pager-pi';
    
    console.log('bleno server start')
    
    bleno.on('stateChange', function(state) {
     console.log('on -> stateChange: ' + state);
     if (state === 'poweredOn') {
         bleno.startAdvertising(name, []);
     } else {
         bleno.stopAdvertising();
       }
    });
    

    tested with nRF Connect/iOS and the advertisment is visible and connectable with Complete Local name set correctly

    on a Puck.JS I am using this code:

    NRF.setScan(function(e){
      if(e.name && e.name.indexOf('tbd-pager') > -1){
        digitalPulse(LED3, 1, 100);
      }
    });
    
    setWatch(function () {
      print("scan disabled");
      digitalPulse(LED1,1,100);
      NRF.setScan();
    }, BTN1, { repeat:true, debounce:true, edge:'rising' });
    

    the problem is that there no found message and no LED3 blinking :(

    same code that runs on Raspberry moved to OSX works perfectly

    any idea why I cannot see the advertisment from Raspberry ?

About

Avatar for tbd @tbd started