Skip to content

Add rak12035 VB Soil Monitor Tested & Working #6741

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 69 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 61 commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
fee9166
[WIP] Add RAK12035VB Soil Moisture Sensor support
fifieldt Mar 7, 2025
37e6769
[WIP] Add RAK12035VB Soil Moisture Sensor support
fifieldt Mar 7, 2025
b0ecfb8
Merge branch 'RAK12035VB' of https://github.com/fifieldt/meshtastic-f…
Justin-Mann Mar 10, 2025
0c41f90
[WIP] Add RAK12035VB Soil Moisture Sensor support
fifieldt Mar 7, 2025
3200102
Merge branch 'RAK12035VB' of https://github.com/fifieldt/meshtastic-f…
Justin-Mann Mar 11, 2025
3ca6d2f
[WIP] Add RAK12035VB Soil Moisture Sensor support
fifieldt Mar 7, 2025
b88ab86
Merge branch 'RAK12035VB' of https://github.com/fifieldt/meshtastic-f…
Justin-Mann Mar 22, 2025
8562d0c
Merge branch 'master' into RAK12035VB
caveman99 Apr 7, 2025
8704c15
Update to 1.0.4 release of RAK12035_SoilMoisture
fifieldt Apr 14, 2025
6f0b083
Merge branch 'master' into RAK12035VB
fifieldt Apr 14, 2025
37c1715
Merge branch 'RAK12035VB' of https://github.com/fifieldt/meshtastic-f…
Justin-Mann Apr 15, 2025
e2b6375
cleanup
Justin-Mann Apr 17, 2025
5c721bd
Merge branch 'pr/6259' into AddRAK12035VB_4.19.25
Justin-Mann Apr 19, 2025
492b35a
cool
Justin-Mann Apr 19, 2025
77cd76b
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann Apr 25, 2025
6f87b6a
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 5, 2025
adfacf7
.
Justin-Mann May 5, 2025
0a3f27b
..
Justin-Mann May 5, 2025
440f3fd
little bit of cleanup and recompile/upload/test on RAK WISBLAOCK STAC…
Justin-Mann May 5, 2025
b33ddfe
. comments about current limitations and TODOs
Justin-Mann May 5, 2025
b5be032
trunk update
Justin-Mann May 5, 2025
07b76e8
trying to autoformat..
Justin-Mann May 5, 2025
f21235a
fix formatting attempt 2
Justin-Mann May 5, 2025
3ca2937
..
Justin-Mann May 5, 2025
0b31f6d
...
Justin-Mann May 5, 2025
3b642ae
...
Justin-Mann May 5, 2025
5bed595
.
Justin-Mann May 5, 2025
3f2dd95
some corrections and local build success
Justin-Mann May 5, 2025
171ea1b
correction in temp code
Justin-Mann May 5, 2025
58d6f64
grr formatting
Justin-Mann May 5, 2025
ad9bc53
cleanup after a few experiments
Justin-Mann May 6, 2025
b02e33a
remove temp code to overwrite values for temp and humidity protos.. n…
Justin-Mann May 6, 2025
7873fb4
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 6, 2025
34b56ef
update some values in varient for rak wistap
Justin-Mann May 6, 2025
ab0d76f
working out trunk formatting..
Justin-Mann May 7, 2025
3fcb2ab
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 7, 2025
2b8c791
wip
Justin-Mann May 19, 2025
8c9988e
.
Justin-Mann May 19, 2025
226ab3c
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 19, 2025
911f7f5
Merge branch 'master' of https://github.com/meshtastic/firmware
Justin-Mann May 19, 2025
825a17f
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 19, 2025
488216a
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 20, 2025
5ce965d
Merge branch 'master' of https://github.com/meshtastic/firmware
Justin-Mann May 21, 2025
ad56c70
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 21, 2025
fca402c
Merge branch 'master' into AddRAK12035VB_4.19.25
caveman99 May 23, 2025
4743f15
Merge branch 'master' of https://github.com/meshtastic/firmware
Justin-Mann May 23, 2025
9ac7e2e
Merge branch 'master' of https://github.com/meshtastic/firmware
Justin-Mann May 27, 2025
b41742b
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 27, 2025
7529a61
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 28, 2025
85aa74c
protobuffs?
Justin-Mann May 28, 2025
3eed634
protobufs?
Justin-Mann May 28, 2025
5875c8d
Update protobufs ref
thebentern May 28, 2025
5f2de80
Merge branch 'master' into AddRAK12035VB_4.19.25
thebentern May 28, 2025
480e97d
Merge branch 'master' of https://github.com/meshtastic/firmware
Justin-Mann May 28, 2025
6635750
Merge branch 'master' into AddRAK12035VB_4.19.25
Justin-Mann May 28, 2025
bb7507e
Merge branch 'AddRAK12035VB_4.19.25' of https://github.com/Justin-Man…
Justin-Mann May 28, 2025
a8e47ee
Merge branch 'master' into AddRAK12035VB_4.19.25
thebentern May 28, 2025
3689b86
Protobufs ref
thebentern May 28, 2025
a9c0654
Trunk
thebentern May 28, 2025
14f6c75
Update RAK12035Sensor.cpp
thebentern May 28, 2025
0ed4fdf
Fmt
thebentern May 28, 2025
5756cab
comment changes
Justin-Mann May 28, 2025
a6737f5
dumb mistakes... resolved, actually built and tested.. all good..
Justin-Mann May 28, 2025
d53ffa0
Update src/modules/Telemetry/Sensor/RAK12035Sensor.cpp
thebentern May 29, 2025
5bc95eb
Update src/modules/Telemetry/Sensor/RAK12035Sensor.cpp
thebentern May 29, 2025
227be11
Merge branch 'master' into AddRAK12035VB_4.19.25
thebentern May 29, 2025
8112753
Merge branch 'master' into AddRAK12035VB_4.19.25
thebentern May 29, 2025
beb525f
Merge branch 'master' into AddRAK12035VB_4.19.25
thebentern May 30, 2025
7d4e39d
Merge branch 'master' into AddRAK12035VB_4.19.25
thebentern May 30, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions src/configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,15 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
// -----------------------------------------------------------------------------
#define FT6336U_ADDR 0x48

