You are reading a single comment by @Nic and its replies. Click here to read the full conversation.
  • Hi Gordon,

    I was sure this was working... I've just done some code tweaks and found it to be unreliable again. I flashed to the newest edge build in case further issues had been rectified but alas I can't get it to work.

    Here's my code:

    function AdvertiseData(Interval) {
    	NRF.setAdvertising([require("ble_ibeaconĀ­").get({
              uuid : UUID, // iBeacon UUID
              major : 0x0001, // optional
              minor : 0x0001, // optional
              rssi : -79 // optional RSSI at 1 meter distance in dBm
            })],{manufacturer: 0x0590, manufacturerData:[SensorID, Light, Temperature, Battery, ActionID, Active_Press_Action, Stuck], interval:Interval});
    

    Noble detects the iBeacon as the manufacturer data and the array of data is never picked up. If I pad it with another value preceeding the iBeacon like so:

    function AdvertiseData(Interval) {
    	NRF.setAdvertising([{0x180F : [0]},
            require("ble_ibeacon").get({
              uuid : UUID, // iBeacon UUID
              major : 0x0001, // optional
              minor : 0x0001, // optional
              rssi : -79 // optional RSSI at 1 meter distance in dBm
            })],{manufacturer: 0x0590, manufacturerData:[SensorID, Light, Temperature, Battery, ActionID, Active_Press_Action, Stuck], interval:Interval});
    
    }
    

    Noble picks up the array of values but the iBeacon isn't working.

    Any ideas?

    Thanks

    Nic

About

Avatar for Nic @Nic started