Skip to content

Macros to provide basic pin information about a particular board. [imported] #495

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

Closed
cmaglie opened this issue Nov 15, 2012 · 0 comments
Closed

Comments

@cmaglie
Copy link
Member

cmaglie commented Nov 15, 2012

This is Issue 495 moved from a Google Code project.
Added by 2011-03-05T16:27:02.000Z by [email protected].
Please review that bug for more context and additional comments, but update this bug.
Closed (Fixed).

Original labels: Type-Enhancement, Priority-Medium, Milestone-1.0, Component-Core

Original description

From Paul Stoffregen:

"1: The total number of digital pins, usable with pinMode, digitalRead, digitalWrite.

2: The total number of analog pins, usable with analogRead.

3: A macro that takes an analog pin as input and outputs the corresponding digital pin, or -1 if that analog pin does not have any corresponding digital pin, or -1 if the input is greater than the maximum analog pin number.

4: A macro that takes a digital pin as input and returns true if that pin has PWM capability, or false if it does not, or false if the input is greater than the maximum digital pin number."

This is in some ways a subset of issue 59 (http://code.google.com/p/arduino/issues/detail?id=59). I think most or all of these particular ones make sense given the more CPU-neutral build system and core we'll have in 1.0.

Look at the Firmata and ArduinoTestSuite libraries for examples of places that might need this functionality.

@cmaglie cmaglie closed this as completed Nov 15, 2012
tbowmo pushed a commit to tbowmo/Arduino that referenced this issue Jul 14, 2016
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

1 participant