// -----------------------------------------------------------------------------
// RAK12035VB Soil Monitor (using RAK12023 up to 3 RAK12035 monitors can be connected)
// - the default i2c address for this sensor is 0x20, and users are instructed to
// set 0x21 and 0x22 for the second and third sensor if present.
// -----------------------------------------------------------------------------
#define RAK120351_ADDR 0x20
#define RAK120352_ADDR 0x21
#define RAK120353_ADDR 0x22

// -----------------------------------------------------------------------------
// BIAS-T Generator
// -----------------------------------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions src/detect/ScanI2C.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ class ScanI2C
DFROBOT_RAIN,
DPS310,
LTR390UV,
RAK12035,
TCA8418KB,
PCT2075,
} DeviceType;
Expand Down
14 changes: 13 additions & 1 deletion src/detect/ScanI2CTwoWire.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -423,9 +423,21 @@ void ScanI2CTwoWire::scanPort(I2CPort port, uint8_t *address, uint8_t asize)
logFoundDevice("BMA423", (uint8_t)addr.address);
}
break;
case TCA9535_ADDR:
case RAK120352_ADDR:
case RAK120353_ADDR:
registerValue = getRegisterValue(ScanI2CTwoWire::RegisterLocation(addr, 0x02), 1);
if (registerValue == addr.address) { // RAK12035 returns its I2C address at 0x02 (eg 0x20)
type = RAK12035;
logFoundDevice("RAK12035", (uint8_t)addr.address);
} else {
type = TCA9535;
logFoundDevice("TCA9535", (uint8_t)addr.address);
}

break;

