From 2b785e5b0c511c419f0da4bcbbe6af86c79b845b Mon Sep 17 00:00:00 2001 From: RedHawk Date: Fri, 9 Jun 2023 11:10:21 +0300 Subject: [PATCH] prototype: Change pins to the prototype ones. --- source/shoh/src/threads/relay/Relay.h | 4 ++-- source/shoh/src/threads/rotary/Rotary.h | 6 +++--- .../src/threads/user_interface/UserInterface.cpp | 16 ++++++++-------- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/source/shoh/src/threads/relay/Relay.h b/source/shoh/src/threads/relay/Relay.h index c626ff7..417b721 100644 --- a/source/shoh/src/threads/relay/Relay.h +++ b/source/shoh/src/threads/relay/Relay.h @@ -48,8 +48,8 @@ public: void utilizeEventData(); private: ThreadCommon::QueueManager* _qm; - RelayDevice relays [2] = {{0, 24, 0}, - {0, 26, 1}}; + RelayDevice relays [2] = {{0, 11, 0}, + {0, 23, 1}}; void parseEvent(Event * e); int8_t setpoint, ext_temp; diff --git a/source/shoh/src/threads/rotary/Rotary.h b/source/shoh/src/threads/rotary/Rotary.h index dafe910..61ccdc0 100644 --- a/source/shoh/src/threads/rotary/Rotary.h +++ b/source/shoh/src/threads/rotary/Rotary.h @@ -20,9 +20,9 @@ public: private: Event* message; ThreadCommon::QueueManager* _qm; - DigitalIoPin signal[3] = { { 0, 1, true, true, false, true, PIN_INT0_IRQn}, //SW1 - { 0, 16, true, true, false, true, PIN_INT1_IRQn}, //SW2 - { 1, 8, true, false, false, true, PIN_INT2_IRQn} }; + DigitalIoPin signal[3] = { { 1, 18, true, true, false, true, PIN_INT0_IRQn}, //SW1 //Right //0 1 + { 2, 12, true, true, false, true, PIN_INT1_IRQn}, //SW2 //Left //0 16 + { 2, 11, true, false, false, true, PIN_INT2_IRQn} }; //Press //1 8 }; void thread_rotary(void* pvParams); diff --git a/source/shoh/src/threads/user_interface/UserInterface.cpp b/source/shoh/src/threads/user_interface/UserInterface.cpp index 4ea61c0..9bcc0fd 100644 --- a/source/shoh/src/threads/user_interface/UserInterface.cpp +++ b/source/shoh/src/threads/user_interface/UserInterface.cpp @@ -75,19 +75,19 @@ void UserInterface::handleLCD(LiquidCrystal *lcd, const char *str) void UserInterface::initLCD1() { - this->lcd1_rs = new DigitalIoPin(1, 9, false); - this->lcd1_en = new DigitalIoPin(0, 14, false); - this->lcd1_d4 = new DigitalIoPin(0, 13, false); - this->lcd1_d5 = new DigitalIoPin(0, 12, false); - this->lcd1_d6 = new DigitalIoPin(0, 23, false); - this->lcd1_d7 = new DigitalIoPin(0, 11, false); + this->lcd1_rs = new DigitalIoPin(1, 24, false);//(1, 18, false); + this->lcd1_en = new DigitalIoPin(1, 26, false);//(1, 24, false); + this->lcd1_d4 = new DigitalIoPin(1, 27, false);//(1, 19, false); + this->lcd1_d5 = new DigitalIoPin(1, 25, false);//(1, 26, false); + this->lcd1_d6 = new DigitalIoPin(1, 28, false);//(1, 27, false); + this->lcd1_d7 = new DigitalIoPin(2, 3, false);//(1, 25, false); this->lcd1_rs->write(false); this->lcd1_en->write(false); this->lcd1_d4->write(false); this->lcd1_d5->write(false); - this->lcd1_d6->write(false); - this->lcd1_d7->write(false); + this->lcd1_d6->write(false); + this->lcd1_d7->write(false); // LCD init. this->lcd1 = new LiquidCrystal(this->lcd1_rs, this->lcd1_en, this->lcd1_d4, this->lcd1_d5, this->lcd1_d6, this->lcd1_d7);