All - I have some good news! I have successfully added Ethernet support to the ST_Anything/SmartThings libraries. I have it working properly on my desk. Happy to report that Ethernet appears to be quicker than the ThingShield as well. I need to do some more testing and write up some new documentation to explain the changes needed within your Arduino sketches. I hope to have everything uploaded to Github this weekend.
To give you a feel for the changes…
Since, ST is no longer supporting the ThingShield and its Arduino library, my son and I decided it was alright to break backwards compatibility in the name of progress. There is now a class hierarchy which you should be aware of, however it really is pretty simple to use still. The same basic functions are all still there. Just the name of the class for the old ThinShield has changed from “SmartThings” to “SmartThingsThingShield” to make it clear which device you are using. And, I’ve added support for the W5100 Ethernet shield as well as the NodeMCU ESP8266 Wifi board to provide a couple methods of using Ethernet.
The classes in BOLD above are the ones you would use depending on how you’re connecting to SmartThings. Additional classes could easily be added for other methods of connecting to the ST Cloud. Currently, all three methods above send and receive all of their traffic via the ST Hub (v2 hub tested, not sure about v1.)
I know that wired Ethernet or WiFi may not be ideal for every application, but at least these will provide options for users who can no longer purchase ThingShields. There are some other efforts underway within the community to see if Xbee shields could be used to continue using Zigbee. I have chosen to focus on Ethernet and WiFi for now. If there is a need for another method/shield, we can easily add another subclass to the new SmartThings library as shown above.
Each class simply needs to support:
- the Callback Function to handle data from ST
- the run() command
- the send() command
- and a new init() command
I hope to have everything ready for a release sometime this weekend, schedule permitting. Please let me know if you have any questions.