This is an old version of the documentation. View the latest version here.
Control Surface  1.0.0
MIDI Control Surface library for Arduino
Public Member Functions | Static Public Member Functions | Protected Attributes | Private Member Functions | Static Private Attributes | List of all members
MIDIInputElementPC Class Referenceabstract

#include <MIDIInputElementPC.hpp>

Inheritance diagram for MIDIInputElementPC:
Collaboration diagram for MIDIInputElementPC:

Public Member Functions

 MIDIInputElementPC (const MIDICNChannelAddress &address)
 Constructor. More...
 
virtual ~MIDIInputElementPC ()
 Destructor. More...
 
virtual void begin ()
 Initialize the input element. More...
 
virtual void reset ()
 Reset the input element to its initial state. More...
 
virtual void update ()
 Update the value of the input element. Used for decaying VU meters etc. More...
 
bool updateWith (const ChannelMessageMatcher &midimsg)
 Receive a new MIDI message and update the internal state. More...
 

Static Public Member Functions

static void beginAll ()
 
static void resetAll ()
 Reset all MIDIInputElementPC elements to their initial state. More...
 
static void updateAll ()
 Update all MIDIInputElementPC elements. More...
 
static void updateAllWith (const ChannelMessageMatcher &midimsg)
 Update all MIDIInputElementPC elements with a new MIDI message. More...
 

Protected Attributes

const MIDICNChannelAddress address
 
MIDIInputElementPCnext
 
MIDIInputElementPCprevious
 

Private Member Functions

MIDICNChannelAddress getTarget (const ChannelMessageMatcher &midimsg) const override
 Program Change doesn't have an address, so the target consists of just the channel and the cable number. More...
 
void moveDown ()
 Move down this element in the linked list of elements. More...
 
virtual bool updateImpl (const ChannelMessageMatcher &midimsg, const MIDICNChannelAddress &target)=0
 Update the internal state with the new MIDI message. More...
 
virtual bool match (const MIDICNChannelAddress &target) const
 Check if the address of the incoming MIDI message matches an address of this element. More...
 

Static Private Attributes

static DoublyLinkedList< MIDIInputElementPCelements
 

Detailed Description

Definition at line 15 of file MIDIInputElementPC.hpp.

Constructor & Destructor Documentation

◆ MIDIInputElementPC()

MIDIInputElementPC::MIDIInputElementPC ( const MIDICNChannelAddress address)
inline

Constructor.

Todo:
Documentation.

Definition at line 22 of file MIDIInputElementPC.hpp.

◆ ~MIDIInputElementPC()

virtual MIDIInputElementPC::~MIDIInputElementPC ( )
inlinevirtual

Destructor.

Todo:
Documentation.

Definition at line 32 of file MIDIInputElementPC.hpp.

Member Function Documentation

◆ beginAll()

static void MIDIInputElementPC::beginAll ( )
inlinestatic

Definition at line 37 of file MIDIInputElementPC.hpp.

◆ resetAll()

static void MIDIInputElementPC::resetAll ( )
inlinestatic

Reset all MIDIInputElementPC elements to their initial state.

See also
MIDIInputElementPC::reset

Definition at line 49 of file MIDIInputElementPC.hpp.

◆ updateAll()

static void MIDIInputElementPC::updateAll ( )
inlinestatic

Update all MIDIInputElementPC elements.

Definition at line 58 of file MIDIInputElementPC.hpp.

◆ updateAllWith()

static void MIDIInputElementPC::updateAllWith ( const ChannelMessageMatcher midimsg)
inlinestatic

Update all MIDIInputElementPC elements with a new MIDI message.

See also
MIDIInputElementPC::updateWith

Definition at line 70 of file MIDIInputElementPC.hpp.

◆ getTarget()

MIDICNChannelAddress MIDIInputElementPC::getTarget ( const ChannelMessageMatcher midimsg) const
inlineoverrideprivatevirtual

Program Change doesn't have an address, so the target consists of just the channel and the cable number.

Reimplemented from MIDIInputElement.

Definition at line 85 of file MIDIInputElementPC.hpp.

◆ moveDown()

void MIDIInputElementPC::moveDown ( )
inlineprivate

Move down this element in the linked list of elements.

This means that the element will be checked earlier on the next iteration.

Definition at line 95 of file MIDIInputElementPC.hpp.

◆ begin()

virtual void MIDIInputElement::begin ( )
inlinevirtualinherited

Initialize the input element.

