This is an old version of the documentation. View the latest version
here.
Control Surface
1.0.0
MIDI Control Surface library for Arduino
|
Go to the documentation of this file.
131 virtual void begin() = 0;
143 virtual void update() = 0;
virtual void pinMode(pin_t pin, uint8_t mode)=0
Set the mode of a given pin.
uint16_t pin_t
The type for Arduino pins (and ExtendedIOElement pins).
virtual void update()=0
Update the extended IO element: write the internal state to the physical outputs, or read the physica...
virtual ~ExtendedIOElement()
pin_t getStart() const
Get the smallest global extended IO pin number that belongs to this extended IO element.
pin_t operator[](pin_t pin) const
Get the extended IO pin number of a given physical pin of this extended IO element.
#define BEGIN_CS_NAMESPACE
uint16_t analog_t
The type returned from analogRead and similar functions.
pin_t getLength() const
Get the number of pins this IO element has.
pin_t getEnd() const
Get the largest global extended IO pin number that belongs to this extended IO element.
pin_t pin(pin_t pin) const
Get the extended IO pin number of a given physical pin of this extended IO element.
static DoublyLinkedList< ExtendedIOElement > & getAll()
Get the list of all Extended IO elements.
An abstract base class for Extended Input/Output elements.
virtual void digitalWrite(pin_t pin, uint8_t state)=0
Set the output of the given pin to the given state.
virtual void analogWrite(pin_t pin, analog_t val)=0
Write an analog (or PWM) value to the given pin.
A class that can be inherited from to allow inserting into a DoublyLinkedList.
static DoublyLinkedList< ExtendedIOElement > elements
virtual void begin()=0
Initialize the extended IO element.
ExtendedIOElement(pin_t length)
Create an ExtendedIOElement with the given number of pins.
static void beginAll()
Initialize all extended IO elements.
virtual int digitalRead(pin_t pin)=0
Read the state of the given pin.
virtual analog_t analogRead(pin_t pin)=0
Read the analog value of the given pin.