12 Commits

Author SHA1 Message Date
Uwe Hermann
83f5c58eb9 Switch the license to GPL, version 3 or later. 2009-07-18 16:27:47 +02:00
Uwe Hermann
915d5bff90 Implement the simplest possible (working) blinking LED example application.
This is the first working example code which is tested on hardware.
The LED on the Olimex STM-H103 eval board is happily blinking.

We use a dummy "delay" function (basically a busy-waiting for-loop), which
will only work if you use -O0 in CFLAGS (-O2, -O3, or -Os will not work as
the compiler optimizes the loop away).

We use some arbitrary value for stack size (2 KB) and use main()
directly as the reset vector function. This will change later.

Also, we do the GPIO and clock init as well as the GPIO toggling for the
LED blinking fully "manually" for now, but there may be more higher-level
functions for doing that at some later date.
2009-07-18 06:09:08 +02:00
Uwe Hermann
526cb01aaa Silence OpenOCD per default, use V=1 for more verbose output. 2009-07-18 05:23:56 +02:00
Uwe Hermann
8d2190a86a Have *.o files depend on Makefile, in case we change gcc -O values there. 2009-07-18 05:17:49 +02:00
Uwe Hermann
10890b3f15 Don't use OpenOCD's "resume" command, only "reset" will work correctly.
Also, make the 'flash' target depend on 'images'.
2009-07-18 05:00:48 +02:00
Uwe Hermann
d7ec6a2983 Make 'flash' target a bit more generic and drop absolute paths. 2009-07-18 02:25:38 +02:00
Uwe Hermann
cf7d4df189 Make OpenOCD location easily configurable by using a variable. 2009-07-18 01:31:08 +02:00
Uwe Hermann
e04cec3b5d Add 'make flash' target using recent OpenOCD versions. 2009-07-17 23:03:42 +02:00
Uwe Hermann
bdba3af3a6 Create bin, hex, srec, and list files for the example project. 2009-07-16 15:49:28 +02:00
Uwe Hermann
3a2c63129e Use a Linux kernel style build output printing.
Example:

$ make install
  BUILD   lib
  CC      gpio.o
  AR      libopenstm32.a
  BUILD   example
  CC      blink.o
  LD      blink
  INSTALL headers
  INSTALL lib

$ make clean
  CLEAN   blink.o
  CLEAN   blink
  CLEAN   gpio.o
  CLEAN   libopenstm32.a
2009-07-16 15:15:26 +02:00
Uwe Hermann
1c459b8c48 Add 'make V=1' support for the example blink code. 2009-07-16 14:59:06 +02:00
Uwe Hermann
0efee48451 Add first example project (framework) using libopenstm32.
This is intended as a small blink example for the Olimex STM32-H103 board.
It doesn't do anything useful (yet), but it builds fine.

There's a sample Makefile and a preliminary ld script (which probably
needs some more work).
2009-07-16 14:29:00 +02:00