arduino_haute_frequence
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
arduino_haute_frequence [2022/09/05 18:28] – [Récupération de la position sur RaspberryPI en python avec SPI] serge | arduino_haute_frequence [2022/09/06 07:24] (Version actuelle) – [Optical Encoder USDigital] serge | ||
---|---|---|---|
Ligne 33: | Ligne 33: | ||
</ | </ | ||
- | + | Ce sketch fonctionne bien sur UNO, mais la UNO n'a que 2 interruptions. Il n'est pas possible d' | |
- | =====SPI entre Raspberry et Arduino===== | + | |
- | **Avec arduino en mode slave** | + | |
- | + | ||
- | ====Ressources==== | + | |
- | * **[[http:// | + | |
- | + | ||
- | ====Slave Mode with SPI.h==== | + | |
- | **et avec des interrupt** | + | |
- | **[[https:// | + | |
- | SPI.h library by default only support Master mode, the SPI.begin() will automatically set slave select (ss) pin to HIGH whether you have pinMode(ss, OUTPUT) in your setup() code or not and set the Arduino as an SPI master. | + | |
- | As the SPI library does not contain the functionality for slave mode, in order to use Arduino as a Slave, you will need to do some customised setup, mainly on | + | |
- | - setting MISO as OUTPUT for slave to send data | + | |
- | - enable slave mode by setting the SPCR register | + | |
- | - enable interrupt when data is received. | + | |
- | + | ||
- | ====Nick Gammon explique tout sur le SPI==== | + | |
- | * **[[http:// | + | |
- | + | ||
- | Les scripts sont sur **[[https:// | + | |
- | + | ||
- | ===How to make an SPI slave=== | + | |
- | * [[https:// | + | |
- | * [[https:// | + | |
- | Montre le problème du 1er transfert. | + | |
- | + | ||
- | ===How to get a response from a slave=== | + | |
- | * https:// | + | |
- | * https:// | + | |
- | * [[https:// | + | |
- | + | ||
- | ===Envoyez et recevez tout type de données === | + | |
- | * https:// | + | |
- | + | ||
{{tag> | {{tag> |
arduino_haute_frequence.txt · Dernière modification : 2022/09/06 07:24 de serge