Popular Threads From Developers:
List Statistics
- Total Threads: 675
- Total Posts: 4004
Phrases Used to Find This Thread
|
# 1

07-05-2010 05:23 PM
|
|
|
I will be glad to see this (aliases), it's one of those things that
are always are tripping up my students.
What would make even more sense, eventually, is to just deprecate the
analog numbers entirely, and just have one set of unambiguous pin numbers.
Eliminating what is a needlessly confusing distinction, for example,
the pwm, interrupt, I2C, SPI, and serial pins do not have their own
pin numbers.
Then users could just check a pin map for their chip, for the
hardware on the pin, and get going with the code.
Paul
_______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 2

07-05-2010 05:48 PM
|
|
|
At 11:23 AM -0500 5/7/10, Paul Badger wrote:
>I will be glad to see this (aliases), it's one of those things that are always are tripping up my students.
>
>What would make even more sense, eventually, is to just deprecate the analog numbers entirely, and just have one set of unambiguous pin numbers.
>Eliminating what is a needlessly confusing distinction, for example, the pwm, interrupt, I2C, SPI, and serial pins do not have their own pin numbers.
>
>Then users could just check a pin map for their chip, for the hardware on the pin, and get going with the code.
>
Hear, Hear!
I expect eventually microcontrollers will be made where every pin can have any function (like many FPGA's) but until then we need to master mapping. Currently we burden beginners
with having to remember or lookup these maps for particular chips in sometimes obscure corners
of the documentation instead of close to where they are working (in the IDE).
_______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 3

07-05-2010 07:44 PM
|
|
|
> What would make even more sense, eventually, is to just deprecate
> the analog numbers entirely, and just have one set of unambiguous
> pin numbers.
Yes! I'd love to see a single set of numbers. But, with aliases, so 1)
folks don't have to check the pin map for their chip as often and 2)
the same identical code is more likely to work on different chips.
PWM_1-PWM_N, SCA_1-SCA_N, SDA_1-SDA_N, MISO_1-MISO_N, etc.
I would prefer if the interrupt numbers were just their pin numbers.
That's how I've set up the xmega port. Don't know if aliases make
sense for them.
Again, transitioning is troublesome. I'm trying to figure out how to
use C++ namespaces to make this easier. To use the "old" API, the user
need do nothing. To use the new API, the user need only add:
using ArduinoApi_v2;
The preprocessor scans the sketch and if it sees no "using" statement,
adds "using ArduinoApi_v1;" I'd like to make it even simpler than
this, but namespace semantics are fighting me.
giuliano
On May 7, 2010, at 9:23 AM, Paul Badger wrote:
> I will be glad to see this (aliases), it's one of those things that
> are always are tripping up my students.
>
> What would make even more sense, eventually, is to just deprecate
> the analog numbers entirely, and just have one set of unambiguous
> pin numbers.
> Eliminating what is a needlessly confusing distinction, for example,
> the pwm, interrupt, I2C, SPI, and serial pins do not have their own
> pin numbers.
>
> Then users could just check a pin map for their chip, for the
> hardware on the pin, and get going with the code.
>
> Paul
>
>
> _______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 4

08-05-2010 01:45 AM
|
|
|
> What would make even more sense, eventually, is to just deprecate the analog numbers entirely, and just have one set of unambiguous pin numbers.
Agreed.
IMHO it makes most sense to move towards abandoning the A0, A1, etc. notation & to shift people toward using 14, 15, 16... Preferred intermediate board labeling for me would be A0/14, A1/15, ... eventually shifting to just 14, 15, ...
Leah
_______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 5

08-05-2010 02:19 AM
|
|
|
On 8 May 2010 06:44, giuliano carlini <> wrote:
>> What would make even more sense, eventually, is to just deprecate the
>> analog numbers entirely, and just have one set of unambiguous pin numbers.
>
> Yes! I'd love to see a single set of numbers. But, with aliases, so 1) folks
> don't have to check the pin map for their chip as often and 2) the same
> identical code is more likely to work on different chips. PWM_1-PWM_N,
> SCA_1-SCA_N, SDA_1-SDA_N, MISO_1-MISO_N, etc.
I think this highlights the main issue we have here.
As I see it we have at least three main options mentioned (so far):
* Maintain standard numbering for some or all pins: 0, 1, 2, 3
* Use aliases in some form for some or all pins: A0, PWM1 etc
* Use of function specific numbering: analogRead(0) etc
* Use generic numbering with specific functions. analogRead(14) etc
One of the complicating matters is that (even now, with just
considering 328 & 1280 use) is the issue of compatibility between pin
numbering and functionality.
In terms of non-technical people I suspect that a bunch of
functionality-based acronym-laden aliases is not going to present a
particularly welcoming image. And functionally, it seems no different
to having a compile time look-up in a functionality-specific table.
--Philip;
_______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 6

08-05-2010 02:31 AM
|
|
|
I think it is less confusing for beginners if some indication of
analog or digital is given in any aliasing.
-Jen
On Fri, May 7, 2010 at 9:19 PM, follower <> wrote:
> On 8 May 2010 06:44, giuliano carlini <> wrote:
>>> What would make even more sense, eventually, is to just deprecate the
>>> analog numbers entirely, and just have one set of unambiguous pin numbers.
>>
>> Yes! I'd love to see a single set of numbers. But, with aliases, so 1) folks
>> don't have to check the pin map for their chip as often and 2) the same
>> identical code is more likely to work on different chips. PWM_1-PWM_N,
>> SCA_1-SCA_N, SDA_1-SDA_N, MISO_1-MISO_N, etc.
> I think this highlights the main issue we have here.
>
> As I see it we have at least three main options mentioned (so far):
>
> * Maintain standard numbering for some or all pins: 0, 1, 2, 3
> * Use aliases in some form for some or all pins: A0, PWM1 etc
> * Use of function specific numbering: analogRead(0) etc
> * Use generic numbering with specific functions. analogRead(14) etc
>
> One of the complicating matters is that (even now, with just
> considering 328 & 1280 use) is the issue of compatibility between pin
> numbering and functionality.
>
> In terms of non-technical people I suspect that a bunch of
> functionality-based acronym-laden aliases is not going to present a
> particularly welcoming image. And functionally, it seems no different
> to having a compile time look-up in a functionality-specific table.
>
> --Philip;
>
> _______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 7

08-05-2010 10:06 AM
|
|
|
We could use new code instead of new pin names so pwmWrite for the pwm pins and analogWrite for the analog pins ie
pwmWrite(0,255) only writes to the digital pwm pin 0
analogWrite(0,255) only writes to the analog pin 0
PWM pins are always labeled so beginners dont have to check the pin aliases of their board
James
On 7 May 2010, at 17:23, Paul Badger <> wrote:
> I will be glad to see this (aliases), it's one of those things that are always are tripping up my students.
>
> What would make even more sense, eventually, is to just deprecate the analog numbers entirely, and just have one set of unambiguous pin numbers.
> Eliminating what is a needlessly confusing distinction, for example, the pwm, interrupt, I2C, SPI, and serial pins do not have their own pin numbers.
>
> Then users could just check a pin map for their chip, for the hardware on the pin, and get going with the code.
>
> Paul
>
>
> _______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 8

08-05-2010 05:58 PM
|
|
|
There are a couple of related issues here.
I'll add support to analogRead() for pin numbers 14, 15, etc. That's
necessary whether we want to use those numbers directly or aliases for
them.
I'd also like to add the aliases A0, A1, etc. This fits the existing
hardware well: the Mini Pro, Nano, Fio, and (in lowercase) the LilyPad
already use this notation and it's similar to the numbers on the
Duemilanove and Mega, too.
I'm asking the rest of the team what they think about the longer-term
labeling of the boards. It seems like a bigger change to switch the
analog input pin numbers to 14, 15, etc.
David
On Fri, May 7, 2010 at 8:45 PM, Leah Buechley
<> wrote:
>> What would make even more sense, eventually, is to just deprecate the analog numbers entirely, and just have one set of unambiguous pin numbers.
>
> Agreed.
>
> IMHO it makes most sense to move towards abandoning the A0, A1, etc. notation & to shift people toward using 14, 15, 16... Preferred intermediate board labeling for me would be A0/14, A1/15, ... eventually shifting to just 14, 15, ...
>
> Leah
>
>
> _______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 9

08-05-2010 07:28 PM
|
|
|
If possible, the boards should be labeled with their "digital" pin
number, and their special function label(s). I know board real estate
is tight, but it would be make things easier. I mostly managed it on
the board I designed so I think it should be possible.
So, for the duemilanove, I'd suggest:
0 Rx
1 Tx
2 INT_0
3 PWM_0 INT_1
4
5 PWM_1
6 PWM_2
7
8
9 PWM_3
10 PWM_4 SS
11 PWM_5 MOSI
12 MISO
13 SCK
14 A0
15 A1
16 A2
17 A3
18 A4 SDA
19 A5 SCL
For boards with multiple serial ports, I'd suggest Rx, Tx, Rx_1, Tx_1,
Rx_2, Tx_2, ...
For boards with multiple SPI ports, SS_1, MOSI_1, MISO_1, SCK_1, ...
Ditto other special purposes. I like the underscores rather than
jamming everything together. Though we should stick with Rx, Tx, and
A0, A1, ... for compatibility.
Just my 2 bits.
giuliano
On May 8, 2010, at 9:58 AM, David A. Mellis wrote:
> There are a couple of related issues here.
>
> I'll add support to analogRead() for pin numbers 14, 15, etc. That's
> necessary whether we want to use those numbers directly or aliases for
> them.
>
> I'd also like to add the aliases A0, A1, etc. This fits the existing
> hardware well: the Mini Pro, Nano, Fio, and (in lowercase) the LilyPad
> already use this notation and it's similar to the numbers on the
> Duemilanove and Mega, too.
>
> I'm asking the rest of the team what they think about the longer-term
> labeling of the boards. It seems like a bigger change to switch the
> analog input pin numbers to 14, 15, etc.
>
> David
>
> On Fri, May 7, 2010 at 8:45 PM, Leah Buechley
> <> wrote:
>>> What would make even more sense, eventually, is to just deprecate
>>> the analog numbers entirely, and just have one set of unambiguous
>>> pin numbers.
>>
>> Agreed.
>>
>> IMHO it makes most sense to move towards abandoning the A0, A1,
>> etc. notation & to shift people toward using 14, 15, 16...
>> Preferred intermediate board labeling for me would be A0/14,
>> A1/15, ... eventually shifting to just 14, 15, ...
>>
>> Leah
>>
>>
>> _______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
# 10

08-05-2010 07:28 PM
|
|
|
On Sat, May 8, 2010 at 18:58, David A. Mellis <> wrote:
>
> I'm asking the rest of the team what they think about the longer-term
> labeling of the boards. It seems like a bigger change to switch the
> analog input pin numbers to 14, 15, etc.
As long as old code does not break, I'm glad to see that there is a
sensible short-term solution as well as a long term aim.
-- magnus
_______________________________________________
___________________________________________________
Posted on the Developers mailing list. Go to http://arduino.cc/mailman/listinfo/developers_arduino.cc to subscribe.
|
NewsArc Lists
| Culture Pages
| Computing Archive
| Media-Pages
Link to this page on your blog or website by copying the HTML code below and pasting it into your site:
|
|