Ligne 143 : |
Ligne 143 : |
| Vous pouvez éventuellement utiliser la bibliothèque '''ir_tx''' de Peter Inch (voir ci-dessous) | | Vous pouvez éventuellement utiliser la bibliothèque '''ir_tx''' de Peter Inch (voir ci-dessous) |
| | | |
− | === Receiving pulse === | + | === Recevoir des codes IR === |
| | | |
| Peter Inch à fait un excellent travail avec sa [https://github.com/peterhinch/micropython_ir bibliothèque '''micropython_ir'''] . | | Peter Inch à fait un excellent travail avec sa [https://github.com/peterhinch/micropython_ir bibliothèque '''micropython_ir'''] . |
Ligne 150 : |
Ligne 150 : |
| | | |
| Le protocole NEC est l'un des plus répandus. Si vous avez une veille télécommande, il y a de fortes changes qu'elle utilise le protocole d'émission NEC. | | Le protocole NEC est l'un des plus répandus. Si vous avez une veille télécommande, il y a de fortes changes qu'elle utilise le protocole d'émission NEC. |
| + | |
| + | [[Fichier:MicroPython-esp32-evb-NEC-Remote.jpg|250px]] |
| + | |
| + | Le code d'exemple suivant à été testé directement sur la plateforme ESP32-EVB (GPIO 39) |
| | | |
| <syntaxhighlight lang="python"> | | <syntaxhighlight lang="python"> |
Ligne 193 : |
Ligne 197 : |
| * [http://docs.micropython.org/en/v1.15/library/esp32.html#rmt Documentation Officielle du module RMT] | | * [http://docs.micropython.org/en/v1.15/library/esp32.html#rmt Documentation Officielle du module RMT] |
| * [http://blog.bschwind.com/2016/05/29/sending-infrared-commands-from-a-raspberry-pi-without-lirc/ Excellent article bien documenté sur la réception et décodage de signaux IR sur un GPIO]. | | * [http://blog.bschwind.com/2016/05/29/sending-infrared-commands-from-a-raspberry-pi-without-lirc/ Excellent article bien documenté sur la réception et décodage de signaux IR sur un GPIO]. |
| + | |
| + | == Interface CAN == |
| + | {{ambox-stop|text=Le firmware officiel ESP32 ne contient pas de classe CAN. }} |
| + | |
| + | Ceci étant, nos86 à produit une [https://github.com/nos86/micropython/tree/esp32-can-driver version de MicroPython V1.13 pour ESP32 incluant un module machine_can.c] ainsi que l'exemple [https://github.com/nos86/micropython/blob/esp32-can-driver/examples/esp32_can.py esp32_can.py] autour du transciever MCP2251 (comme sur la présente carte). |
| + | |
| + | Il y a bien eu une tentative de [https://github.com/micropython/micropython/pull/5310 Pull-Request #5310] mais ce dernier n'est pas arrivé à terme, il ne suivait pas l'interface {{fname|machine.CAN}} du port STM32. |
| | | |
| == Interface LAN8710A == | | == Interface LAN8710A == |
Ligne 204 : |
Ligne 215 : |
| lan = network.LAN( id=None, clk_type=3, mdc=Pin(23), mdio=Pin(18), power=Pin(21), phy_addr=1, phy_type=network.PHY_LAN8720 ) | | lan = network.LAN( id=None, clk_type=3, mdc=Pin(23), mdio=Pin(18), power=Pin(21), phy_addr=1, phy_type=network.PHY_LAN8720 ) |
| </nowiki> | | </nowiki> |
| + | |
| + | == GPIO == |
| + | Les GPIO disponibles sur la carte s'utilisent comme n'importe quel GPIO sous MicroPython. |
| + | |
| + | '''Attention:''' Les fonctions de la carte (relais, CAN, IR, etc) sont également indiqué sur la documentation du GPIO |
| + | |
| + | [[Fichier:MicroPython-esp32-evb-GPIO.jpg]] |
| | | |
| == Où acheter == | | == Où acheter == |