Mercurial > public > ostc4
comparison Small_CPU/Src/baseCPU2.c @ 207:b95741467355 ImprovmentSPI
Introduce scheduler function
The first implementation was only focussed on doing a hard sync and the new one uses an interface instead of global variables
author | ideenmodellierer |
---|---|
date | Sun, 24 Mar 2019 22:53:17 +0100 |
parents | 9baecc0c24b2 |
children | e4207f0aaa4b |
comparison
equal
deleted
inserted
replaced
206:0bb6a8e7be9d | 207:b95741467355 |
---|---|
377 } | 377 } |
378 SPI_synchronize_with_Master(); | 378 SPI_synchronize_with_Master(); |
379 MX_DMA_Init(); | 379 MX_DMA_Init(); |
380 MX_SPI1_Init(); | 380 MX_SPI1_Init(); |
381 SPI_Start_single_TxRx_with_Master(); /* be prepared for the first data exchange */ | 381 SPI_Start_single_TxRx_with_Master(); /* be prepared for the first data exchange */ |
382 dohardspisync = 1; | 382 Scheduler_Request_sync_with_SPI(SPI_SYNC_METHOD_HARD); |
383 EXTI_Test_Button_Init(); | 383 EXTI_Test_Button_Init(); |
384 global.mode = MODE_SURFACE; | 384 global.mode = MODE_SURFACE; |
385 break; | 385 break; |
386 | 386 |
387 case MODE_CALIB: | 387 case MODE_CALIB: |