From 67045d0aef5e8f75d702ce2aa9a35b740dc1a1e0 Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Tue, 26 Sep 2023 14:35:49 +0300 Subject: initial commit: This uses the Control Surface library with a single potentionmeter, sending 14-bit CC values --- .gitignore | 1 + shmotbox.ino | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 .gitignore create mode 100644 shmotbox.ino diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b03bcec --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +build-leonardo diff --git a/shmotbox.ino b/shmotbox.ino new file mode 100644 index 0000000..2b5bb44 --- /dev/null +++ b/shmotbox.ino @@ -0,0 +1,22 @@ +#include + +class CCPotentiometer14 : public MIDIFilteredAnalog> { + public: + CCPotentiometer14(pin_t analogPin, MIDIAddress address) + : MIDIFilteredAnalog(analogPin, address, {}) {} +}; + +USBMIDI_Interface midi; +CCPotentiometer14 pot {A0, MIDI_CC::General_Purpose_Controller_1}; + +void +setup() +{ + Control_Surface.begin(); +} + +void +loop() +{ + Control_Surface.loop(); +} -- cgit v1.2.3