SCAN_SIMPLE_CASE(LSM6DS3_ADDR, LSM6DS3, "LSM6DS3", (uint8_t)addr.address);
SCAN_SIMPLE_CASE(TCA9535_ADDR, TCA9535, "TCA9535", (uint8_t)addr.address);
SCAN_SIMPLE_CASE(TCA9555_ADDR, TCA9555, "TCA9555", (uint8_t)addr.address);
SCAN_SIMPLE_CASE(VEML7700_ADDR, VEML7700, "VEML7700", (uint8_t)addr.address);
SCAN_SIMPLE_CASE(TSL25911_ADDR, TSL2591, "TSL2591", (uint8_t)addr.address);
Expand Down
1 change: 1 addition & 0 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -732,6 +732,7 @@ void setup()
scannerToSensorsMap(i2cScanner, ScanI2C::DeviceType::DFROBOT_RAIN, meshtastic_TelemetrySensorType_DFROBOT_RAIN);
scannerToSensorsMap(i2cScanner, ScanI2C::DeviceType::LTR390UV, meshtastic_TelemetrySensorType_LTR390UV);
scannerToSensorsMap(i2cScanner, ScanI2C::DeviceType::DPS310, meshtastic_TelemetrySensorType_DPS310);
scannerToSensorsMap(i2cScanner, ScanI2C::DeviceType::RAK12035, meshtastic_TelemetrySensorType_RAK12035);
scannerToSensorsMap(i2cScanner, ScanI2C::DeviceType::PCT2075, meshtastic_TelemetrySensorType_PCT2075);

i2cScanner.reset();
Expand Down
38 changes: 36 additions & 2 deletions src/modules/Telemetry/EnvironmentTelemetry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
#include <OLEDDisplayUi.h>

#if !MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR_EXTERNAL
// Sensors

// Sensors
#include "Sensor/CGRadSensSensor.h"
#include "Sensor/RCWL9620Sensor.h"
#include "Sensor/nullSensor.h"
Expand Down Expand Up @@ -94,6 +94,13 @@ SHTC3Sensor shtc3Sensor;
NullSensor shtc3Sensor;
#endif

#if __has_include("RAK12035_SoilMoisture.h") && defined(RAK_4631) && RAK_4631 == 1
#include "Sensor/RAK12035Sensor.h"
RAK12035Sensor rak12035Sensor;
#else
NullSensor rak12035Sensor;
#endif

#if __has_include(<Adafruit_VEML7700.h>)
#include "Sensor/VEML7700Sensor.h"
VEML7700Sensor veml7700Sensor;
Expand Down Expand Up @@ -166,6 +173,7 @@ NullSensor pct2075Sensor;

RCWL9620Sensor rcwl9620Sensor;
CGRadSensSensor cgRadSens;

#endif
#ifdef T1000X_SENSOR_EN
#include "Sensor/T1000xSensor.h"
Expand All @@ -175,6 +183,7 @@ T1000xSensor t1000xSensor;
#include "Sensor/IndicatorSensor.h"
IndicatorSensor indicatorSensor;
#endif

#define FAILED_STATE_SENSOR_READ_MULTIPLIER 10
#define DISPLAY_RECEIVEID_MEASUREMENTS_ON_SCREEN true

Expand Down Expand Up @@ -279,6 +288,11 @@ int32_t EnvironmentTelemetryModule::runOnce()

result = rak9154Sensor.runOnce();
#endif
#if __has_include("RAK12035_SoilMoisture.h") && defined(RAK_4631) && RAK_4631 == 1
if (rak12035Sensor.hasSensor()) {
result = rak12035Sensor.runOnce();
}
#endif
#endif
}
// it's possible to have this module enabled, only for displaying values on the screen.
Expand Down Expand Up @@ -612,6 +626,14 @@ bool EnvironmentTelemetryModule::getEnvironmentTelemetry(meshtastic_Telemetry *m
valid = valid && rak9154Sensor.getMetrics(m);
hasSensor = true;
#endif
#if __has_include("RAK12035_SoilMoisture.h") && defined(RAK_4631) && \
RAK_4631 == \
1 // Not really needed, but may as well just skip at a lower level it if no library or not a RAK_4631
if (rak12035Sensor.hasSensor()) {
valid = valid && rak12035Sensor.getMetrics(m);
hasSensor = true;
}
#endif
#endif
return valid && hasSensor;
}
Expand Down Expand Up @@ -666,6 +688,9 @@ bool EnvironmentTelemetryModule::sendTelemetry(NodeNum dest, bool phoneOnly)

