Frequently Asked Questions

Technical

  • My JavaScript code fails to connect to the Arduino board on my PC.

This can happen when the Arduino board is not automatically detected by Johnny-five.  In this case you will have to specify the port yourself in the JavaScript code.  To find out what the port is, make sure your Arduino board is connected, then open the Arduino IDE (click the Arduino icon), check the bottom right of the window.  The Arduino should be recognized and tell you what port it is on.  For example COM3.  In your JavaScript, when you create the Board, add the port like this:

var board = five.Board ( {port: "COM3"} );
  • Lesson 1 - My LED only blinks once and then stops.

We've noticed that some computers (MacBook Air and older PCs running Windows 7) have issues with the .blink() command with the PWM pins.  The PWM pins are pins 3, 5, 6, 9, 10 and 11.  Use a different pin on your Arduino board (like 4) and update your code with the pin that you choose.