Hello! I am trying to configure pins 20 through 27 to be inputs on the Arduino Nano Every. My code is as follows.
This, unfortunately, doesn't work. The code seems to freeze and never gets to the Serial.print() command in the void loop. For whatever reason it seems to get stuck on this chunk of code. I have discovered two ways to successfully get past this block of code. The first way is to comment out pins 22, 23, and 25. When I run the code as follows, it goes through without issue. If I uncomment any of those three lines, it gets stuck.
I have tried on multiple boards and they both behave in this manner. Why can I not successfully set pins 22, 23, and 25 to inputs? Why do they work as outputs? Why are these pins behaving any differently than the other GPIO pins? Any thoughts welcomed.
If I'm reading this table correctly, my understanding is that pins 20-28 can all be used as GPIO. Is there something different you meant by there being only 22 signal pins? This table is right out of the Arduino Nano Every datasheet.
The Serial.print() is further down in the void loop. I did not include that chunk of code because it executes properly when the trouble code is bypassed.