Reimplemented in MCU::VPotRing_Base< NumValues, Callback >, MCU::VPotRing_Base< NumBanks, Callback >, MCU::VPotRing_Base< 1, VPotRingLEDsCallback >, MCU::VPotRing_Base< NumBanks, VPotEmptyCallback >, MCU::VPotRing_Base< 1, VPotEmptyCallback >, MCU::VPotRing_Base< 1, Callback >, MCU::VPotRing_Base< NumBanks, VPotRingLEDsCallback >, MCU::VU_Base< NumValues, Callback >, MCU::VU_Base< NumBanks, Callback >, MCU::VU_Base< NumBanks, VULEDsCallback< NumLEDs > >, MCU::VU_Base< NumBanks, VUEmptyCallback >, MCU::VU_Base< 1, VUEmptyCallback >, MCU::VU_Base< 1, VULEDsCallback< NumLEDs > >, MCU::VU_Base< 1, Callback >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCFastLED< ColorMapper > >, GenericProgramChangeSelector< N, Callback >, GenericProgramChangeSelector< N >, and GenericProgramChangeSelector< N, SelectorLEDsCallback< N > >.

Definition at line 30 of file MIDIInputElement.hpp.

◆ reset()

virtual void MIDIInputElement::reset ( )
inlinevirtualinherited

Reset the input element to its initial state.

Reimplemented in MCU::VPotRing_Base< NumValues, Callback >, MCU::VPotRing_Base< NumBanks, Callback >, MCU::VPotRing_Base< 1, VPotRingLEDsCallback >, MCU::VPotRing_Base< NumBanks, VPotEmptyCallback >, MCU::VPotRing_Base< 1, VPotEmptyCallback >, MCU::VPotRing_Base< 1, Callback >, MCU::VPotRing_Base< NumBanks, VPotRingLEDsCallback >, MCU::VU_Base< NumValues, Callback >, MCU::VU_Base< NumBanks, Callback >, MCU::VU_Base< NumBanks, VULEDsCallback< NumLEDs > >, MCU::VU_Base< NumBanks, VUEmptyCallback >, MCU::VU_Base< 1, VUEmptyCallback >, MCU::VU_Base< 1, VULEDsCallback< NumLEDs > >, MCU::VU_Base< 1, Callback >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCFastLED< ColorMapper > >, MCU::SevenSegmentDisplay< LENGTH >, MCU::SevenSegmentDisplay< AssignmentDisplayLength >, MCU::SevenSegmentDisplay< TimeDisplayLength >, GenericProgramChangeSelector< N, Callback >, GenericProgramChangeSelector< N >, and GenericProgramChangeSelector< N, SelectorLEDsCallback< N > >.

Definition at line 33 of file MIDIInputElement.hpp.

◆ update()

virtual void MIDIInputElement::update ( )
inlinevirtualinherited

◆ updateWith()

bool MIDIInputElement::updateWith ( const ChannelMessageMatcher midimsg)
inlineinherited

Receive a new MIDI message and update the internal state.

Definition at line 39 of file MIDIInputElement.hpp.

◆ updateImpl()

virtual bool MIDIInputElement::updateImpl ( const ChannelMessageMatcher midimsg,
const MIDICNChannelAddress target 
)
privatepure virtualinherited

Update the internal state with the new MIDI message.

Implemented in MCU::VPotRing_Base< NumValues, Callback >, MCU::VU_Base< NumValues, Callback >, MCU::VPotRing_Base< NumBanks, Callback >, MCU::VPotRing_Base< 1, VPotRingLEDsCallback >, MCU::VPotRing_Base< NumBanks, VPotEmptyCallback >, MCU::VPotRing_Base< 1, VPotEmptyCallback >, MCU::VPotRing_Base< 1, Callback >, MCU::VPotRing_Base< NumBanks, VPotRingLEDsCallback >, MCU::VU_Base< NumBanks, Callback >, MCU::VU_Base< NumBanks, VULEDsCallback< NumLEDs > >, MCU::VU_Base< NumBanks, VUEmptyCallback >, MCU::VU_Base< 1, VUEmptyCallback >, MCU::VU_Base< 1, VULEDsCallback< NumLEDs > >, MCU::VU_Base< 1, Callback >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCFastLED< ColorMapper > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementCC, RangeLen, 1, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, NumBanks, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCRangeEmptyCallback >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLEDBarCallback< NumLEDs > >, NoteCCRange< MIDIInputElementCC, RangeLen, NumBanks, NoteCCLED< RangeLen > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCLED< 1 > >, NoteCCRange< MIDIInputElementNote, RangeLen, 1, NoteCCFastLED< ColorMapper > >, MCU::SevenSegmentDisplay< LENGTH >, MCU::SevenSegmentDisplay< AssignmentDisplayLength >, MCU::SevenSegmentDisplay< TimeDisplayLength >, GenericProgramChangeSelector< N, Callback >, GenericProgramChangeSelector< N >, and GenericProgramChangeSelector< N, SelectorLEDsCallback< N > >.

◆ match()

virtual bool MIDIInputElement::match ( const MIDICNChannelAddress target) const
inlineprivatevirtualinherited

