Cette compilation comprend des articles intégrés de l'actuel Elektor entre juillet 2012 et novembre 2014.
Les documents suivants sont inclus dans le numéro de document (PDF) avec la fonction de navigation disponible et les articles sont intéressants.
Practical Multitasking Fundamentals
Programming embedded systems is difficult because of resource constraints and limited debugging facilities. Why develop your own Real-Time Operating System (RTOS) as well as your application when the proven FreeRTOS software is freely available? Why not start with a validated foundation?
Every software developer knows that you must divide a difficult problem into smaller ones to conquer it. Using separate preemptive tasks and FreeRTOS communication mechanisms, a clean separation of functions is achieved within the entire application. This results in safe and maintainable designs.
Practicing engineers and students alike can use this book and the ESP32 Arduino environment to wade into FreeRTOS concepts at a comfortable pace. The well-organized text enables you to master each concept before starting the next chapter. Practical breadboard experiments and schematics are included to bring the lessons home. Experience is the best teacher.
Each chapter includes exercises to test your knowledge. The coverage of the FreeRTOS Application Programming Interface (API) is complete for the ESP32 Arduino environment. You can apply what you learn to other FreeRTOS environments, including Espressif’s ESP-IDF. The source code is available from GitHub. All of these resources put you in the driver’s seat when it is time to develop your next uber-cool ESP32 project.
What you will learn:
How preemptive scheduling works within FreeRTOS
The Arduino startup “loopTask”
Message queues
FreeRTOS timers and the IDLE task
The semaphore, mutex, and their differences
The mailbox and its application
Real-time task priorities and its effect
Interrupt interaction and use with FreeRTOS
Queue sets
Notifying tasks with events
Event groups
Critical sections
Task local storage
The gatekeeper task
Design IoT Projects with Raspberry Pi, Arduino and ESP32 The Internet of Things (IoT) is becoming a major application area for embedded systems. As a result, more and more people are becoming interested in learning about embedded design and programming. Technical colleges and universities are moving away from legacy 8 and 16-bit microcontrollers and are introducing 32-bit embedded microcontrollers to their curriculums. Many IoT applications demand precision, high processing power, and low power consumption. Produced by IBM, Node-RED is an open-source visual editor for wiring the Internet of Things. Node-RED comes with a large number of nodes to handle a multitude of tasks. The required nodes are selected and joined together to perform a particular task. Node-RED is based on flow type programming where nodes are configured and joined together to form an application program. There are nodes for performing complex tasks, including web access, Twitter, E-mail, HTTP, Bluetooth, MQTT, controlling GPIO ports, etc. One particularly nice aspect of Node-RED is that the programmer does not need to learn how to write complex programs. For example, an email can be sent by simply joining nodes together and writing only a few lines of code. The aim of this book is to teach how Node-RED can be used in projects. The main hardware platform used with most of the projects in this book is Raspberry Pi 4. Chapters are included to show how Node-RED can be also be used with Arduino Uno, ESP32 DevKitC, and the ESP8266 NodeMCU microcontroller development boards.
En moins de 100 lignes de code par projet avec les cartes Feather Sense et Clue Express d'Adafruit
Le langage de programmation Python est apprécié par les pédagogues parce que sa syntaxe le rend facile à comprendre. Il s'est également imposé chez les informaticiens expérimentés. La société Adafruit a développé une version spéciale de Python pour l'embarquer sur les microcontrôleurs à 32 bits : CircuitPython.
Ce livre permettra au lecteur de s'initier à la programmation en CircuitPython sur deux cartes : Feather BlueFruit Sense (également appelée Feather nRF52840 Sense) et CLUE nRF52840 Express. Chacune est animée par le SoC nRF52840 de NORDIC avec une architecture à 32 bits.
Pour ce voyage dans le monde de la programmation embarquée, l'auteur sort du chemin classique, à savoir un cours complet sur la programmation orientée objet appliquée à ce langage. Il préfère emmener le lecteur directement sur le terrain avec des projets qui mettent en oeuvre les cartes et différents périphériques. Plus d'une quarantaine d'exemples et de montages permettent de découvrir la richesse de CircuitPython. Toutefois l'auteur s'est imposé une limite pour ne pas décourager les novices : le code de chaque projet ne dépasse jamais la centaine de lignes. Pour ce qui est du matériel, là aussi la simplicité domine : aucun programmateur, un simple PC suffit ; aucun soudage grâce au câblage sur platine d'essai. Les cartes d'extension FeatherWing à enficher sur la Feather nRF52840 Sense permettent de démultiplier ses fonctions : matrice de LED, enregistreur de données, écran à encre électronique, écran OLED, écran TFT, commande de moteurs, audio, relais…
Toutes les étapes (assemblage des différents composants, installation des bibliothèques requises, programmation, tests…) sont expliquées en détail. Le code des différents exemples et projets est disponible sur Github. Le résultat de chaque projet est même présenté sur de courtes vidéos disponibles sur YouTube.
À la fin de sa lecture, le nouveau Pythonien pourra facilement approfondir les notions abordées et donner vie à ses propres projets grâce aux outils qu'il aura essayés.
Ce livre s'adresse aux lycéens et étudiants ainsi qu'à toute la communauté des makers.
Chaîne YouTube de l'auteur :
YouTube (Michaël Bottin)
USB-Logikanalysatoren am PC mit Arduino, Raspberry Pi und Co
Schritt-für-Schritt-Anleitungen führen Sie in die Analyse moderner Protokolle von I²C, SPI, UART, RS-232, NeoPixel, WS28xx, HD44780 und 1-Wire ein. Anhand zahlreicher Experimentierschaltungen mit dem Raspberry Pi Pico, Arduino Uno und dem Bus Pirate üben Sie die praxisnahe Anwendung gängiger USB-Logikanalysatoren ein.
Alle in diesem Buch vorgestellten Experimentierschaltungen wurden gründlich getestet und sind funktionsfähig. Die notwendigen Programmlistings sind enthalten, es sind keine besonderen Programmier- oder Elektronikkenntnisse für diese Schaltungen notwendig. Es werden die Programmiersprachen MicroPython und C mit den Entwicklungsumgebungen Thonny und Arduino IDE eingesetzt.
Dieses Buch verwendet mehrere Modelle flexibler und weit verbreiteter USB-Logikanalysatoren und zeigt die Stärken und Schwächen jeder Preisklasse. Sie werden herausfinden, welche Kriterien für Ihre Arbeit wichtig sind und in der Lage sein, das passende Gerät für Sie zu finden.
Egal ob Arduino, Raspberry Pi oder Raspberry Pi Pico: Die abgebildeten Beispielschaltungen ermöglichen einen schnellen Einstieg in die Protokollanalyse und können auch als Grundlage für eigene weitere Experimente dienen.
Sie werden alle wichtigen Begriffe und Zusammenhänge kennenlernen, eigene Experimente durchführen, selbstständig Protokolle analysieren und nach der Lektüre dieses Buches – im Bereich der digitalen Signale und Protokolle – ein umfassendes Wissen aufgebaut haben.
Learn how to use the ESP32 Microcontroller and MicroPython programming in your future projects!
The project book, written by well-known Elektor author Dogan Ibrahim, holds many software- and hardware-based projects especially developed for the MakePython ESP32 Development Kit. The kit comes with several LEDs, sensors, and actuators. The kit will help you acquire the basic knowledge to create IoT projects.
The book’s fully evaluated projects feature all the supplied components. Each project includes a block diagram, a circuit diagram, a full program listing, and a complete program description.
Included in the kit
1x MakePython ESP32 development board with LCD
1x Ultrasonic ranging module
1x Temperature and humidity sensor
1x Buzzer module
1x DS18B20 module
1x Infrared module
1x Potentiometer
1x WS2812 module
1x Sound sensor
1x Vibration sensor
1x Photosensitive resistance module
1x Pulse sensor
1x Servo motor
1x USB cable
2x Button
2x Breadboard
45x Jumper wire
10x Resistor 330R
10x LED (Red)
10x LED (Green)
1x Project book (206 pages)
46 Projects in the Book
LED Projects
Blinking LED
Flashing SOS
Blinking LED – using a timer
Alternately flashing LEDs
Button control
Changing the LED flashing rate using pushbutton interrupts
Chasing-LEDs
Binary-counting LEDs
Christmas lights (random-flashing 8 LEDs)
Electronic dice
Lucky day of the week
Pulsewidth Modulation (PWM) Projects
Generate a 1000-Hz PWM waveform with 50% duty cycle
LED brightness control
Measuring the frequency and duty cycle of a PWM waveform
Melody maker
Simple electronic organ
Servo motor control
Servo motor DS18B20 thermometer
Analog To Digital Converter (ADC) Projects
Voltmeter
Plotting the analog input voltage
ESP32 internal temperature sensor
Ohmmeter
Photosensitive resistance module
Digital To Analog Converter (DAC) Projects
Generating fixed voltages
Generating a sawtooth-wave signal
Generating a triangular-wave signal
Arbitrary periodic waveform
Generating a sinewave signal
Generating accurate sinewave signal using timer interrupts
Using The OLED Display
Seconds counter
Event counter
DS18B20 OLED based digital thermometer
ON-OFF temperature controller
Measuring the temperature and humidity
Ultrasonic distance measurement
Height of a person (stadiometer)
Heart rate (pulse) measurement
Other Sensors Supplied with the Kit
Theft alarm
Sound-activated light
Infrared obstacle avoidance with buzzer
WS2812 RGB LED ring
Timestamping temperature and humidity readings
Network Programming
Wi-Fi scanner
Remote control from the Internet browser (using a smartphone or PC) – Web Server
Storing temperature and humidity data in the Cloud
Low-Power Operation
Using a timer to wake up the processor
Construisez votre station météo idéale ou explorez les données environnementales avec le monde entier. Avec de nombreux projets pratiques pour Arduino, Raspberry Pi, NodeMCU, ESP32 et autres cartes de développement.
Les stations météo jouissent d’une grande popularité depuis des décennies. Tous les magazines d’électronique, qu’ils soient récents ou non, ont publié et publient régulièrement des articles sur la construction d’une station météo. Au fil des années, elles sont devenues de plus en plus sophistiquées et peuvent aujourd’hui être entièrement intégrées dans la maison intelligente. Ceci implique toutefois souvent une fidélité à un fabricant de produits de marque (coûteux) pour tous les composants.
Cependant, avec votre propre station météo, vous pouvez facilement suivre le rythme et même capturer des relevés que les appareils commerciaux ne peuvent pas réaliser. Le plaisir ne manque pas : vous développerez de manière ludique vos connaissances en électronique, en cartes de développement de microcontrôleurs modernes et en langages de programmation. Pour moins de dix euros, vous pouvez collecter des données environnementales initiales et étendre votre système au fur et à mesure que votre intérêt grandit.
Dans ce numéro
Sur la route du vent et de la météo
Écran météo OpenWeatherMap à affichage fluorescent
Les composés organiques volatils dans l‘air que nous respirons
Travailler avec les capteurs MQ : mesurer le monoxyde de carbone
Détecteur de CO2 avec connexion IdO vers ThingSpeak
Un arrosage automatique pour vos plantes
Un climat intérieur sain : la température et l‘humidité de l‘air sont importants
Thermomètre avec tubes Nixie
Une maison météo rétro pour toute la famille
Mesurez la pression atmosphérique et la température avec précision
Un détecteur de coups de soleil
Capteur maison pour la durée d‘ensoleillement
Le smartphone l‘indique : brouillard ou bonne visibilité ?
Détecter les tremblements de terre
Les niveaux des cours d‘eau et des réservoirs
Évaluer la valeur du pH de l’eau
Détecter les rayonnements radioactifs
Avec le GPS, vous savez où se trouve votre capteur
Enregistrer les fichiers journaux avec horodatage sur des cartes SD
LoRaWAN, The Things Network et ThingSpeak
Exploiter la passerelle LoRaWAN pour le TTN
Affichage géant à led avec prévisions météo
Ce qui se passe en électronique est par définition invisible à l'oeil nu. L'instrument qui permet précisément de rendre visibles les signaux électriques, celui par le truchement duquel les effets de l'électronique se manifestent à nous, c'est l'oscilloscope.
Hélas, quand on commence à faire de l'électronique, c'est souvent sans oscilloscope. Et l'on en est réduit à tâtonner, aussi bien physiquement que mentalement. Le jour où l'on goûte à la visualisation des signaux sur un écran, c'est une révélation. Plus personne ne souhaite se priver de cet enchantement. Pas de retour en arrière. En électronique, si l'on veut progresser dans le plaisir et dans la compréhension, il faut un oscillo.
Commence alors une période d'interrogation : comment choisir ? Et à peine cette question-là aura-t-elle trouvé sa réponse, il en viendra une ribambelle d'autres que l'on peut résumer en une seule : comment se servir de l'oscilloscope de telle sorte que ce qu'il affiche corresponde bien à la réalité des signaux ?
Dans ce livre, Rémy Mallard, répond clairement à ces questions. Il donne aussi de nombreuses informations pour aider son lecteur à élucider lui-même de nouveaux mystères qui ne manqueront pas de surgir. Ceux qui le connaissent déjà comme l'auteur d'un livre sur l'électronique dont le titre est un programme à lui tout seul : L'électronique pour les débutants qui sèchent les cours mais soudent sans se brûler les doigts, ainsi que d'un livre d'initiation à la programmation des microcontrôleurs PIC, savent qu'ils trouveront ici un ouvrage utile, qu'ils rouvriront souvent.
Dit boek gaat over de Raspberry Pi, en over het programmeren in C. De programmeertaal C en het besturingssysteem Linux (Raspbian) passen uitstekend bij elkaar. Alles wat we nodig hebben om in C te programmeren wordt meegeleverd met het besturingssysteem van de Raspberry Pi.
In dit boek leert u hoe C gebruikt wordt met de Raspberry Pi, en krijgt u een overzicht van de taal.
WiringPi is een softwarebibliotheek voor de Raspberry Pi waarmee C hardware-uitbreidingen kan benaderen. Die bibliotheek wordt gebruikt om sensoren uit te lezen en om extra hardware aan te sturen. U gaat experimenteren met LED’s en schakelaars, met motoren, met geluid en met sensoren voor temperatuur, luchtdruk, en luchtvochtigheid.
Met een Linux-systeem kunt u een webserver maken, inclusief interactieve websites met PHP en WiringPi. Daarom is ook een beknopt overzicht van HTML en PHP in het boek opgenomen. In de voorbeelden worden sensoren via het web uitgelezen en worden apparaten bestuurd. In het laatste voorbeeld wordt een temperatuurlogger gemaakt. Die meet elk kwartier de temperatuur. Een tabel met de meetwaarden kan via het web worden uitgelezen.
Alle voorbeeldprogramma’s kunnen worden gedownload van de website van Elektor.
Ce qui se passe en électronique est par définition invisible à l'oeil nu. L'instrument qui permet précisément de rendre visibles les signaux électriques, celui par le truchement duquel les effets de l'électronique se manifestent à nous, c'est l'oscilloscope.
Hélas, quand on commence à faire de l'électronique, c'est souvent sans oscilloscope. Et l'on en est réduit à tâtonner, aussi bien physiquement que mentalement. Le jour où l'on goûte à la visualisation des signaux sur un écran, c'est une révélation. Plus personne ne souhaite se priver de cet enchantement. Pas de retour en arrière. En électronique, si l'on veut progresser dans le plaisir et dans la compréhension, il faut un oscillo.
Commence alors une période d'interrogation : comment choisir ? Et à peine cette question-là aura-t-elle trouvé sa réponse, il en viendra une ribambelle d'autres que l'on peut résumer en une seule : comment se servir de l'oscilloscope de telle sorte que ce qu'il affiche corresponde bien à la réalité des signaux ?
Dans ce livre, Rémy Mallard, répond clairement à ces questions. Il donne aussi de nombreuses informations pour aider son lecteur à élucider lui-même de nouveaux mystères qui ne manqueront pas de surgir. Ceux qui le connaissent déjà comme l'auteur d'un livre sur l'électronique dont le titre est un programme à lui tout seul : L'électronique pour les débutants qui sèchent les cours mais soudent sans se brûler les doigts, ainsi que d'un livre d'initiation à la programmation des microcontrôleurs PIC, savent qu'ils trouveront ici un ouvrage utile, qu'ils rouvriront souvent.
Learning Embedded Systems with STM32 Nucleo Boards
Programming compact electronic systems is now easier to get started with than ever before. Affordable development boards, powerful software tools, and readily available documentation make it possible to turn an idea into a working prototype in very little time. MicroPython plays an important role in this development by offering a readable, interactive way to control microcontrollers while still providing direct access to their hardware features.
This book explores embedded programming with MicroPython using an STM32-based Nucleo board. It shows how a microcontroller continuously interacts with its environment by reading inputs, processing information, and controlling outputs. Step by step, you will learn to flash LEDs, measure analog signals, work with sensors, control actuators, and exchange data with other devices. The built-in REPL makes it easy to test instructions immediately, inspect results, and learn through experimentation.
Although microcontroller boards differ in size, speed, memory, and peripherals, the fundamental concepts remain largely the same. Digital input and output, analog conversion, timers, PWM, interrupts, and serial communication are the essential building blocks of embedded applications.
By concentrating on these transferable principles, the book provides a foundation that remains useful when moving to other boards, processors, or development environments.
It is intended both for newcomers and for programmers who want to expand into embedded systems. MicroPython offers a practical route into this field, combining quick results with a clear understanding of how software and hardware work together.
Hands-on in more than 50 projects
STM32 Nucleo family of processors are manufactured by STMicroelectronics. These are low-cost ARM microcontroller development boards. This book is about developing projects using the popular STM32CubeIDE software with the Nucleo-L476RG development board. In the early Chapters of the book the architecture of the Nucleo family is briefly described.
The book covers many projects using most features of the Nucleo-L476RG development board where the full software listings for the STM32CubeIDE are given for each project together with extensive descriptions. The projects range from simple flashing LEDs to more complex projects using modules, devices, and libraries such as GPIO, ADC, DAC, I²C, SPI, LCD, DMA, analogue inputs, power management, X-CUBE-MEMS1 library, DEBUGGING, and others. In addition, several projects are given using the popular Nucleo Expansion Boards. These Expansion Boards plug on top of the Nucleo development boards and provide sensors, relays, accelerometers, gyroscopes, Wi-Fi, and many others. Using an expansion board together with the X-CUBE-MEMS1 library simplifies the task of project development considerably.
All the projects in the book have been tested and are working. The following sub-headings are given for each project: Project Title, Description, Aim, Block Diagram, Circuit Diagram, and Program Listing for the STM32CubeIDE.
In this book you will learn about
STM32 microcontroller architecture;
the Nucleo-L476RG development board in projects using the STM32CubeIDE integrated software development tool;
external and internal interrupts and DMA;
DEBUG, a program developed using the STM32CubeIDE;
the MCU in Sleep, Stop, and in Standby modes;
Nucleo Expansion Boards with the Nucleo development boards.
What you need
a PC with Internet connection and a USB port;
STM32CubeIDE software (available at STMicroelectronics website free of charge)
the project source files, available from the book’s webpage hosted by Elektor;
Nucleo-L476RG development board;
simple electronic devices such as LEDs, temperature sensor, I²C and SPI chips, and a few more;
Nucleo Expansion Boards (optional).