Using Arduino on Windows to program my RAK4630 on a RAK5005-0 base board, I can’t get a voltage reading on the GPIO pin WB_IO1. Serial monitor just prints 0 over and over again. Earlier, I was able to program HIGH and LOW voltage OUTPUTto the pin, then when I measured the voltage of the pin using a multimeter and I able to get a pulsing voltage, but I can’t read voltages from the pin as INPUT. This is my code I am uploading to the wisblock kit and I am delivering 0.3V to the pin WB_IO1:
#include <Arduino.h>
#include <SX126x-RAK4630.h>
#include <SPI.h>
#include <Wire.h>
void setup() {
// put your setup code here, to run once:
pinMode(WB_IO1, INPUT);
}
void loop() {
// put your main code here, to run repeatedly:
delay(3000);
int val = analogRead(WB_IO1); // read the input pin
Serial.print(val);
}