Exploring BeagleBone
V1.0
|
A class to control a basic PWM output – you must know the exact sysfs filename for the PWM output. More...
#include <PWM.h>
Public Types | |
enum | POLARITY { ACTIVE_LOW =0, ACTIVE_HIGH =1 } |
Public Member Functions | |
PWM (string pinName) | |
virtual int | setPeriod (unsigned int period_ns) |
virtual unsigned int | getPeriod () |
virtual int | setFrequency (float frequency_hz) |
virtual float | getFrequency () |
virtual int | setDutyCycle (unsigned int duration_ns) |
virtual int | setDutyCycle (float percentage) |
virtual unsigned int | getDutyCycle () |
virtual float | getDutyCyclePercent () |
virtual int | setPolarity (PWM::POLARITY) |
virtual void | invertPolarity () |
virtual PWM::POLARITY | getPolarity () |
virtual void | setAnalogFrequency (float frequency_hz) |
virtual int | calibrateAnalogMax (float analogMax) |
virtual int | analogWrite (float voltage) |
virtual int | run () |
virtual bool | isRunning () |
virtual int | stop () |
virtual | ~PWM () |
exploringBB::PWM::PWM | ( | string | pinName | ) |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
inlinevirtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |