-
Well, i try using my little laptop, still on ubuntu 19.04, and while i didnt face same issue, i still encounter new one :
Loaded code from storage. Handling URL "https://www.espruino.com/ide/" Couldn't connect to wss://localhost:31234 - disabling websockets for this session ERROR: getURL("/serial/ports") error : Not Found /serial/ports doesn't exist - disabling WebSocket support ERROR: serial_frame: getPorts timeout, disabling >>> Connecting... Set Slow Write = true serviceworker> active BT> ERROR: NotFoundError: User cancelled the requestDevice() chooser. ERROR: [notify_error] Connection Failed. >>> Connection Failed. >>> Connecting... Set Slow Write = true >>> Connecting to Pixl.js c734 BT> Device Name: Pixl.js c734 BT> Device ID: MckzoCJ/zg3Wdi0vtHM5mg== BT> ERROR: NetworkError: Connection failed for unknown reason. ERROR: [notify_error] Connection Failed. >>> Connection Failed.
-
thank you @Gordon :)
-
And there we go :
plonky@macronetmonk:~/node_modules/espruino/bin$ ./espruino-cli.js -d Pixl --ide 8080 Espruino Command-line Tool 0.1.27 ----------------------------------- Searching for device named "Pixl" Found "Pixl.js c734" ("fa:ee:05:a7:c7:34") Connecting to 'fa:ee:05:a7:c7:34' Connected Web IDE is now available on http://localhost:8080 Web IDE Connection accepted. >< << {"VERSION":"2v01","GIT_COMMIT":"748a4d3","BOARD":"PIXLJS","FLASH":524288,"RAM":65536,"SERIAL":"1e21d7bf-3480018d","CONSOLE":"Bluetooth","MODULES":"Flash,Storage,heatshrink,fs,net,dgram,http,NetworkJS,WIZnet,crypto,neopixel,graphical_menu","EXPTR":536882356} >> > >
-
plonky@macronetmonk:~/node_modules/espruino/bin$ sudo setcap cap_net_raw+eip $(eval readlink -f `which node`) [sudo] password for plonky: plonky@macronetmonk:~/node_modules/espruino/bin$ ./espruino-cli.js --list Espruino Command-line Tool 0.1.27 ----------------------------------- PORTS: fa:ee:05:a7:c7:34 (Pixl.js c734) plonky@macronetmonk:~/node_modules/espruino/bin$ ./espruino-cli.js --list --verbose 0.1.27 Espruino Command-line Tool 0.1.27 ----------------------------------- Acorn library not found - you'll need it for compiled code Found /home/plonky/node_modules/espruino/libs/targz.js Found /home/plonky/node_modules/espruino/libs/utf8.js Found /home/plonky/node_modules/espruino/espruino.js Found /home/plonky/node_modules/espruino/core/codeWriter.js Found /home/plonky/node_modules/espruino/core/config.js Found /home/plonky/node_modules/espruino/core/env.js Found /home/plonky/node_modules/espruino/core/flasher.js Found /home/plonky/node_modules/espruino/core/modules.js Found /home/plonky/node_modules/espruino/core/notifications.js Found /home/plonky/node_modules/espruino/core/serial.js Found /home/plonky/node_modules/espruino/core/serial_chrome_serial.js No chrome.serial - Chrome Serial disabled Found /home/plonky/node_modules/espruino/core/serial_chrome_socket.js No chrome.sockets - Chrome Socket disabled Found /home/plonky/node_modules/espruino/core/serial_frame.js Found /home/plonky/node_modules/espruino/core/serial_noble.js Found /home/plonky/node_modules/espruino/core/serial_node_serial.js Found /home/plonky/node_modules/espruino/core/serial_node_socket.js Found /home/plonky/node_modules/espruino/core/serial_web_audio.js Found /home/plonky/node_modules/espruino/core/serial_web_bluetooth.js Found /home/plonky/node_modules/espruino/core/serial_websocket_local.js Found /home/plonky/node_modules/espruino/core/serial_websocket_relay.js Found /home/plonky/node_modules/espruino/core/serial_winnus.js Not on Windows, Winnus not needed Found /home/plonky/node_modules/espruino/core/terminal.js Found /home/plonky/node_modules/espruino/core/utils.js Found /home/plonky/node_modules/espruino/plugins/assembler.js Found /home/plonky/node_modules/espruino/plugins/boardJSON.js Found /home/plonky/node_modules/espruino/plugins/compiler.js Found /home/plonky/node_modules/espruino/plugins/getGitHub.js Found /home/plonky/node_modules/espruino/plugins/localModules.js Found /home/plonky/node_modules/espruino/plugins/minify.js Found /home/plonky/node_modules/espruino/plugins/saveOnSend.js Found /home/plonky/node_modules/espruino/plugins/setTime.js Found /home/plonky/node_modules/espruino/plugins/unicode.js Loading UTF8 with require Found /home/plonky/node_modules/espruino/plugins/versionChecker.js Initialising CodeWriter Initialising Config Initialising Env Initialising Flasher Initialising Modules Initialising Notifications Initialising Serial - Initialising Serial Noble Bluetooth LE - Initialising Serial Node Serial - Initialising Serial Node Socket - Initialising Serial Web Bluetooth Initialising Utils Initialising Status Initialising Assembler Initialising BoardJSON Initialising Compiler Initialising GetGitHub Initialising LocalModules Initialising Minify Initialising SaveOnSend Initialising SetTime Initialising Unicode Initialising VersionChecker Initialising CoreModules Searching for serial ports... Noble: getPorts - not initialised No navigator.bluetooth - Web Bluetooth not enabled Noble: stateChange -> poweredOn Noble: Disable Web Bluetooth as we have Noble instead Noble: Starting scan Noble: Found UART device: Pixl.js c734 fa:ee:05:a7:c7:34 Noble: Found device: TNT_BW f0:ab:54:4b:3f:8c Noble: Found device: TNT_BW f0:ab:54:4b:3f:8c PORTS: fa:ee:05:a7:c7:34 (Pixl.js c734)
looks better ! :)
-
Well well well,
Not good.
As far as i can see:plonky@macronetmonk:~/node_modules/espruino/bin$ ./espruino-cli.js --list Espruino Command-line Tool 0.1.27 ----------------------------------- PORTS:
No port listed.
I can still connect using gatttool, but using a random address on computer side.
If i use a public address, it doesn't work at all:plonky@macronetmonk:~/node_modules/espruino/bin$ gatttool -t random -b FA:EE:05:A7:C7:34 -I [FA:EE:05:A7:C7:34][LE]> connect Attempting to connect to FA:EE:05:A7:C7:34 Connection successful Notification handle = 0x000d value: 3c 2d 20 54 65 72 6d 69 6e 61 6c 0d 0a 3e [FA:EE:05:A7:C7:34][LE]> (gatttool:18294): GLib-WARNING **: 17:06:47.993: Invalid file descriptor. plonky@macronetmonk:~/node_modules/espruino/bin$ man gatttool plonky@macronetmonk:~/node_modules/espruino/bin$ gatttool -t public -b FA:EE:05:A7:C7:34 -I [FA:EE:05:A7:C7:34][LE]> connect Attempting to connect to FA:EE:05:A7:C7:34 [FA:EE:05:A7:C7:34][LE]> plonky@macronetmonk:~/node_modules/espruino/bin$
-
-
-
plonky@macronetmonk:~$ bluetoothd --version 5.50 plonky@macronetmonk:~$ sudo /etc/init.d/bluetooth restart [sudo] password for plonky: [ ok ] Restarting bluetooth (via systemctl): bluetooth.service. plonky@macronetmonk:~$ chromium --version Chromium 74.0.3729.108 snap
Still getting the error :
serviceworker> active Handling URL "https://www.espruino.com/ide/" Couldn't connect to wss://localhost:31234 - disabling websockets for this session ERROR: serial_frame: getPorts timeout, disabling ERROR: getURL("/serial/ports") error : Not Found /serial/ports doesn't exist - disabling WebSocket support >>> Connecting... Set Slow Write = true BT> ERROR: NotFoundError: Bluetooth adapter not available. ERROR: [notify_error] Connection Failed. >>> Connection Failed. >>> Connecting... Set Slow Write = true BT> ERROR: NotFoundError: Bluetooth adapter not available. ERROR: [notify_error] Connection Failed. >>> Connection Failed.
-
After activating bluetooth in chrome with enabling this switch :
chrome://flags/#enable-experimental-web-platform-features
i face a new issue :serviceworker> active Handling URL "https://www.espruino.com/ide/" Couldn't connect to wss://localhost:31234 - disabling websockets for this session ERROR: serial_frame: getPorts timeout, disabling ERROR: getURL("/serial/ports") error : Not Found /serial/ports doesn't exist - disabling WebSocket support >>> Connecting... Set Slow Write = true BT> ERROR: NotFoundError: Bluetooth adapter not available. ERROR: [notify_error] Connection Failed. >>> Connection Failed.
-
Good evening,
Im able to connect to device using gatttool commandroot@macronetmonk:/var/log# gatttool -t random -b FA:EE:05:A7:C7:34 -I
[FA:EE:05:A7:C7:34][LE]> connect Attempting to connect to
FA:EE:05:A7:C7:34 Connection successful
[FA:EE:05:A7:C7:34][LE]> helpBut im unable to connect to it using web ide app from chromium, the device is not appearing when i try to connect.
It works very well from the same computer station, when im using windows10, i succed to connect and dev with windows chrome. But when i switch back to ubuntu (latest version 19.*) not possible to connect.anybody had faced this issue before, and how did you solved it ?
I added -E to bluetoothd command to enable experimental mode: