Uh oh!
There was an error while loading. Please reload this page.
Univ ldma handler dev - #68
Conversation
… only be 1. Modified logger-ldma to use universal handler.
…ting up false flags.
Seems that logger_ldma is expecting some other flag to function properly. Currently unable to fix logger_ldma myself (Lembitu). Went with easier approach letting logger_ldma to accept both flags. Currently seems to work. TODO: make actual fix
| #define SIZE_OF_ARRAY(arr) (sizeof(arr))/sizeof(arr[0]) | ||
| static volatile ldma_handler_conf_t m_head; | ||
| static volatile ldma_handler_conf_t m_head = {0xFF, NULL, 0, 0, NULL}; |
There was a problem hiding this comment.
Use structre members names to initialize them e.g. const osThreadAttr_t app_thread_attr = { .name = "app" };
| while(ptr != NULL) | ||
| { | ||
| if ( pending & (1<<ptr->channel) ) | ||
| if ( pending & (1 << ptr->channel) ) |
There was a problem hiding this comment.
BARR - remove spaces if ((pending & (1 << ptr->channel)))
| ldma_handler_conf_t* ptr = &m_head; | ||
| while(ptr != NULL) |
| { | ||
| if ( pending & (1<<ptr->channel) ) | ||
| if ( pending & (1 << ptr->channel) ) | ||
| { |
There was a problem hiding this comment.
Identation - open all files in editor and convert tabs to spaces and check after that the indentation is correct
| m_ldma_handler_conf.signal = LOGGER_THREAD_FLAG_LDMA_DONE; | ||
| m_ldma_handler_conf.thrd = &m_ldma_thread; | ||
| m_ldma_handler_conf.thrd = m_ldma_thread; | ||
| m_ldma_handler_conf.name = 69; |
There was a problem hiding this comment.
Use constants instead of mystical numbers. e.g. #define DEFAULT_CONF_NAME 69
raidoz
commented
Mar 3, 2022
This looks to duplicate functionality already provided by dmadrv.h ... which the logger already supports. dmadrv.h is also used by DALI and smenete microphones/microwave and there they all work together merrily. |
This adds universal LDMA handler.
Before only logger could use LDMA now through this handler any application is able to interface with LDMA.