LOG_INFO("Send: radiation=%fµR/h", m.variant.environment_metrics.radiation);

LOG_INFO("Send: soil_temperature=%f, soil_moisture=%u", m.variant.environment_metrics.soil_temperature,
m.variant.environment_metrics.soil_moisture);

sensor_read_error_count = 0;

meshtastic_MeshPacket *p = allocDataProtobuf(m);
Expand Down Expand Up @@ -832,8 +857,17 @@ AdminMessageHandleResult EnvironmentTelemetryModule::handleAdminMessageForModule
if (result != AdminMessageHandleResult::NOT_HANDLED)
return result;
}
#if __has_include("RAK12035_SoilMoisture.h") && defined(RAK_4631) && \
RAK_4631 == \
1 // Not really needed, but may as well just skip it at a lower level if no library or not a RAK_4631
if (rak12035Sensor.hasSensor()) {
result = rak12035Sensor.handleAdminMessage(mp, request, response);
if (result != AdminMessageHandleResult::NOT_HANDLED)
return result;
}
#endif
#endif
return result;
}

#endif
#endif
109 changes: 109 additions & 0 deletions src/modules/Telemetry/Sensor/RAK12035Sensor.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
#include "configuration.h"
#if !MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR && __has_include("RAK12035_SoilMoisture.h") && defined(RAK_4631) && RAK_4631 == 1

#include "../mesh/generated/meshtastic/telemetry.pb.h"
#include "RAK12035Sensor.h"

RAK12035Sensor::RAK12035Sensor() : TelemetrySensor(meshtastic_TelemetrySensorType_RAK12035, "RAK12035") {}

int32_t RAK12035Sensor::runOnce()
{

LOG_INFO("Init sensor: %s", sensorName);
if (!hasSensor()) {
return DEFAULT_SENSOR_MINIMUM_WAIT_TIME_BETWEEN_READS;
}

// TODO:: check for up to 2 additional sensors and start them if present.
sensor.set_sensor_addr(RAK120351_ADDR);
delay(100);
sensor.begin(nodeTelemetrySensorsMap[sensorType].first);

// Get sensor firmware version
uint8_t data = 0;
sensor.get_sensor_version(&data);
LOG_INFO("Sensor1 Firmware version: %i", data);

if (data != 0) {
LOG_INFO("RAK12035Sensor Init Succeed");
status = true;
} else {
LOG_ERROR("RAK12035Sensor Init Failed");
status = false;
}
sensor.sensor_sleep();
return initI2CSensor();
}

