rwaldron/johnny-five

johny-five initialization pb with ConfigurableFirmata 3.0.0

echavet opened this issue · 8 comments

I can manage to init johnny-five with the blink (helloWorld.js) example if I use the StandardFirmataPlus firmware on an arduino UNO but I can't manage to get it work with ConfigurableFirmata which is supposed to be supported in the doc.

I get an exception :

serialport/bindings/unixRead read error [Error: EAGAIN: resource temporarily unavailable, read] {
errno: -35,
code: 'EAGAIN',
syscall: 'read'
} +0ms
serialport/bindings/unixRead waiting for readable because of code: EAGAIN +0ms
serialport/bindings/poller Polling for "readable" +1ms
serialport/stream _write 1 bytes of data +2s
serialport/binding-abstract write 1 bytes +2s
serialport/bindings/unixWrite Starting write 1 bytes offset 0 bytesToWrite 1 +0ms
serialport/bindings/unixWrite write returned: wrote 1 bytes +0ms
serialport/bindings/unixWrite Finished writing 1 bytes +1ms
serialport/stream binding.write write finished +2ms
serialport/stream _write 3 bytes of data +0ms
serialport/binding-abstract write 3 bytes +2ms
serialport/bindings/unixWrite Starting write 3 bytes offset 0 bytesToWrite 3 +0ms
serialport/bindings/unixWrite write returned: wrote 3 bytes +0ms
serialport/bindings/unixWrite Finished writing 3 bytes +0ms
serialport/stream binding.write write finished +1ms
1677596731635 Device or Firmware Error A timeout occurred while connecting to the Board.

Please check that you've properly flashed the board with the correct firmware.
See: https://github.com/rwaldron/johnny-five/wiki/Getting-Started#trouble-shooting

If connecting to a Leonardo or Leonardo clone, press the 'Reset' button on the board, wait approximately 11 seconds for complete reset, then run your program again.
Erreur: {"type":"error","timestamp":1677596731635,"class":"Device or Firmware Error","message":"A timeout occurred while connecting to the Board.

Of course I've read the trouble-shooting section which indicate to use a StandardFirmata firmware. But if I do so, I cannot use the OneWire Thermometer feature of Johnny-five (which indicates me to use ConfigurableFirmata when I'm using StandardFirmata).

There is no log to help me to trouble shoot this issue!!

Capture d’écran 2023-02-28 à 16 18 59

Precision: ConfigurableFirmata V 2.10.1 works well. So the pb is only with 3.0.0 version of ConfigurableFirmata

Interesting, I'm not aware of a protocol change that would affect the initialization sequence. And other client libraries seem to be unaffected. I have never worked with js, so I'm not even able to find the code that does the actual communication. The board class seems to just wait for an event which isn't comming.

Hmmm... I don't quite understand how that could help. The bit order certainly hasn't changed.

Ok.
I should have double checked that the bauds rates were matching both side.
Thanks for help, sorry for the waste of time...

@echavet Oh, yea. That's what did change. The default baudrate has changed from 57600 to 115200.

@echavet I think it is init problem on ConfigurableFirmata.ino. Can you follow this pr, and test it?
firmata/ConfigurableFirmata#144