You are reading a single comment by @jgrizou and its replies. Click here to read the full conversation.
  • You could try espruino --verbose and see if it mentions anything there about Noble and whether it's not working for some reason?

    But you probably wouldn't expect the Pixl to appear in the Mac OS bluetooth settings because it doesn't provide any services (like keyboard or voice) that the Mac is interested in.

    You could try uploading this from your phone: https://espruino.github.io/EspruinoApps/#blehidkey

    It'd turn the Pixl into a bluetooth keyboard (only for 'Enter') and then it's possible the Mac would see it in the OS menu. It doesn't help you program it but it would at least prove it was an issue with Chrome.

    Another option is to install https://github.com/espruino/EspruinoHub on a Raspberry Pi, and then you can connect to the raspberry pi (again via web address) and program the Pixl.js that way

    ... or, if you have USB-TTL converter you can program Pixl.js via serial port as well.

  • It works now! It was the most stupid thing as often, it was due to MacOS "Security & Privacy"settings but no warning was shown in Chrome.

    I tried espruino --verbose and indeed found Noble issues.

    Noble: getPorts - initialising... Noble: module couldn't be loaded, no
    node.js Bluetooth Low Energy Error: Cannot find module
    '@abandonware/noble'

    It was not installed, so tried installing it which didn't work at first. I followed the tracks and tried resintalling xcode (https://medium.com/@mrjohnkilonzi/how-to-resolve-no-xcode-or-clt-version-detected-d0cf2b10a750). Could install noble in the end but still did not work.

    I then looked at npm page for noble (https://www.npmjs.com/package/@abandonware/noble#os-x), which says:

    On newer versions of OSX, allow bluetooth access on the terminal app:
    "System Preferences" —> "Security & Privacy" —> "Bluetooth" -> Add
    terminal app (see Sandboxed terminal)

    I went there and found Chrome app unchecked :/, checked it and everything worked. I could use the app loader and uploaded the t-rex app.

    Somehow Bluetility was in the list and already activated but not the two other apps there. I don't remember having done so for Bluetility otherwise I would have understood . There was no warning in Chrome either to indicate this could be an issue, it was blind to the macOS settings. Even chrome://bluetooth-internals/#adapter was showing Bluetooth as available and working. So I am not sure how you could catch that and show a message from the WebIDE.

    Good to have this mystery sorted!

    Thanks again for your time Gordon and apologies if this is a known issue and I missed it in the documentation.


    1 Attachment

    • Screenshot 2021-03-19 at 10.18.32.png
About

Avatar for jgrizou @jgrizou started