Modifications

Sauter à la navigation Sauter à la recherche
878 octets ajoutés ,  18 octobre 2013 à 15:36
aucun résumé de modification
Ligne 2 : Ligne 2 :     
== Brochage du GPIO ==
 
== Brochage du GPIO ==
{{bloc-etroit|text=Pin numbering of the BCM2835 GPIO port(s) on the Raspberry Pi has been a source of great confusion since the designs for the Pi were first published. In the early days (even beofre hardware was avalable) the default usable GPIO pins were simply referred to by number as GPIO0 through GPIO7. Additionally there were pins for other purposes, SPI, I2C and serial. This was highlighted on the original image on the Raspberry Pi Wiki site too.
+
{{bloc-etroit|text=La numérotation des broches de(s) port(s) GPIO du BCM2835 GPIO sur le Raspberry Pi est source d'une grande confusion et ce depuis la publication des informations de conception du Pi.  
   −
So when initially writing wiringPi, I chose to have the same default pin numbering scheme and numbered them from 0 upwards. This is no different to how the Arduino operates – “Pin 13″ on the Arduino is Port B, bit 5 for example. The underlying hardware definitions are hidden by a simplified numbering scheme. On the Pi, using wiringPi, pin 0 is BCM_GPIO pin 17 for example)
+
Au début (avant même la disponibilité de la première version matérielle) les broches GPIO utilisaient tout simplement des référencées numérotées sous GPIO0 à GPIO7.  
   −
However this has subsequently been viewed as “wrong” and several people have expressed concern about my numbering scheme, however I’ve stuck with it (as by then people were using wiringPi). and it’s proven its worth over the hardware board revisions where some pins changed their hardware definitions, however wiringPi was able to hide this from the user. As a result (for example) a program that uses wiringPi pin 2 on a Rev. 1 Pi will work unchanged on a Rev 2. Pi, however someone using BCM_GPIO pin 21 on a Rev 1 Pi will need to change their program to use BCM_GPIO pin 27 on a Rev 2.}}
+
Par la suite, d'autres broches furent ajoutées pour d'autres utilisations générales, SPI, I2C et port série. Cela fut également mis en avant sur Wiki du Raspberry Pi.
   −
So wiringPi supports its own pin numbering scheme as well as the BCM_GPIO pin numbering scheme, and as of Version 2, it also supports the physical hardware pin numbers (for the P1 connector only), but I would like to suggest you stick to the simplified wiringPi pin numbers. That way your programs will be portable over different hardware revisions without needing any changes.
+
Lors de l'écriture initiale de WiringPi, Gordon décida d'utiliser le même schéma de numérotation des broches (schéma par défaut) en commençant par 0. Cela n'est pas différent de la façon dont Arduino gère les numéros de broches – par exemple, la "Pin 13" sur un Arduino correspond au bit 5 du port B. La définition matériel sous-jacente est caché sous un schéma de numérotation simplifié (comme la numérotation de 0 à 13 pour les broches Arduino).  
   −
The following tables give the mapping of the Raspberry Pi GPIO Pins to the (P1) GPIO connector in relation to the pin numbers and the physical location on the connector. This is a representation of the GPIO connector as viewed looking at the board from above. The GPIO connector is to the top-right of the board with the Ethernet and USB sockets to the bottom.
+
Par exemple, en utilisant WiringPi sur votre Raspberry, la "pin 0" correspond à la broche "GPIO broche 17" du BCM.
 +
 
 +
Plusieurs personnes voyait cette approche comme "erronée" et ont exprimés leur préoccupations vis-à-vis de ce schéma de numérotation. Cependant, Gordon était coincé avec ce schéma (de plus en plus de personnes utilisaient wiringPi). Mais ce modèle fit ses preuves au cours des différentes révisions matérielles où certaines broches furent déplacées sur le GPIO. Le modèle utilisé par WiringPi fut capable de caché ces changements à l'utilisateur. }}
 +
 
 +
Par conséquent, à titre d'exemple, un programme qui utilise la broche 2 de wiringPi sur un Pi révision 1 fonctionnera sans changement sur une révision 2. Cependant, si quelqu'un utilisait directement la broche BCM_GPIO 21 sur un Pi résivion 1, il devait alors modifier son programme pour utiliser la broche BCM_GPIO 27 sur un Pi révision 2.
 +
 
 +
Pour finir, wiringPi supporte son propre schéma de numérotation simplifié ainsi que le schéma de numération BCM_GPIO des broches, comme celui de la Version 2. WiringPi supporte également la numérotation matérielle (''physical hardware pin numbers'') mais uniquement pour le connecteur P1.
 +
Bien que vous ayez le choix entre les numérotations, Gordon suggère de suivre la numérotation simplifiée. Cela permettra à votre programme de rester "portable" entre les différentes révisions matérielles sans nécessiter aucun changement dans votre programme.
 +
 
 +
Les tables suivantes fournissent un mapping des broches GPIO du Raspberry Pi sur le connecteur GPIO (P1) en relation avec le numéro de broche et la localisation physique sur le connecteur. Il s'agit d'une représentation du connecteur GPIO tel qu'il est vu par le dessus. Le connecteur GPIO se situe en haut et droite de la carte lorsque la prise Ethernet et USB sont situés en bas.
    
[[Fichier:Pi-WiringPi-GPIO-01.png]]
 
[[Fichier:Pi-WiringPi-GPIO-01.png]]
   −
Révision des cartes:
+
=== Révision des cartes ===
    
Faite attention aux différences entre les révisions 1 et 2 des cartes (Rv1 et Rv2 ci-dessus). La révision 2 est facilement identifiable par la présence de 2 tours de fixation.
 
Faite attention aux différences entre les révisions 1 et 2 des cartes (Rv1 et Rv2 ci-dessus). La révision 2 est facilement identifiable par la présence de 2 tours de fixation.
 +
 +
== Connecteur P5 ==
 +
Votre Raspberry Pi dispose d'un second GPIO "caché"... ce dernier est présent mais ne dispose pas de connecteur.
    
[[Fichier:Pi-WiringPi-GPIO-02.png]]
 
[[Fichier:Pi-WiringPi-GPIO-02.png]]
29 917

modifications

Menu de navigation