Skip to content
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

Opta variant I/O pins vs analog pins #1029

Open
vmsh0 opened this issue Feb 22, 2025 · 1 comment
Open

Opta variant I/O pins vs analog pins #1029

vmsh0 opened this issue Feb 22, 2025 · 1 comment

Comments

@vmsh0
Copy link

vmsh0 commented Feb 22, 2025

Hi,
Sorry for opening an issue; this is not an issue per se but I wasn't sure where else to ask these very specific questions about the Opta core (the Arduino forums don't look like a place where this would be very on topic).

I'm trying to understand how the pins for the Opta I1-I8 ports are mapped. From my understanding, ports I1-I8 can be set up as either ADC ports or I/O ports. This latter option, just for input.

From here, I gather that only I1 (A0) and I2 (A1) are using direct analog channels when used as I/O ports. This is empirically confirmed by measuring the HIGH output of all the pins: the first two sit at a different voltage (just below 3V), suggesting that they have slightly different electrical characteristics. (I know the experiment I have performed is unsupported; I made sure to use appropriate current limit to avoid burning the ADC pins.)

First, I don't understand is how this relates to g_AAnalogPinDescription array in the same file. In particular:

  1. Why does that array map the same names A0-A7 to different processor pins? Are the physical ports of the Opta electrically connected to more than one pin on the package?
  2. How is port PC_2C connected to both I2 (A1) as an I/O and I3 (A2) as an ADC? Does this mean that it is not possible to use I3 as an analog input while I2 is used as a digital input? Also, if this is the case, wouldn't using I2 as a digital input risk sinking too much current to PC_2C?

Second, I was trying to find an explanation to the manual's claim that you can't use I1 (PA_0C) and I4 (PB_0) as interrupt ports. I couldn't explain it from what I read here in the core source code, so I was hoping you could help me shed some light on that as well.

Again, sorry if this is not the correct channel to ask. I thank you in advance for your time and consideration :)

@manchoz
Copy link
Contributor

manchoz commented Feb 24, 2025

Hey @vmsh0,
Please check the Pinout at https://docs.arduino.cc/tutorials/opta/user-manual/#pinout and the Programmable Inputs at https://docs.arduino.cc/tutorials/opta/user-manual/#programmable-inputs section of the User Manual.

More details regarding the multiplexed pins are available in the same document at https://docs.arduino.cc/tutorials/opta/user-manual/#interrupts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants