automated (HW-unit-)tests + DMA cleanup
This branch is based on the !1 (merged) and as such should only be merged after !1 (merged) has been merged.
While cleaning up the DMA driver and fixing possible bugs that didn't show up yet just by chance, I created some tests that can be automatically run on a target MSP430 to test the code. There are currently 2 tests: dma
and checkpoint
. While dma
verifies correct behaviour of the both dma_memcpy()
and dma_memset()
, test/checkpoint
requires an intermittent power supply in order to verify that basic checkpointing works.
There are (not yet very specific) assumptions about the test environment, so let's take this as a starting point to what makes sense. For now, a "test" means that the program is run approx. for 1 second and then the content of some variable is checked to decide whether the test has passed or failed. These conditions can be defined like var_a >= 42
or array_b != 01020304
(see tests/dma/test_dma.expect and tests/checkpoint/test_checkpoint.expect for reference).
What do you think?