the "make clean" target showed a constant "stm32/f1" debug message
instead of the current relative directory. this is fixed by showing the
relevant portion of the current directory instead, relevant being
determined by evaluating the current makefile's relative position and
stripping that part off.
vector.o, nvic.o, scb.o and assert.o are available on every platform,
but at least some of them differ between the implementations. they
already got built explicityly on some platforms; now adding them to the
common Makefile.include.
Add object files to Makefile to include new modules into lib.
Correct typo in pwr.c
Add two new functions to timer.c to preset the counter (for use
with deadman style timeouts) and to identify an interrupt
source.
Also noticed lib/makefile.include didn't clean lib/stm32, which
isn't a target. Added a fix.
- The library files are now being built into the lib subdirectory of the
source.
- The linker files for each library are being copied into the lib source
subdirectory.
Motivation: The relative locations of files in the source directory after make
are now the same as after make install now. This makes it easier to
reuse examples with their makefiles outside of the libopencm3
sourcecode directory.
Changed the license to LGPL3+ for some makefiles that got ommited in the
previous big patch commit.
Corrected a find and replace error in a linker file.
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.
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).