Author Topic: Gnu Arm Eclipse OpenOCD: Building project without trace/semihosting  (Read 2463 times)

0 Members and 1 Guest are viewing this topic.

Offline BurnedResistorTopic starter

  • Regular Contributor
  • *
  • Posts: 192
  • Country: at
After successfully following this book: https://leanpub.com/mastering-stm32 (really good resource btw), I was able to get an stm32f4 disco devboard up and running with the gnu arm eclipse toolchain. I also successfully ran the blinky program with tracing and semihosting. However, as excpected this firmware willl only run properly if a debugger is connected, which makes sense!

However I would like to know if there is a simple software switch or other option to compile the program without this functionality to allow for it to run freestanding and at full speed without the overhead of the extra tracing functionality, however was not able to find a solution for this. Does anybody know how this could be achieved?
 

Offline HackedFridgeMagnet

  • Super Contributor
  • ***
  • Posts: 2045
  • Country: au
Re: Gnu Arm Eclipse OpenOCD: Building project without trace/semihosting
« Reply #1 on: August 08, 2016, 10:24:15 pm »
This thread tells you how to turn it on. so if you work backwards.

http://www.openstm32.org/forumthread1530
 

Offline BurnedResistorTopic starter

  • Regular Contributor
  • *
  • Posts: 192
  • Country: at
Re: Gnu Arm Eclipse OpenOCD: Building project without trace/semihosting
« Reply #2 on: August 08, 2016, 10:44:27 pm »
This thread tells you how to turn it on. so if you work backwards.

http://www.openstm32.org/forumthread1530


It seems that the tread focuses on enabling the trace in openOCD which i already have working. However by the time openOCD gets its hands on the program it is already compiled and therefor to late to enable or disable the tracing code. I was looking to see if there was a step in the ide/the compiler/the headers which enabled me to disable or exclude the tracing code. Maybe even as a seperate run configuration? That would be great as it would allow me to switch really quickly!

Thank you for your help in any case! :)
 

Offline mac.6

  • Regular Contributor
  • *
  • Posts: 226
  • Country: fr
Re: Gnu Arm Eclipse OpenOCD: Building project without trace/semihosting
« Reply #3 on: August 10, 2016, 07:11:06 am »
As far as I remember just link with nosys instead of rdimon library, it's just a -specs=rdimon.specs to change to -specs=nosys.specs in the linker parameters.
 
The following users thanked this post: Muxr


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf

 

- - -
-->