I recently watched a great video of someone using a GoPro and WiFi enabled Arduino to give high fives. The Arduino would send a command to the GoPro to start recording when his arm was raised. Check it out here http://vimeo.com/89814137
I love the idea of controlling my GoPro with the Spark Core so I’ve started this post to publish my progress and hope to have help from the Spark Community
The core will no longer have access to the Spark Cloud and you will not be able to use the online tool Spark Build. Only way to code the core now is via USB and to do this you have to change the firmware mode to DFU http://docs.spark.io/#/connect/appendix-dfu-mode-device-firmware-upgrade
Thanks for sharing your project @tylerwp, this looks sweet!!!
I'll try to answer the questions you've posed above piece by piece below:
You typically put the core in dfu mode when you want to flash it locally over USB via dfu-util. If you simply tap the reset button and get back to the breathing cyan state, you can flash it via the Web IDE again. You can use either approach. Additionally, if you are into developing code locally, you should check out the Spark CLI tool . It supports the ability to develop in the local IDE of your choosing, use the cloud to compile, and then flash via usb or over wifi. Lots of options--depends on your preferences.
You can use whatever text editor you prefer. For Windows Notepad++ is a good free option, for Mac, TextMate is a good free option. For make to work (and successfully compile a flashable firmware binary over dfu-util), you'll need to install the build tools documented in the core-firmware.
You probably want to check out the TCPClient library documented here. Provided it's not https (just http), this should work for you if you want to control the GoPro directly from the core.
So this is what I tried based on your feedback.
I used Spark Build to write my code and used TCPClient. Tests with TCPClient were successful (to google IP)
When my code was ready and uploaded to my core I used putty to connect to my core and change the wifi settings.
After settings were changed I would get a flashing green light. I tried a few other security settings but still no luck.
I was able to connect to the core again with putty and change the settings back to my wifi so I know it works.
Just can’t figure out why it wont connect to the gopro’s wifi. I’ll keep at it
I’ve run into a problem when the Spark Core is connected to Wifi with no internet.
This could also be the problem I’m having with the GoPro. So I did a test….
I loaded up the Blinking LED App to my Spark while connected to WiFi with Internet.
The LED blinks fine. I then unplugged the internet from the WiFi router and reset the Spark.
The LED App never runs and I get a flashing error code.
@jgoggins Will the Apps only run if the Spark has access to the internet?
@tylerwp
With the way the Core is currently configured, it will need an access to the internet (since it needs to connect to the Spark Cloud). Every command you send to the Core goes via the Cloud and then to the Core. If you were running local applications that did not require WiFi connectivity, then is would be possible run them without being connected to the internet.
In your use case, what you are looking for is a WiFi remote control that requires no internet connectivity. I’m afraid this won’t be possible with the Core in its current form. You’ll need to change the firmware significantly to make this work.
There are new include files and functions to turn cloud access on and off and this whole area is under active review by the Spark team. You can turn the cloud requirement off with Spark.disconnect() today.