Tripple Controller for the TLE5206 H Bridge motor controller
SimpleTLE5206Output Class Reference
SimpleTLE5206Output - Adds pin output objects. More...
#include <SimpleTLE5206Output.h>
Public Member Functions | |
SimpleTLE5206Output (PinName p, Direction d=Out, PinMode m=PullDown) | |
Constructor. | |
void | write (int i) |
write | |
int | read (void) |
read | |
void | output (void) |
output | |
void | input (void) |
input | |
PinName | getPin (void) |
getPin | |
int | getDirection (void) |
getDirection | |
operator int () | |
operator int() | |
SimpleTLE5206Output & | operator= (int value) |
operator= | |
SimpleTLE5206Output & | operator= (SimpleTLE5206Output &rhs) |
operator= | |
uint32_t | getMask (void) |
getMask | |
uint32_t | getFiodir (void) |
getFiodir | |
uint32_t | getFiomask (void) |
getFiomask | |
uint32_t | getFiopin (void) |
getFiopin | |
uint32_t | getFioset (void) |
getFioset | |
uint32_t | getFioclr (void) |
getFioclr |
Detailed Description
SimpleTLE5206Output - Adds pin output objects.
The Mbed library supplies the DigitalIn and DigitalOut objects to allow you to specify ins and outs.
SimpleTLE5206Output allows library objects to implement pins without the requirement to link against the Mbed library. This increase portability when using alternate compilers (such as the Code Red GCC C++ compiler for LPCXpresso).
Additionally, this class allows the pin to be configured as a GPIO output or swapped to PWM output mode.
Note, this class can only be used for pins p21 through p26 as these are used for PWM pins. Trying to set this to any other pin will result in a fatal error() call.
Definition at line 53 of file SimpleTLE5206Output.h.
Constructor & Destructor Documentation
SimpleTLE5206Output | ( | PinName | p, |
Direction | d = Out , |
||
PinMode | m = PullDown |
||
) |
Constructor.
Definition at line 93 of file SimpleTLE5206Output.h.
Member Function Documentation
int getDirection | ( | void | ) |
getDirection
Get the operational direction this pin is setup for.
- Returns:
- int 0v returns zero, otherwise returns 1.
Definition at line 162 of file SimpleTLE5206Output.h.
uint32_t getFioclr | ( | void | ) |
getFioclr
Get the FIOCLR register for the port the pin is on.
- Returns:
- uint32_t The register value.
Definition at line 253 of file SimpleTLE5206Output.h.
uint32_t getFiodir | ( | void | ) |
getFiodir
Get the FIODIR register for the port the pin is on.
- Returns:
- uint32_t The register value.
Definition at line 213 of file SimpleTLE5206Output.h.
uint32_t getFiomask | ( | void | ) |
getFiomask
Get the FIOMASK register for the port the pin is on.
- Returns:
- uint32_t The register value.
Definition at line 223 of file SimpleTLE5206Output.h.
uint32_t getFiopin | ( | void | ) |
getFiopin
Get the FIOPIN register for the port the pin is on.
- Returns:
- uint32_t The register value.
Definition at line 233 of file SimpleTLE5206Output.h.
uint32_t getFioset | ( | void | ) |
getFioset
Get the FIOSET register for the port the pin is on.
- Returns:
- uint32_t The register value.
Definition at line 243 of file SimpleTLE5206Output.h.
uint32_t getMask | ( | void | ) |
getMask
Get the mask value for this pin.
- Returns:
- uint32_t The mask value used by this pin.
Definition at line 203 of file SimpleTLE5206Output.h.
PinName getPin | ( | void | ) |
getPin
Get the PinName this object is operating on.
- Returns:
- int 0v returns zero, otherwise returns 1.
Definition at line 152 of file SimpleTLE5206Output.h.
void input | ( | void | ) |
input
Setup the pin to be an input.
- Returns:
- int 0v returns zero, otherwise returns 1.
Definition at line 142 of file SimpleTLE5206Output.h.
operator int | ( | ) |
operator int()
Reads the value on the pin.
- Returns:
- int 0v returns zero, otherwise returns 1.
Definition at line 173 of file SimpleTLE5206Output.h.
SimpleTLE5206Output& operator= | ( | int | value ) |
SimpleTLE5206Output& operator= | ( | SimpleTLE5206Output & | rhs ) |
void output | ( | void | ) |
output
Setup the pin to be an output.
- Returns:
- int 0v returns zero, otherwise returns 1.
Definition at line 132 of file SimpleTLE5206Output.h.
int read | ( | void | ) |
read
Reads the value on the pin.
- Returns:
- int 0v returns zero, otherwise returns 1.
Definition at line 121 of file SimpleTLE5206Output.h.
void write | ( | int | i ) |
write
Writes a value to the pin.
- Parameters:
-
i Zero makes the pin 0v, non-zero makes the pin 1.
Definition at line 111 of file SimpleTLE5206Output.h.
Generated on Tue Jul 12 2022 21:37:53 by 1.7.2