Control Surface
main
MIDI Control Surface library for Arduino
Toggle main menu visibility
Loading...
Searching...
No Matches
src
MIDI_Outputs
Bankable
Bankable/NoteButtons.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include <
Banks/BankAddresses.hpp
>
4
#include <
MIDI_Outputs/Bankable/Abstract/MIDIButtons.hpp
>
5
#include <
MIDI_Senders/DigitalNoteSender.hpp
>
6
7
BEGIN_CS_NAMESPACE
8
9
namespace
Bankable
{
10
26
template
<u
int
8_t NumButtons>
27
class
NoteButtons
28
:
public
MIDIButtons
<SingleAddress, DigitalNoteSender, NumButtons> {
29
public
:
52
NoteButtons
(
OutputBankConfig<>
config,
53
const
Array<AH::Button, NumButtons>
&
buttons
,
54
MIDIAddress
baseAddress,
RelativeMIDIAddress
incrementAddress
,
55
uint8_t velocity = 0x7F)
56
:
MIDIButtons
<
SingleAddress
,
DigitalNoteSender
, NumButtons> {
57
{config, baseAddress},
58
buttons
,
59
incrementAddress
,
60
{velocity},
61
} {}
62
64
void
setVelocity
(uint8_t velocity) { this->
sender
.setVelocity(velocity); }
66
uint8_t
getVelocity
()
const
{
return
this->
sender
.getVelocity(); }
67
};
68
69
}
// namespace Bankable
70
71
END_CS_NAMESPACE
BankAddresses.hpp
MIDIButtons.hpp
DigitalNoteSender.hpp
END_CS_NAMESPACE
#define END_CS_NAMESPACE
Definition
Settings/NamespaceSettings.hpp:14
BEGIN_CS_NAMESPACE
#define BEGIN_CS_NAMESPACE
Definition
Settings/NamespaceSettings.hpp:11
Bankable::MIDIButtons< SingleAddress, DigitalNoteSender, NumButtons >::incrementAddress
RelativeMIDIAddress incrementAddress
Definition
Bankable/Abstract/MIDIButtons.hpp:75
Bankable::MIDIButtons< SingleAddress, DigitalNoteSender, NumButtons >::sender
DigitalNoteSender sender
Definition
Bankable/Abstract/MIDIButtons.hpp:79
Bankable::MIDIButtons< SingleAddress, DigitalNoteSender, NumButtons >::MIDIButtons
MIDIButtons(SingleAddress bankAddress, const Array< AH::Button, NumButtons > &buttons, RelativeMIDIAddress incrementAddress, const DigitalNoteSender &sender)
Definition
Bankable/Abstract/MIDIButtons.hpp:30
Bankable::MIDIButtons< SingleAddress, DigitalNoteSender, NumButtons >::buttons
Array< AH::Button, NumButtons > buttons
Definition
Bankable/Abstract/MIDIButtons.hpp:74
Bankable::NoteButtons::setVelocity
void setVelocity(uint8_t velocity)
Set the velocity of the MIDI Note events.
Definition
Bankable/NoteButtons.hpp:64
Bankable::NoteButtons::getVelocity
uint8_t getVelocity() const
Get the velocity of the MIDI Note events.
Definition
Bankable/NoteButtons.hpp:66
Bankable::NoteButtons::NoteButtons
NoteButtons(OutputBankConfig<> config, const Array< AH::Button, NumButtons > &buttons, MIDIAddress baseAddress, RelativeMIDIAddress incrementAddress, uint8_t velocity=0x7F)
Create a new Bankable NoteButtons object with the given pins, the given controller number and channel...
Definition
Bankable/NoteButtons.hpp:52
Bankable::SingleAddress
Definition
BankAddresses.hpp:9
DigitalNoteSender
Class that sends MIDI note on and off messages.
Definition
DigitalNoteSender.hpp:12
MIDIAddress
A type-safe utility class for saving a MIDI address consisting of a 7-bit address,...
Definition
MIDIAddress.hpp:145
RelativeMIDIAddress
A class for saving an offset to a MIDI address.
Definition
MIDIAddress.hpp:113
Bankable
A namespace for MIDI elements that can be added to a Bank, to change their address or channel.
Definition
BankAddresses.hpp:7
AH::Array
An array wrapper for easy copying, comparing, and iterating.
Definition
Array.hpp:32
OutputBankConfig
Definition
BankConfig.hpp:79
Generated by
1.17.0