Hello,
I'm developing a program using nrf52832 DK and SDK V15.
I want to activate the SPI transmission when NRF_RADIO->EVENTS_END occurs using the PPI. I follow the PPI example that I found in the SDK. When I insert in my code the pp_init()
function
static void ppi_init(void) { err_code = nrf_drv_ppi_init(); //I stuck here, before nrf_drv_ppi_channel_alloc() function err_code = nrf_drv_ppi_channel_alloc(&m_ppi_channel1); err_code = nrf_drv_ppi_channel_assign(m_ppi_channel1,(uint32_t)&NRF_RADIO->EVENTS_END, nrf_drv_spi_start_task_get(&spi)); nrf_drv_ppi_channel_enable(m_ppi_channel1); }
I get stuck in a loop (the code jump directly to ther else statement):
/** * Function examines current header and omits pushed strings and packets which are in progress. */ static bool invalid_packets_pushed_str_omit(nrf_log_header_t const * p_header, uint32_t * p_rd_idx) { bool ret = false; if ((p_header->base.generic.type == HEADER_TYPE_PUSHED) || (p_header->base.generic.in_progress == 1)) { if (p_header->base.generic.in_progress == 1) { switch (p_header->base.generic.type) { case HEADER_TYPE_STD: *p_rd_idx += (HEADER_SIZE + p_header->base.std.nargs); break; case HEADER_TYPE_HEXDUMP: *p_rd_idx += (HEADER_SIZE + p_header->base.hexdump.len); break; default: ASSERT(0); break; } } else { *p_rd_idx += (PUSHED_HEADER_SIZE + p_header->base.pushed.len + p_header->base.pushed.offset); } ret = true; } return ret; }