From 6d30e5dee79979de08600cd6aca06cf90bdfb3f3 Mon Sep 17 00:00:00 2001 From: Holger Wirtz Date: Thu, 24 Oct 2019 15:35:16 +0200 Subject: [PATCH] Rolling back some changes, due to get it running again on my dev system. Should be made easier to change between different systems (e.g. Teensy-4/Teensy-3, built-in SD card or audio shield SD card, ...) --- SoftenValue.hpp | 2 +- config.h | 41 ++++++++++++++++++++--------------------- 2 files changed, 21 insertions(+), 22 deletions(-) diff --git a/SoftenValue.hpp b/SoftenValue.hpp index 0ba11aa..1f2a552 100644 --- a/SoftenValue.hpp +++ b/SoftenValue.hpp @@ -30,7 +30,7 @@ template class SoftenValue { public: - init(T value, T minimum, T maximum) + void init(T value, T minimum, T maximum) { _from = value; _to = value; diff --git a/config.h b/config.h index 8f2ab03..18165e6 100644 --- a/config.h +++ b/config.h @@ -57,9 +57,9 @@ //#define TEENSY_DAC //#define TEENSY_DAC_SYMMETRIC //#define TEENSY_AUDIO_BOARD -#define I2S_AUDIO_ONLY +//#define I2S_AUDIO_ONLY //#define TGA_AUDIO_BOARD -//#define PT8211_AUDIO +#define PT8211_AUDIO //************************************************************************************************* //* MIDI SETTINGS @@ -113,24 +113,24 @@ #define ENABLE_LCD_UI 1 // LCD Display //I2C_DISPLAY only -//#define LCD_I2C_ADDRESS 0x27 -#define LCD_I2C_ADDRESS 0x3f +#define LCD_I2C_ADDRESS 0x27 +//#define LCD_I2C_ADDRESS 0x3f //Display size, must be set for U8X8 as well #define LCD_cols 16 -//#define LCD_rows 2 -#define LCD_rows 4 +#define LCD_rows 2 +//#define LCD_rows 4 //enable U8X8 support -#define U8X8_DISPLAY +//#define U8X8_DISPLAY //enable SPI CS switching -#define DISPLAY_LCD_SPI -#define U8X8_DISPLAY_CLASS U8X8_SSD1322_NHD_256X64_4W_HW_SPI +//#define DISPLAY_LCD_SPI +//#define U8X8_DISPLAY_CLASS U8X8_SSD1322_NHD_256X64_4W_HW_SPI //#define U8X8_DISPLAY_CLASS U8X8_SSD1306_128X64_NONAME_HW_I2C -#define U8X8_CS_PIN 9 -#define U8X8_DC_PIN 15 -#define U8X8_RESET_PIN 14 +//#define U8X8_CS_PIN 9 +//#define U8X8_DC_PIN 15 +//#define U8X8_RESET_PIN 14 //Standard 16x2 LCD display (SPI/PCF8874) -//#define I2C_DISPLAY +#define I2C_DISPLAY // [I2C] SCL: Pin 19, SDA: Pin 18 (https://www.pjrc.com/teensy/td_libs_Wire.html) //#define LCD_GFX 1 #define CONTROL_RATE_MS 50 @@ -156,8 +156,7 @@ //#define SDCARD_SCK_PIN 14 #define SGTL5000_LINEOUT_LEVEL 29 // Teensy 3.5 & 3.6 SD card -//#define SDCARD_CS_PIN BUILTIN_SDCARD -#define SDCARD_CS_PIN 10 +#define SDCARD_CS_PIN BUILTIN_SDCARD #define SDCARD_MOSI_PIN 11 // not actually used #define SDCARD_SCK_PIN 13 // not actually used @@ -167,12 +166,12 @@ #define ENC_L_PIN_A 3 #define ENC_L_PIN_B 2 #define BUT_L_PIN 4 -//#define ENC_R_PIN_A 28 -//#define ENC_R_PIN_B 29 -//#define BUT_R_PIN 30 -#define ENC_R_PIN_A 6 -#define ENC_R_PIN_B 5 -#define BUT_R_PIN 8 +#define ENC_R_PIN_A 28 +#define ENC_R_PIN_B 29 +#define BUT_R_PIN 30 +//#define ENC_R_PIN_A 6 +//#define ENC_R_PIN_B 5 +//#define BUT_R_PIN 8 #define BUT_DEBOUNCE_MS 20 #define LONG_BUTTON_PRESS 500