Blockly without Arduino IDE install

267 views
Skip to first unread message

puttley

unread,
Dec 16, 2018, 11:45:08 AM12/16/18
to Blockly
Does anyone have knowledge of how to compile arduino code generated by Blockly into a HEX file without dependency on the Arduino IDE being installed? There are examples of Blockly apps which compile and upload arduino sketch code, but all seem to be dependent on the Arduino IDE being installed. I would like to (1) - generate a HEX file with a button click, or (2) compile to hex and upload with a button click without needing to have the Arduino IDE installed.

Noah Glaser

unread,
Dec 16, 2018, 2:25:07 PM12/16/18
to Blockly
So I did this with my with an electron app.  I am going to be renaming it this the next release. You can upload the hex file using a node package avr-girld arduino.

I send the Arduino code up to a server and have it compile into hex code.   Here is the code for that. 

I think that's the best way to go because compiling the Arduino code on each os is a giant pain.  

Here is the code that creates the hex file.  It's a node server that runs the Arduino mk-arduino makefile. 

Right now I am redoing the blocks for this and I will be shortly coming out with a series of youtube video instructions on how to do cool projects.  I also teach with this at a library and museum so I have been getting a lot of feedback on my block designs and adjusting.   I also going to be taking the server and wrapping it in docker file so that it can be used without internet.

Hope this was helpful

Thank you

Noah

puttley

unread,
Dec 16, 2018, 8:57:56 PM12/16/18
to Blockly
Thanks for sharing your work, Noah. I hope we will continue to see more development with Blockly + Arduino connecting these two popular and growing platforms. My wish is to create a Blockly + Arduino app for use on Chromebook. I am also in education, and in need of Blocks + Arduino + Chromebook.

Noah Glaser

unread,
Dec 16, 2018, 11:07:31 PM12/16/18
to Blockly
It looks like I should have gone with NW.js which supports chrome books.  I imagine it would not be hard to take the js and migrate it to support it though.  I will make an issue on my repo and see what's involved.  Good luck with everything.


On Sunday, December 16, 2018 at 8:45:08 AM UTC-8, puttley wrote:

puttley

unread,
Dec 17, 2018, 2:23:59 PM12/17/18
to Blockly
Thanks, Noah. I've created a Blockly + Arduino Leonardo + WebUSB  web app that communicates via a serial bit stream with my own firmata. Do you think WebUSB could be possibly be used to upload arduino code?

Noah Glaser

unread,
Dec 18, 2018, 4:42:03 AM12/18/18
to Blockly
Unfortunately, to my knowledge, it's not.    I would love to see how you did what you did with firmata though.  That sounds very promising.

Here's some more info on the webusb stuff.  Once that is possible I am turning the desktop app into a website.  It's a little over my head, to be honest.  

Reply all
Reply to author
Forward
0 new messages