Naming of pins for ADC, DAC, etc. #6740
Unanswered
espruino-discuss
asked this question in
Porting to new Devices
Replies: 1 comment
-
Posted at 2016-12-12 by @gfwilliams You can also define global variables using JSON in the same way - I think if you look up That'd probably be the easiest method? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2016-12-11 by JumJum
Right now we have pins named D0 ..... D39
Is there an option in boards file or somewhere else, to have pins named like:
ADC1 pointing to D36, would be readAnalog(ADC1)
...
ADC4 pointing to D32
...
DAC1 pointing to D25
...
For ESP8266 there is something like that in jswrap_nodemcu.c
Following this idea in general we could have a class called pins, where pins.ADC1 = D36
Any other suggestion ?
Beta Was this translation helpful? Give feedback.
All reactions