The instructions require an STLINK/V2 ($21 and less off the web) which I don’t have of course.
So can I use the JLink EDU. First challenge is getting the connector right. Which is pin #1?
I’ve written the canonical LED flasher program, but now I’m trying to figure out what port.pin the LEDs are on. Back to the Schematic…
timer_start(); blink_led_init();
// Infinite loop while (1) { blink_led_on(); timer_sleep(BLINK_ON_TICKS); blink_led_off(); timer_sleep(BLINK_OFF_TICKS); }
OK, it looks like I can talk to the EVB1000 because I seem to have nixed the program that was in it, so clearly something got flashed. But the program isn’t starting…
This CodeSorcery compiler looks like it needs a different set of startup files. I wonder if I can get it to work under the gcc compiler instead.
Recompile, and change a few settings…
Poked around a bit more and managed to find out how to get the semi-hosting to work too.
STM32F10X_CLTRACEOS_USE_TRACE_SEMIHOSTING_DEBUGUSE_STDPERIPH_DRIVERHSE_VALUE=8000000
// Note: Applications built with semihosting output active cannot be
// executed without the debugger connected and active, since they use
// BKPT to communicate with the host. Attempts to run them standalone or
// without semihosting enabled will usually be terminated with hardware faults.