On the SC20100 I’m having issues with GPIO input on PE0 / pin 97. I have the same circuit on other pins and those work correctly. There are two issues that lead me to believe this may not be wired up correctly internally:
The internal pull-up resistor is not working. I have an external pull-up resistor space on the PCB and was testing with it removed to reduce component cost/complexity. Internal pull-ups work correctly on other GPIO input pins I tested.
It always reads logic level 1 (high) regardless of whether the pin is high or low. I have tested this by disconnecting it from the rest of the PCB and using external pull-up and pull-down.
Gpio = GpioController.GetDefault(); MainPowerSwitchPin = Gpio.OpenPin(SC20100.GpioPin.PE0); // PE0 = const 64, actual pin #97, both delta 14 from PD2 values MainPowerSwitchPin.SetDriveMode(GpioPinDriveMode.InputPullUp); <-- Always reads 1, pull-up doesn't work BattPowerSwitchPin = Gpio.OpenPin(SC20100.GpioPin.PD2); // PD2 = const 50, actual pin #83 BattPowerSwitchPin.SetDriveMode(GpioPinDriveMode.InputPullUp); <-- Reads 0 and 1 correctly, pull-up works
Can someone double-check all the definitions for this pin are correct internally?