Restore old makefile
fix issues and switch to new makefile

- organized build tree in the out folder
- link freeRTOS in the final binary