Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
8 changes: 6 additions & 2 deletions variants/rak4631/RAK4631Board.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,12 @@
#include <helpers/NRF52Board.h>

// built-ins
#define PIN_VBAT_READ 5
#define ADC_MULTIPLIER (3 * 1.73 * 1.187 * 1000)
#ifndef PIN_VBAT_READ
#define PIN_VBAT_READ 5
#endif
#ifndef ADC_MULTIPLIER
#define ADC_MULTIPLIER (3 * 1.73 * 1.187 * 1000)
#endif

class RAK4631Board : public NRF52BoardDCDC {
protected:
Expand Down
8 changes: 6 additions & 2 deletions variants/rak4631/variant.h
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,12 @@ extern "C"
#define PWRMGT_VOLTAGE_BOOTLOCK 3300 // Won't boot below this voltage (mV)
// LPCOMP wake configuration (voltage recovery from SYSTEMOFF)
// AIN3 = P0.05 = PIN_A0 / PIN_VBAT_READ
#define PWRMGT_LPCOMP_AIN 3
#define PWRMGT_LPCOMP_REFSEL 4 // 5/8 VDD (~3.13-3.44V)
#ifndef PWRMGT_LPCOMP_AIN
#define PWRMGT_LPCOMP_AIN 3
#endif
Comment on lines 111 to +114
#ifndef PWRMGT_LPCOMP_REFSEL
#define PWRMGT_LPCOMP_REFSEL 4 // 5/8 VDD (~3.13-3.44V)
#endif

// Other pins
#define PIN_AREF (2)
Expand Down