bleno icon indicating copy to clipboard operation
bleno copied to clipboard

Unusable on macOS 10.15.3

Open OR13 opened this issue 4 years ago • 4 comments

There are no obvious errors on install but 'stateChange' never fires.

node: v12.16.0

OR13 avatar Apr 19 '20 20:04 OR13

I am running into the same thing. Haven't dug much into it, but it looks like something changed.

running DEBUG=* ./index.js shows some debugging info:

$ DEBUG=* ./index.js 
Starting...
  bleno platform darwin +0ms
  bleno addressChange ... +1ms
  highsierra-bindings sendCBMsg: 1, {
  highsierra-bindings   "kCBMsgArgName": "node-1588044072024",
  highsierra-bindings   "kCBMsgArgOptions": {
  highsierra-bindings     "kCBInitOptionShowPowerAlert": 1
  highsierra-bindings   },
  highsierra-bindings   "kCBMsgArgType": 1
  highsierra-bindings } +0ms
  highsierra-bindings xpcEvent: {
  highsierra-bindings   "kCBMsgId": 48,
  highsierra-bindings   "kCBMsgArgs": {
...
  highsierra-bindings     }
  highsierra-bindings   }
  highsierra-bindings } +1ms
  highsierra-bindings xpcEvent: {
  highsierra-bindings   "kCBMsgId": 6,
  highsierra-bindings   "kCBMsgArgs": {
  highsierra-bindings     "kCBMsgArgBTPowerState": 1,
  highsierra-bindings     "kCBMsgArgState": 5
  highsierra-bindings   }
  highsierra-bindings } +0ms

So, it's getting an xpcEvent with a message id 48 and one with message id 6, but there are no handlers inside highsierra.js that handles those messages.

petewall avatar Apr 28 '20 03:04 petewall

Same for MacOS Mojave 10.14.6 (18G5033) with Node v10.21.0

$ DEBUG=* node ./main.js
bleno - echo
  bleno platform darwin +0ms
  bleno addressChange 64:76:ba:8c:13:d1 +2ms
  highsierra-bindings sendCBMsg: 1, {
  highsierra-bindings   "kCBMsgArgName": "node-1592678188769",
  highsierra-bindings   "kCBMsgArgOptions": {
  highsierra-bindings     "kCBInitOptionShowPowerAlert": 1
  highsierra-bindings   },
  highsierra-bindings   "kCBMsgArgType": 1
  highsierra-bindings } +0ms
  highsierra-bindings xpcEvent: {
  highsierra-bindings   "kCBMsgId": 4,
  highsierra-bindings   "kCBMsgArgs": {
  highsierra-bindings     "kCBMsgArgState": 5
  highsierra-bindings   }
  highsierra-bindings } +4ms
  highsierra-bindings state change poweredOn +0ms
  bleno stateChange poweredOn +4ms
on -> stateChange: poweredOn
  highsierra-bindings sendCBMsg: 16, {
  highsierra-bindings   "kCBAdvDataLocalName": "echo",
  highsierra-bindings   "kCBAdvDataServiceUUIDs": [
  highsierra-bindings     {
  highsierra-bindings       "type": "Buffer",
  highsierra-bindings       "data": [
  highsierra-bindings         236,
  highsierra-bindings         0
  highsierra-bindings       ]
  highsierra-bindings     }
  highsierra-bindings   ]
  highsierra-bindings } +4ms

alainux avatar Jun 20 '20 18:06 alainux

I recommend using: https://github.com/pokusew/nfc-pcsc, its supports raw transmit, and can be configured to handle large responses... You will need to generate / parse the TLV yourself.

OR13 avatar Jun 22 '20 14:06 OR13

I have also the issue that nothing works on macos - also with the current verison her on github ... Does anypne solved it @ptx2 @OR13 ?

Apollon77 avatar Jun 16 '23 14:06 Apollon77