Puck.js

Puck.js

$  dmesg
[72289.990670] usb 7-1: new full-speed USB device number 3 using ohci-pci
[72290.145201] usb 7-1: New USB device found, idVendor=0a12, idProduct=0001
[72290.145206] usb 7-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[72290.145209] usb 7-1: Product: CSR8510 A10

$ hciconfig -a
hci0:   Type: BR/EDR  Bus: USB
        BD Address: 00:1A:7D:DA:71:03  ACL MTU: 310:10  SCO MTU: 64:8
        DOWN 
        RX bytes:564 acl:0 sco:0 events:29 errors:0
        TX bytes:358 acl:0 sco:0 commands:29 errors:0
        Features: 0xff 0xff 0x8f 0xfe 0xdb 0xff 0x5b 0x87
        Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3 
        Link policy: RSWITCH HOLD SNIFF PARK 
        Link mode: SLAVE ACCEPT 
$ lsusb
   ...
Bus 007 Device 003: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
   ....

The device is there, but the network functionality is down.

$ sudo hciconfig hci0 up
$ hciconfig -a
hci0:   Type: BR/EDR  Bus: USB
        BD Address: 00:1A:7D:DA:71:03  ACL MTU: 310:10  SCO MTU: 64:8
        UP RUNNING PSCAN 
        RX bytes:1179 acl:0 sco:0 events:67 errors:0
        TX bytes:1064 acl:0 sco:0 commands:66 errors:0
        Features: 0xff 0xff 0x8f 0xfe 0xdb 0xff 0x5b 0x87
        Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3 
        Link policy: RSWITCH HOLD SNIFF PARK 
        Link mode: SLAVE ACCEPT 
        Name: 'heinz.site'
        Class: 0x0c0104
        Service Classes: Rendering, Capturing
        Device Class: Computer, Desktop workstation
        HCI Version: 4.0 (0x6)  Revision: 0x22bb
        LMP Version: 4.0 (0x6)  Subversion: 0x22bb
        Manufacturer: Cambridge Silicon Radio (10)

But

$ hcitool -i hci0 scan
Scanning ...
$

The Puck device is not found. After telling my phone it should be visible:

hcitool -i hci0 scan
Scanning ...
        60:AF:6D:AB:AE:1C       Heinz

OK, it seems to work in principle. Looking at the option the hcitool has, one can see that there is not only scan but a special lescan. It must be used with root privilgies.

$ sudo hcitool -i hci0 lescan
LE Scan ...
E6:46:FE:45:41:C5 Puck.js 41c5
E6:46:FE:45:41:C5 (unknown)
E6:46:FE:45:41:C5 Puck.js 41c5
E6:46:FE:45:41:C5 (unknown)
E6:46:FE:45:41:C5 Puck.js 41c5
E6:46:FE:45:41:C5 (unknown)
  .....

Now it is possible to activate Web-Bluetooth in the Chrome Browser and the Espruino Web IDE connects to the Puck.js

Anyway the IDE does not connect correctly. I found some similar posts and now try to update the BT stack
according to WEB BLUETOOTH ON UBUNTU 16.04 / LINUX MINT 18. OK, I'm on openSuse, but ...
The configure stops complaining about gcc. v4.8 is not enough there is a test for > 5. Installed gcc-6-2.4

It was easier then i Thought. The latest version 5.43 was available using zypper install

After some twittleing with all the Bluetooth tools, I manged to connect the Web IDE with one of the Pucks.

Using the Espruino Command Line Interface CLI

If the Node Package Manager npm is already installed:

npm  -g espruino-cli

Installing on Raspberry

sudo apt-get install npm

wget https://nodejs.org/dist/v4.4.5/node-v4.4.5-linux-armv6l.tar.gz
tar -xvf node-v4.4.5-linux-armv6l.tar.gz
cd node-v4.4.5-linux-armv6l
sudo cp -R * /usr/local/
sudo reboot

Using the Espruino Command Line Interface CLI

If the Node Package Manager npm is already installed:

sudo npm i -g espruino-cli

esp