Check if the address of the incoming MIDI message matches an address of this element.

Note
This base version of the function is only valid for non-Bankable MIDI input elements, it only matches if the address is equal to the address of this element.

Reimplemented in MCU::Bankable::GenericVU< NumBanks, Callback >, MCU::Bankable::GenericVU< NumBanks >, MCU::Bankable::GenericVU< NumBanks, VULEDsCallback< NumLEDs > >, MCU::Bankable::GenericVPotRing< NumBanks, Callback >, MCU::Bankable::GenericVPotRing< NumBanks >, MCU::Bankable::GenericVPotRing< NumBanks, VPotRingLEDsCallback >, Bankable::GenericNoteCCRange< MIDIInputElementNote, 1, BankSize, NoteCCFastLED< ColorMapper > >, Bankable::GenericNoteCCRange< MIDIInputElementCC, 1, NumBanks >, Bankable::GenericNoteCCRange< MIDIInputElementNote, RangeLen, BankSize, NoteCCFastLED< ColorMapper > >, Bankable::GenericNoteCCRange< MIDIInputElementCC, RangeLen, BankSize, NoteCCFastLED< ColorMapper > >, Bankable::GenericNoteCCRange< MIDIInputElementCC, 1, BankSize, NoteCCLED< 1 > >, Bankable::GenericNoteCCRange< MIDIInputElementNote, RangeLen, BankSize, NoteCCLED< RangeLen > >, Bankable::GenericNoteCCRange< MIDIInputElementNote, RangeLen, NumBanks >, Bankable::GenericNoteCCRange< MIDIInputElementNote, 1, NumBanks >, Bankable::GenericNoteCCRange< MIDIInputElementNote, 1, BankSize, NoteCCLEDBarCallback< NumLEDs > >, Bankable::GenericNoteCCRange< MIDIInputElementNote, 1, BankSize, NoteCCLED< 1 > >, Bankable::GenericNoteCCRange< MIDIInputElementCC, 1, BankSize, NoteCCFastLED< ColorMapper > >, Bankable::GenericNoteCCRange< MIDIInputElementCC, 1, BankSize, NoteCCLEDBarCallback< NumLEDs > >, Bankable::GenericNoteCCRange< MIDIInputElementCC, RangeLen, BankSize, NoteCCLED< RangeLen > >, Bankable::GenericNoteCCRange< MIDIInputElementCC, RangeLen, NumBanks >, GenericNoteCCRange< MIDIInputElementCC, RangeLen, NoteCCFastLED< ColorMapper > >, GenericNoteCCRange< MIDIInputElementCC, 1, NoteCCLED< 1 > >, GenericNoteCCRange< MIDIInputElementNote, RangeLen >, GenericNoteCCRange< MIDIInputElementNote, 1, NoteCCLED< 1 > >, GenericNoteCCRange< MIDIInputElementNote, 1, NoteCCFastLED< ColorMapper > >, GenericNoteCCRange< MIDIInputElementNote, RangeLen, NoteCCLED< RangeLen > >, GenericNoteCCRange< MIDIInputElementNote, RangeLen, NoteCCFastLED< ColorMapper > >, GenericNoteCCRange< MIDIInputElementCC, 1 >, GenericNoteCCRange< MIDIInputElementCC, 1, NoteCCLEDBarCallback< NumLEDs > >, GenericNoteCCRange< MIDIInputElementCC, RangeLen, NoteCCLED< RangeLen > >, GenericNoteCCRange< MIDIInputElementNote, 1, NoteCCLEDBarCallback< NumLEDs > >, GenericNoteCCRange< MIDIInputElementNote, 1 >, GenericNoteCCRange< MIDIInputElementCC, RangeLen >, GenericNoteCCRange< MIDIInputElementCC, 1, NoteCCFastLED< ColorMapper > >, MCU::SevenSegmentDisplay< LENGTH >, MCU::SevenSegmentDisplay< AssignmentDisplayLength >, and MCU::SevenSegmentDisplay< TimeDisplayLength >.

Definition at line 75 of file MIDIInputElement.hpp.

Member Data Documentation

◆ elements

DoublyLinkedList< MIDIInputElementPC > MIDIInputElementPC::elements
staticprivate

Definition at line 100 of file MIDIInputElementPC.hpp.

◆ address

const MIDICNChannelAddress MIDIInputElement::address
protectedinherited

Definition at line 80 of file MIDIInputElement.hpp.

◆ next

MIDIInputElementPC * DoublyLinkable< MIDIInputElementPC >::next
protectedinherited

Definition at line 301 of file LinkedList.hpp.

◆ previous

MIDIInputElementPC * DoublyLinkable< MIDIInputElementPC >::previous
protectedinherited

Definition at line 302 of file LinkedList.hpp.


The documentation for this class was generated from the following files: