PortManipulation page lacks information about Arduino Mega

Hi,

The PortManipulation page has the names and corresponding pins of the ports on the smaller arduino's but doesn't have this info for my new Arduino Mega 2560. I went through the schematic for the Mega 2560 and made a table of the ports and pins. I think this info should be included on the PortManipulation page, or linked to if that is more stream lined.

Here it is (also attached in a file):

For the Arduino Mega 2560

Pin Port Mapping
0 PORTE 0
1 PORTE 1
2 PORTE 4
3 PORTE 5
4 PORTG 5
5 PORTE 3
6 PORTH 3
7 PORTH 4

8 PORTH 5
9 PORTH 6
10 PORTB 4
11 PORTB 5
12 PORTB 6
13 PORTB 7

14 PORTJ 1
15 PORTJ 0
16 PORTH 1
17 PORTH 0
18 PORTD 3
19 PORTD 2
20 PORTD 1
21 PORTD 0

22 PORTA 0
23 PORTA 1
24 PORTA 2
25 PORTA 3
26 PORTA 4
27 PORTA 5
28 PORTA 6
29 PORTA 7

30 PORTB 7
31 PORTB 6
32 PORTB 5
33 PORTB 4
34 PORTB 3
35 PORTB 2
36 PORTB 1
37 PORTB 0

38 PORTD 7
39 PORTG 2
40 PORTG 1
41 PORTG 0
42 PORTL 7
43 PORTL 6
44 PORTL 5
45 PORTL 4

46 PORTL 3
47 PORTL 2
48 PORTL 1
49 PORTL 0
50 PORTB 3
51 PORTB 2
52 PORTB 1
53 PORTB 0

Mega port mapping (635 Bytes)

Thanks for this list, I'm desigining a Mega clone at present and it was good to have a second opinion to verify my own design against. I did in fact find two pins swapped because I checked against your list.

I also think I have found a bug in the list

30 PORTB 7
31 PORTB 6
32 PORTB 5
33 PORTB 4
34 PORTB 3
35 PORTB 2
36 PORTB 1
37 PORTB 0

30-37 == PC7-0 not PB.

I think the rest is correct, or at least the same as what I have :slight_smile:


Rob

Thank you soooooooooooooooooooooooooo muucchh!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

thanks,

I am sending this to the documentation team,

/d

The mapping is available in the schematic: http://arduino.cc/en/uploads/Main/arduino-mega2560-schematic.pdf

The mapping is available in the schematic:

True, but it's not in a convenient tabular form.


Rob

Please see http://arduino.cc/en/Hacking/PinMapping2560 for the 2560 pin mapping and convenient tablular presentation.

Vielen Dank für diese Aufstellung :smiley: ich habe schon den ganzen Tag daran gesessen dafür eine Lösung zu erarbeiten :smiley:

And the page lacks instructions about reading pins.
-Malhar