Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion drivers/adc/adc_nrfx_saadc.c
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,7 @@ static inline void single_ended_channel_cut_negative_sample(uint16_t channel_bit
uint8_t single_ended_channels,
int16_t **sample)
{
if ((channel_bit & single_ended_channels) && (*sample < 0)) {
if ((channel_bit & single_ended_channels) && (**sample < 0)) {
**sample = 0;
}

Expand Down Expand Up @@ -755,6 +755,7 @@ static void event_handler(const nrfx_saadc_evt_t *event)
correct_single_ended(&m_data.ctx.sequence, m_data.user_buffer,
event->data.done.size);
}
nrfy_saadc_disable(NRF_SAADC);
adc_context_on_sampling_done(&m_data.ctx, DEVICE_DT_INST_GET(0));
} else if (event->type == NRFX_SAADC_EVT_CALIBRATEDONE) {
err = nrfx_saadc_mode_trigger();
Expand Down
Loading