void RAK12035Sensor::setup()
{
// Set the calibration values
// Reading the saved calibration values from the sensor.
// TODO:: Check for and run calibration check for up to 2 additional sensors if present.
uint16_t zero_val = 0;
uint16_t hundred_val = 0;
uint16_t default_zero_val = 550;
uint16_t default_hundred_val = 420;
sensor.sensor_on();
delay(200);
sensor.get_dry_cal(&zero_val);
sensor.get_wet_cal(&hundred_val);
delay(200);
if (zero_val == 0 || zero_val <= hundred_val) {
LOG_INFO("Dry calibration value is %d", zero_val);
LOG_INFO("Wet calibration value is %d", hundred_val);
LOG_INFO("This does not make sense. You can recalibrate this sensor using the calibration sketch included here: "
"https://github.com/RAKWireless/RAK12035_SoilMoisture.");
LOG_INFO("For now, setting default calibration value for Dry Calibration: %d", default_zero_val);
sensor.set_dry_cal(default_zero_val);
sensor.get_dry_cal(&zero_val);
LOG_INFO("Dry calibration reset complete. New value is %d", zero_val);
}
if (hundred_val == 0 || hundred_val >= zero_val) {
LOG_INFO("Dry calibration value is %d", zero_val);
LOG_INFO("Wet calibration value is %d", hundred_val);
LOG_INFO("This does not make sense. You can recalibrate this sensor using the calibration sketch included here: "
"https://github.com/RAKWireless/RAK12035_SoilMoisture.");
LOG_INFO("For now, setting default calibration value for Wet Calibration: %d", default_hundred_val);
sensor.set_wet_cal(default_hundred_val);
sensor.get_wet_cal(&hundred_val);
LOG_INFO("Wet calibration reset complete. New value is %d", hundred_val);
}
sensor.sensor_sleep();
delay(200);
LOG_INFO("Dry calibration value is %d", zero_val);
LOG_INFO("Wet calibration value is %d", hundred_val);
}

bool RAK12035Sensor::getMetrics(meshtastic_Telemetry *measurement)
{
// TODO:: read and send metrics for up to 2 additional soil monitors if present.
// -- how to do this.. this could get a little complex..
// ie - 1> we combine them into an average and send that, 2> we send them as separate metrics
// ^-- these scenarios would require different handling of the metrics in the receiving end and maybe a setting in the
// device ui and an additional proto for that?
measurement->variant.environment_metrics.has_soil_temperature = true;
measurement->variant.environment_metrics.has_soil_moisture = true;

uint8_t moisture = 0;
uint16_t temp = 0;
bool success = false;

sensor.sensor_on();
delay(200);
success = sensor.get_sensor_moisture(&moisture);
delay(200);
success = sensor.get_sensor_temperature(&temp);
delay(200);
sensor.sensor_sleep();

if (success == false) {
LOG_ERROR("Failed to read sensor data");
return false;
}
measurement->variant.environment_metrics.soil_temperature = (float)(temp / 10);
measurement->variant.environment_metrics.soil_moisture = moisture;

return true;
}
#endif
28 changes: 28 additions & 0 deletions src/modules/Telemetry/Sensor/RAK12035Sensor.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#pragma once

#include "configuration.h"

#if !MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR && __has_include(<RAK12035_SoilMoisture.h>) && defined(RAK_4631)
#ifndef _MT_RAK12035VBSENSOR_H
#define _MT_RAK12035VBSENSOR_H
#endif

#include "../mesh/generated/meshtastic/telemetry.pb.h"
#include "RAK12035_SoilMoisture.h"
#include "TelemetrySensor.h"
#include <Arduino.h>

class RAK12035Sensor : public TelemetrySensor
{
private:
RAK12035 sensor;

protected:
virtual void setup() override;

public:
RAK12035Sensor();
virtual int32_t runOnce() override;
virtual bool getMetrics(meshtastic_Telemetry *measurement) override;
};
#endif
3 changes: 2 additions & 1 deletion variants/rak4631/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ lib_deps =
melopero/Melopero RV3028@^1.1.0
https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip
rakwireless/RAKwireless NCP5623 RGB LED library@^1.0.2
beegee-tokyo/RAK12035_SoilMoisture@^1.0.4
https://github.com/RAKWireless/RAK12034-BMX160/archive/dcead07ffa267d3c906e9ca4a1330ab989e957e2.zip

; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
Expand Down Expand Up @@ -51,4 +52,4 @@ lib_deps =
upload_protocol = stlink
; eventually use platformio/tool-pyocd@^2.3600.0 instad
;upload_protocol = custom
;upload_command = pyocd flash -t nrf52840 $UPLOADERFLAGS $SOURCE
;upload_command = pyocd flash -t nrf52840 $UPLOADERFLAGS $SOURCE
5 changes: 4 additions & 1 deletion variants/rak4631/variant.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ static const uint8_t A7 = PIN_A7;
// Other pins
#define PIN_AREF (2)
#define PIN_NFC1 (9)
#define WB_IO5 PIN_NFC1
#define WB_IO4 (4)
#define PIN_NFC2 (10)

