The pwm_in_channel class.
This class holds the configuration and value for a single PWM input channel.
#include <pwm_in_channel.h>
The pwm_in_channel class.
This class holds the configuration and value for a single PWM input channel.
◆ pwm_in_channel() [1/4]
The class constructor.
- Parameters
-
| desc | The channel configuration. |
- See also
- pwm_in_descriptor
◆ pwm_in_channel() [2/4]
◆ pwm_in_channel() [3/4]
| vsdk::io::pwm_in_channel::pwm_in_channel |
( |
const pwm_in_channel & | other | ) |
|
|
delete |
◆ pwm_in_channel() [4/4]
◆ descriptor()
Return a descriptor with the channel configuration used when the class was instantiated.
- Returns
- A pwm_in_descriptor object.
◆ operator=() [1/2]
Standard assignment operators
◆ operator=() [2/2]
Standard assignment operators
◆ process_notification()
|
|
overrideprotectedvirtualnoexcept |
Process event notifications for PWM input channels.
This method handles the following event types:
- Threshold events (above/below)
- Range events (in/out of range)
Events are generated only when the conditions are met, and are pushed to the notification queue specified in the descriptor.
- Parameters
-
| desc | The event notification descriptor containing:
- source: The PWM input source (pwm_in0 or pwm_in1)
- type: The event type (threshold or range)
- value: The trigger value (double for threshold, range_value for range)
- queue: The event queue to receive notifications, for more see vsdk::io::event_notification_descriptor.
|
- Returns
- True if the notification was processed, false otherwise
Implements vsdk::io::event_notification.
◆ read()
| pwm_result vsdk::io::pwm_in_channel::read |
( |
| ) |
const |
Read the current value of the channel.
- Returns
- A pwm_result containing the status and value for the channel in Hz.
The documentation for this class was generated from the following file: