News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

Use "Build -> Run" to execute something else

Started by pyrohaz, November 09, 2015, 12:06:25 AM

Previous topic - Next topic

pyrohaz

Hi all,

I've got Codeblocks configured with SDCC, along side the STM8 series of microcontrollers. I can compile and link fine along with generate the .hex file required. Currently, I have the .hex file being uploaded to the STM8 after the build process has completed. What I'm wondering is can I change what the Build->Run command does to instead of trying to execute the program in windows, execute the ST uploader from command line and upload to the microcontroller?

Thanks,
Harris

oBFusCATed

You can do this using a post build step or using a tool.
You can probably setup another commands only target to do this.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

scarphin

Or use the Toolsplus plugin to define custom commands to program your microcontroller or execute the code etc...

pyrohaz

Quote from: scarphin on November 09, 2015, 09:44:59 AM
Or use the Toolsplus plugin to define custom commands to program your microcontroller or execute the code etc...

Aha! I didn't know such a thing existed. I've now created a Toolsplus macro.

Thank you all for your replies!

ouch

You might be able to create a new compiler profile for it too. That would make the build, run etc buttons work like normal for your micro.

settings->compiler and then click on copy, name it whatever and then just edit the directory and toolchain executables to whatever your microcontroller software needs.