I am having a heck of a time trying to figure out the problem with connecting the SM shield to a Leonardo arduino. I’m trying to run the simple on/off/hello sample sketch, and am getting “setup…” in the serial monitor but that’s it. Otherwise the SMartthings hub sees the shield and I have it set as the On/Off (example) option. I already added the "while (!Serial) ; portion to the code, so that should be working ok (I think…) I did see something about the 2-3 pins not being the same on the Leonardo that they are on the Duo, but I’m not completely clear on what that means or if/how I can get it to work. I’d love to have the Leonardo working with this, but I guess if need be I can spring for a Duo instead…
@snooginsguy, I found this line in the Smarthings.h header…Did you uncomment that line to define leonardo board type?
//*******************************************************************************
// @note Set to Leonardo here if using Leonardo board
//*******************************************************************************
//#define BOARD_TYPE BOARD_TYPE_LEONARDO //TODO Incomplete
thanks for the suggestion. I uncommented the line, but then the project wouldn’t compile at all! I then added the line #define BOARD_TYPE BOARD_TYPE_LEONARDO to the sketch just under the lines to define the PIN_THING_RX/TX but that doesn’t seem to have done anything. Any other ideas?
Shoot, I did just notice in the info.txt of the smartthings libraries folder that on 2/8/2012 they “Began framework for working on Leonardo” but there’s no subsequent entry that it was finished. It seems that it’s unlikely the Leonardo will work after all? Bit disappointing if that’s the case since the arduino shield page specifies the Leonardo as working…
calling in the big guns…@urman, @megapixel, @chrisb, @wackware …can one of you answer the question about how to get smartthings shiled working with the LEONARDO board?
Sorry @gopi2212, in this area I’m more of a BB-gun than a big gun!
Based on what PJ was saying above:
Shoot, I did just notice in the info.txt of the smartthings libraries folder that on 2/8/2012 they “Began framework for working on Leonardo” but there’s no subsequent entry that it was finished. It seems that it’s unlikely the Leonardo will work after all? Bit disappointing if that’s the case since the arduino shield page specifies the Leonardo as working…
Might be the clue. I’d send an email to support and ask if the Leonardo is even supported.
Yep, it did! My application is a controller for multiple strings of LEDs, driven by a 6-FET Sparkfun power shield. Fortunately I only need 4 control channels, as the power controller uses all 6 PWM pins and the ThingShield now wants two of them (3 and 10).