Skip to content

Commit

Permalink
Added pull-up for INTERFACE_SEL input
Browse files Browse the repository at this point in the history
  • Loading branch information
matthias-bs authored Apr 17, 2023
1 parent 2bdbaa3 commit 21996df
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions growatt2lorawan.ino
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
#define _DEBUG_MODE_

// Enable sleep mode - sleep after successful transmission to TTN (recommended!)
#define SLEEP_EN
//#define SLEEP_EN

// Enable setting RTC from LoRaWAN network time
#define GET_NETWORKTIME
Expand Down Expand Up @@ -542,7 +542,7 @@ bool modbusRS485; // Modbus interface select: 0 - USB / 1 - RS485

void setup() {

pinMode(INTERFACE_SEL, INPUT);
pinMode(INTERFACE_SEL, INPUT_PULLUP);
modbusRS485 = digitalRead(INTERFACE_SEL);


Expand Down Expand Up @@ -1039,7 +1039,7 @@ cSensor::doUplink(int port) {
#endif

this->m_fBusy = true;

if (! myLoRaWAN.SendBuffer(
loraData, encoder.getLength(),
// this is the completion function:
Expand Down

0 comments on commit 21996df

Please sign in to comment.