nRF Connect SDK API 3.4.99
Loading...
Searching...
No Matches

◆ pulse_meas_stop()

int pulse_meas_stop ( const struct device * dev,
bool immediate )

#include <include/drivers/pulse_meas.h>

Stop pulse width measurement.

The function is non-blocking. When immediate is true, the function stops sampling immediately and discards any incomplete series.

When immediate is false, the driver completes the current series before stopping hardware. While that series is still in progress, pulse_meas_get returns -EAGAIN.

Parameters
devPointer to the pulse width measurement device.
immediateStop sampling immediately and discard any incomplete series.
Return values
0On success.
-EINVALInvalid argument.