blob: 931a09aabcd22be69e734a885725f3e163f54e5a [file] [log] [blame]
Kévin Redon69b92d92019-01-24 16:39:20 +01001#include <atmel_start.h>
2
Kévin Redonc94e0fc2019-03-07 19:15:29 +01003/** Memory to memory DMA callback */
4static void M2M_DMA_complete_cb(void)
5{
6 dma_m2m_complete_flag = true;
7}
8
Kévin Redon69b92d92019-01-24 16:39:20 +01009/**
10 * Initializes MCU, drivers and middleware in the project
11 **/
12void atmel_start_init(void)
13{
14 system_init();
Kévin Redonc94e0fc2019-03-07 19:15:29 +010015 dma_memory_init();
16 dma_memory_register_callback(DMA_MEMORY_COMPLETE_CB, M2M_DMA_complete_cb);
Eric Wild22887032019-11-27 18:10:39 +010017#ifdef ENABLE_DBG_UART7
18 stdio_redirect_init();
19#endif
Harald Welte34a87062019-04-19 22:33:36 +020020 usb_init();
Kévin Redon69b92d92019-01-24 16:39:20 +010021}