static const uint8_t AREF = PIN_AREF;
Expand Down Expand Up @@ -223,6 +225,7 @@ SO GPIO 39/TXEN MAY NOT BE DEFINED FOR SUCCESSFUL OPERATION OF THE SX1262 - TG
// enables 3.3V periphery like GPS or IO Module
// Do not toggle this for GPS power savings
#define PIN_3V3_EN (34)
#define WB_IO2 PIN_3V3_EN

// RAK1910 GPS module
// If using the wisblock GPS module and pluged into Port A on WisBlock base
Expand Down Expand Up @@ -276,4 +279,4 @@ SO GPIO 39/TXEN MAY NOT BE DEFINED FOR SUCCESSFUL OPERATION OF THE SX1262 - TG
* Arduino objects - C++ only
*----------------------------------------------------------------------------*/

#endif
#endif
1 change: 1 addition & 0 deletions variants/rak4631_epaper/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ lib_deps =
melopero/Melopero RV3028@^1.1.0
rakwireless/RAKwireless NCP5623 RGB LED library@^1.0.2
beegee-tokyo/RAKwireless RAK12034@^1.0.0
beegee-tokyo/RAK12035_SoilMoisture@^1.0.4
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
;upload_protocol = jlink
5 changes: 4 additions & 1 deletion variants/rak4631_epaper/variant.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ static const uint8_t A7 = PIN_A7;
// Other pins
#define PIN_AREF (2)
#define PIN_NFC1 (9)
#define WB_IO5 PIN_NFC1
#define WB_IO4 (4)
#define PIN_NFC2 (10)

static const uint8_t AREF = PIN_AREF;
Expand Down Expand Up @@ -188,6 +190,7 @@ static const uint8_t SCK = PIN_SPI_SCK;

// enables 3.3V periphery like GPS or IO Module
#define PIN_3V3_EN (34)
#define WB_IO2 PIN_3V3_EN

// RAK1910 GPS module
// If using the wisblock GPS module and pluged into Port A on WisBlock base
Expand Down Expand Up @@ -231,4 +234,4 @@ static const uint8_t SCK = PIN_SPI_SCK;
* Arduino objects - C++ only
*----------------------------------------------------------------------------*/

#endif
#endif
1 change: 1 addition & 0 deletions variants/rak4631_epaper_onrxtx/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ lib_deps =
melopero/Melopero RV3028@^1.1.0
rakwireless/RAKwireless NCP5623 RGB LED library@^1.0.2
beegee-tokyo/RAKwireless RAK12034@^1.0.0
beegee-tokyo/RAK12035_SoilMoisture@^1.0.4
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
;upload_protocol = jlink
Expand Down
7 changes: 5 additions & 2 deletions variants/rak4631_epaper_onrxtx/variant.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,9 @@ static const uint8_t A7 = PIN_A7;

// Other pins
#define PIN_AREF (2)
// #define PIN_NFC1 (9)
#define PIN_NFC1 (9)
#define WB_IO5 PIN_NFC1
#define WB_IO4 (4)
// #define PIN_NFC2 (10)

static const uint8_t AREF = PIN_AREF;
Expand Down Expand Up @@ -160,6 +162,7 @@ static const uint8_t SCK = PIN_SPI_SCK;

// enables 3.3V periphery like GPS or IO Module
#define PIN_3V3_EN (34)
#define WB_IO2 PIN_3V3_EN

// NO GPS
#undef GPS_RX_PIN
Expand Down Expand Up @@ -202,4 +205,4 @@ static const uint8_t SCK = PIN_SPI_SCK;
* Arduino objects - C++ only
*----------------------------------------------------------------------------*/

#endif
#endif
Loading
Loading