Lines Matching refs:channel

64 static bool channel_is_allocated(uint8_t channel)  in channel_is_allocated()  argument
66 return ((m_allocated_channels & DPPI_BIT_SET(channel)) != 0); in channel_is_allocated()
106 uint8_t channel = 0; in nrfx_dppi_channel_alloc() local
116 while (!(remaining_channels & DPPI_BIT_SET(channel))) in nrfx_dppi_channel_alloc()
118 channel++; in nrfx_dppi_channel_alloc()
121 m_allocated_channels |= DPPI_BIT_SET(channel); in nrfx_dppi_channel_alloc()
122 *p_channel = channel; in nrfx_dppi_channel_alloc()
125 NRFX_LOG_INFO("Allocated channel: %d.", channel); in nrfx_dppi_channel_alloc()
129 nrfx_err_t nrfx_dppi_channel_free(uint8_t channel) in nrfx_dppi_channel_free() argument
133 if (!channel_is_allocated(channel)) in nrfx_dppi_channel_free()
140 nrf_dppi_channels_disable(NRF_DPPIC, DPPI_BIT_SET(channel)); in nrfx_dppi_channel_free()
142 m_allocated_channels &= ~DPPI_BIT_SET(channel); in nrfx_dppi_channel_free()
148 nrfx_err_t nrfx_dppi_channel_enable(uint8_t channel) in nrfx_dppi_channel_enable() argument
152 if (!channel_is_allocated(channel)) in nrfx_dppi_channel_enable()
158 nrf_dppi_channels_enable(NRF_DPPIC, DPPI_BIT_SET(channel)); in nrfx_dppi_channel_enable()
164 nrfx_err_t nrfx_dppi_channel_disable(uint8_t channel) in nrfx_dppi_channel_disable() argument
168 if (!channel_is_allocated(channel)) in nrfx_dppi_channel_disable()
174 nrf_dppi_channels_disable(NRF_DPPIC, DPPI_BIT_SET(channel)); in nrfx_dppi_channel_disable()
228 nrfx_err_t nrfx_dppi_channel_include_in_group(uint8_t channel, in nrfx_dppi_channel_include_in_group() argument
233 if (!group_is_allocated(group) || !channel_is_allocated(channel)) in nrfx_dppi_channel_include_in_group()
239 nrf_dppi_channels_include_in_group(NRF_DPPIC, DPPI_BIT_SET(channel), group); in nrfx_dppi_channel_include_in_group()
245 nrfx_err_t nrfx_dppi_channel_remove_from_group(uint8_t channel, in nrfx_dppi_channel_remove_from_group() argument
250 if (!group_is_allocated(group) || !channel_is_allocated(channel)) in nrfx_dppi_channel_remove_from_group()
256 nrf_dppi_channels_remove_from_group(NRF_DPPIC, DPPI_BIT_SET(channel), group); in nrfx_dppi_channel_remove_from_group()