File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change 2020
2121 See file LICENSE.txt for further informations on licensing terms.
2222
23- Last updated by Jeff Hoefs: May 17 , 2015
23+ Last updated by Jeff Hoefs: May 30 , 2015
2424*/
2525
2626#include < Servo.h>
@@ -692,7 +692,16 @@ void setup()
692692 Firmata.attach (START_SYSEX, sysexCallback);
693693 Firmata.attach (SYSTEM_RESET, systemResetCallback);
694694
695+ // to use a port other than Serial, such as Serial1 on an Arduino Leonardo or Mega,
696+ // Call begin(baud) on the alternate serial port and pass it to Firmata to begin like this:
697+ // Serial1.begin(57600);
698+ // Firmata.begin(Serial1);
699+ // then comment out or remove lines 701 - 704 below
700+
695701 Firmata.begin (57600 );
702+ while (!Serial) {
703+ ; // wait for serial port to connect. Only needed for ATmega32u4-based boards (Leonardo, etc).
704+ }
696705 systemResetCallback (); // reset to default config
697706}
698707
You can’t perform that action at this time.
0 commit comments