- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
Hi, im using johnny-five with galileo-io in a galileo gen 2 running yocto, i am trying to set a serial communication with SerialPort module, but i am getting the error: "Illegal instruction"
The code:
var Serialport = require("serialport").SerialPort;
var five = require("johnny-five");
var Galileo = require("galileo-io");
var board = new Galileo();
board.on("ready", function() {
var sp = new Serialport("/dev/ttyS0", { baudRate: 57600 });
sp.on("open", function() {
console.log("Port is open!"); // Once the port is open, you may read or write to it.
sp.on("data", function(data) {
console.log("Received: ", data);
});
setInterval(function(){
sp.write(new Buffer(["0120000003"])) }, 5000);
});
});
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
Hello ortizvinicius,
According to http://johnny-five.io/platform-support/# intel-galileo-gen-2 http://johnny-five.io/platform-support/# intel-galileo-gen-2, Johnny-five does not support Galileo's UART interface.
However, if you would like to interact with Galileo's interfaces, I'd suggest you to use mraa, this library has a lot more support for Galileo's interfaces. You can find more information about this library in https://github.com/intel-iot-devkit/mraa https://github.com/intel-iot-devkit/mraa.
Peter.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
Hello ortizvinicius,
According to http://johnny-five.io/platform-support/# intel-galileo-gen-2 http://johnny-five.io/platform-support/# intel-galileo-gen-2, Johnny-five does not support Galileo's UART interface.
However, if you would like to interact with Galileo's interfaces, I'd suggest you to use mraa, this library has a lot more support for Galileo's interfaces. You can find more information about this library in https://github.com/intel-iot-devkit/mraa https://github.com/intel-iot-devkit/mraa.
Peter.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page