PROS Dgtl port 10

Why, in


API.h

, in PROS, does it state that you cannot use digital port 10 for an encoder?

port 10 cant be used for interrupts, its a low level cortex thing and has to do how the user SoC multiplexes interrupts for digital ports
you cant use encoders on port 10 on any OS, its not just PROS

Well that’s just stupid

¯_(ツ)_/¯ i would complain more about vex using the package with only 64k of memory

That too

When you have 10 digital ports, I don’t think it’s a huge problem that you can’t use one of the ports for a specific task. Then again, lots of teams use digital ports more than I would.

Well if you had 11 ports with interrupts and 1 port without your options are not let people use that port or to allow people to use it for only buttons, pistons or half of am ultrasonic sensor.

I have used arduinos quite a bit and love how many interrupt ports the cortex has.

Actually you can on every other option, ROBOTC, ConVEX etc.

What you can not do is use both port 4 and port 10 at the same time for something like a quad encoder or sonar that need to configure those ports as interrupt inputs. There are several old posts discussing why, here is one.
https://vexforum.com/t/quadrature-encoder-values-not-working-from-robotc-tech-forum/22825/1

Out of curiosity, other than the api comment saying you can’t use port 10, does pros actually not allow you to use it or was the comment just meant to simplify the issue of ports 4 & 10 sharing an interrupt?

It’s the latter :slight_smile:

PROS does still allow you to use port 10 as an interrupt (so it can be used with encoders), but with the same stipulation that the interrupt is shared with port 4. The API simply mentions port 10 for simplicity’s sake, it accomplishes the same goal without needing to get into the full discussion of the way that the Cortex handles interrupts. There is no particular reason to avoid port 10 instead of port 4 besides that team BLRS and the PROS development team have found it easier to remember.

This information will be covered soon in the tutorials section at pros.cs.purdue.edu as well, though it may take a day or two before these changes become live.