0
votes

The program I am trying to compile for my arduino micro does not compile in the 'standard' arduino IDE. The reason is subject to a completely different topic discussed at the arduino forum. Cut a long story short, I write pure C and the arduino GUI only does C++. Trust me, I have tried to tweak the interface so it would use avr-gcc, but you enter in an infinite compile - error - refactor loop. I need an other solution.

I am using code::blocks as IDE and want to flash the avr-gcc compiled code onto the arduino micro board using avr-dude on linux kubuntu machine. How would one achieve this?

Problem is I have been running in circles for quite some time now trying to find the correct command line arguments or code:blocks post compiler settings. All information out there is either very old or irrelevant.

I'll keep you posted if I find relevant info

2
I just use the port of Code::Blocks that's been adapted to the task. It's every bit as easy as the official IDE, without the horror of Java on the machine or the painful project management tools. Try this on for size: arduinodev.com/codeblocksenhzflep
I have tried this link, with very small positive feed-back, plus,using repo's over 5 years old with no activity, I am a bit wearyhewi

2 Answers

1
votes
avrdude -V -F -C <avrdude.conf> -p <processor> -P <tty-port> -c stk500v1 -b <baud-rate> -U flash:w:<your-application>.hex

An easy way to see all the settings and get a suitable command line for your system is to use the Arduino gui. Enable verbose upload in the preferences, then program in a basic program like blink. Copy/paste that command line and change the hex file.

0
votes

I did it here

here

body 24262830