PxPeChange()
Change the period and events associated with Pe.
- APPLIES TO
-
1.0.0
- SYNOPSIS
-
PxError_t PxPeChange (PxPe_t Pe, PxTicks_t period, PxEvents_t events);
- ARGUMENTS
|
|
|
|
|
- RETURN VALUES
-
-
PXROS error code
-
- ERROR CODES
-
PXERR_PE_ILLPE
Pe
is not a valid periodic event handler objectPXERR_REQUEST_ILLEGAL
The caller is not the requester of the Pe object
- DESCRIPTION
-
PxPeChange changes the period and events associated with Pe. It implicitly stops Pe.
- IMPLEMENTATION GUIDELINES
-
- Before call
-
-
PeId
must be a valid PXROS-HR periodic event object created with aPxPeRequest
call (V). The validity ofPeId
may also be checked by thePxPeIsValid
macro (F). -
The
period
parameter must have a plausible value. It should be a constant or the result of aPxTickGetTicksFromMilliSeconds
call (V); -
The parameter
events
contains an event bit and should not be zero. Typically the event is a constant (V).
-
- After call
-
-
The function returns
PXERR_NOERROR
if the periodic event could be changed. Any other return value describes an error, which has to be interpreted (C).
-
- Best Practice
-
-
No restrictions.
-
- SEE ALSO
- USAGE
-
#include "pxdef.h" #define MY_EVENT 0x1l PxError_t Err = PxPeChange(Pe, 10, MY_EVENT); if (Err != PXERR_NOERROR) { // Report error }