Add first generic API testing routine

build with make BOARD=stm32f0discovery