Go Down

Topic: StandardFirmata on Due (Read 5 times) previous topic - next topic

datastorm

That would be fantastic, I would help test it for sure!


Actually, updating Firmata is on my to-do list... roughly in the middle, below lots of urgent stuff for Teensy 3.0, but well above lots of low priority bugs and stuff.  I'm planning to add Due and Teensy 3.0 definitions, and also work on making it truly compatible with alternate Stream-based ports.  I want to merge the recent stepper support that's currently in a separate branch.

This probably won't happen in time for 1.0.2 (unless someone else does it... which seems unlikely).  At the moment, I have 2 Dues on order from Mouser, but they haven't arrived yet.  The only Due hardware I have is the early developer beta.  If Mouser doesn't ship in a couple weeks, I'll probably just use the beta hardware for testing.  I'll probably only connect a few LEDs and pushbuttons.  If anyone is willing to test with more stuff connected to lots of pins, please get on the Firmata developer mail list.

As to whether Firmata is a "waste" of good hardware, if it lets people get their projects working, then I believe it's valuable.



jgmdavies

#11
Oct 31, 2012, 07:13 pm Last Edit: Oct 31, 2012, 07:14 pm by jgmdavies Reason: 1
@Grumpy_Mike

Maybe you're feeling extra grumpy, but how can you ignore all the folk who occasionally want an easy way to test their board, often because the 'super fast many-interrupt native app' they're trying to get going isn't quite there yet?  Anyone ever thought they've bricked a board?

I think we need more ways to test kit and help beginners to develop their confidence, not fewer.

BW
Jim

mantoui

#12
Dec 15, 2012, 01:44 am Last Edit: Dec 15, 2012, 02:06 am by mantoui Reason: 1
Well, as a first try, here is the DUE info I put into Boards.h after moving the Firmata folder into the DUE's libraries folder. StandardFirmata wouldn't build because it needs Servo.h (and probably more), but SimpleDigitalFirmata compiled and loaded on to the DUE, and I was able to use the processing Sketchbook/blink/blink.pde to blink the LED (pin 13) on the DUE.  

Code: [Select]

// Arduino DUE
#elif defined(__SAM3X8E__)
#define TOTAL_ANALOG_PINS       12
#define TOTAL_PINS              66 // 54 digital + 12 analog
#define VERSION_BLINK_PIN       13
#define IS_PIN_DIGITAL(p)       ((p) >= 2 && (p) < TOTAL_PINS)
#define IS_PIN_ANALOG(p)        ((p) >= 54 && (p) < TOTAL_PINS)
#define IS_PIN_PWM(p)           digitalPinHasPWM(p)
#define IS_PIN_SERVO(p)         ((p) >= 2 && (p) - 2 < MAX_SERVOS)
#define IS_PIN_I2C(p)           ((p) == 20 || (p) == 21) // 70 71
#define PIN_TO_DIGITAL(p)       (p)
#define PIN_TO_ANALOG(p)        ((p) - 54)
#define PIN_TO_PWM(p)           PIN_TO_DIGITAL(p)
#define PIN_TO_SERVO(p)         ((p) - 2)


Valdas

#13
Dec 15, 2012, 02:53 pm Last Edit: Dec 15, 2012, 03:34 pm by Valdas Reason: 1
Yes, mantoui!

But I can't test using http://www.pjrc.com/teensy/firmata_test/firmata_test.64bit program, becouse window is empty. Only Arduino IDE shows greating string.

And after copying of "Servo" directory from "arm" folder into "sam" folder, when I compile StandardFirmata I get:

/opt/arduino-1.5.1/hardware/arduino/sam/libraries/Servo/Servo.cpp:45: fatal error: avr/interrupt.h: No such file or directory
compilation terminated.

So, we need interrupt.h for sam (Arduino Due)  ;)

Paul Stoffregen


But I can't test using http://www.pjrc.com/teensy/firmata_test/firmata_test.64bit program, becouse window is empty.


In the screenshot you posted, notice there are 2 menus at the top, "File" and "Port".  Try using "Port" to select the serial port.  Of course, close the Arduino Serial Monitor before you open the port with firmata_test.

Go Up