For Raspberry Pi, ESP32 and nRF52 with Python, Arduino and Zephyr
Bluetooth Low Energy (BLE) radio chips are ubiquitous from Raspberry Pi to light bulbs. BLE is an elaborate technology with a comprehensive specification, but the basics are quite accessible.
A progressive and systematic approach will lead you far in mastering this wireless communication technique, which is essential for working in low power scenarios.
In this book, you’ll learn how to:
Discover BLE devices in the neighborhood by listening to their advertisements.
Create your own BLE devices advertising data.
Connect to BLE devices such as heart rate monitors and proximity reporters.
Create secure connections to BLE devices with encryption and authentication.
Understand BLE service and profile specifications and implement them.
Reverse engineer a BLE device with a proprietary implementation and control it with your own software.
Make your BLE devices use as little power as possible.
This book shows you the ropes of BLE programming with Python and the Bleak library on a Raspberry Pi or PC, with C++ and NimBLE-Arduino on Espressif’s ESP32 development boards, and with C on one of the development boards supported by the Zephyr real-time operating system, such as Nordic Semiconductor's nRF52 boards.
Starting with a very little amount of theory, you’ll develop code right from the beginning. After you’ve completed this book, you’ll know enough to create your own BLE applications.
Projects with Thonny-IDE, uPyCraft-IDE, and ESP32
The 'Python' programming language has enjoyed an enormous upswing in recent years. Not least, various single-board systems such as the Raspberry Pi have contributed to its popularity. But Python has also found widespread use in other fields, such as artificial intelligence (AI) or machine learning (ML). It is obvious, therefore, to use Python or the 'MicroPython' variant for use in SoCs (Systems on Chip) as well.
Powerful controllers such as the ESP32 from Espressif Systems offer excellent performance as well as Wi-Fi and Bluetooth functionality at an affordable price. With these features, the Maker scene has been taken by storm. Compared to other controllers, the ESP32 has a significantly larger flash and SRAM memory, as well as a much higher CPU speed. Due to these characteristics, the chip is not only suitable for classic C applications, but also for programming with MicroPython.
This book introduces the application of modern one-chip systems. In addition to the technical background, the focus is on MicroPython itself. After the introduction to the language, the programming skills learned are immediately put into practice. The individual projects are suitable for use in the laboratory as well as for everyday applications. So, in addition to the actual learning effect, the focus is also on the joy of building complete and useful devices. By using laboratory breadboards, circuits of all kinds can be realized with little effort, turning the testing and debugging of the 100% homebrew projects into an instructive pleasure.
The various applications, such as weather stations, digital voltmeters, ultrasound range finders, RFID card readers or function generators, make the projects presented ideally suited for practical courses or subject and study work in the natural sciences, or in science and technology classes.
A Handbook on DIY
Nowadays, security problems are rarely properly solved or correctly addressed. Electronic security is only part of the chain in making a system secure. Electronic security is usually addressed as network or software security, neglecting other aspects, but the chain is only as strong as its weakest link.
This book is about electronic hardware security, with an emphasis on problems that you can solve on a shoestring DIY budget. It deals mostly with secure communications, cryptosystems, and espionage. You will quickly appreciate that you can’t simply buy a trustworthy and reliable cryptosystem off the shelf. You will then realise that this applies equally to individuals, corporations, and governments.
If you want to increase your electronic security awareness in a world already overcrowded with networks of microphones and cameras, this is a book for you. Furthermore, if you want to do something DIY by designing and expanding upon simple electronic systems, please continue reading. Some of the devices described are already published as projects in the Elektor magazine. Some are still ideas yet to be worked out.
Complexity is the main enemy of security, so we'll try to keep to simple systems. Every chapter will analyse real-life espionage events or at least several hypothetical scenarios that will hopefully spark your imagination. The final goal is to build a security-conscious mindset (or “to get into a head of a spy”) which is necessary to recognise possible threats beforehand, to design a truly secure system.
Don’t bother reading if:
you think you and your secrets are 100% safe and secure
you think somebody else can effectively handle your security
you think conspiracy theories only exist in theory – Telefunken’s masterpiece the “FS-5000 Harpoon” was built on one!
Technology is constantly changing. New microcontrollers become available every year. The one thing that has stayed the same is the C programming language used to program these microcontrollers. If you would like to learn this standard language to program microcontrollers, then this book is for you!
Arduino is the hardware platform used to teach the C programming language as Arduino boards are available worldwide and contain the popular AVR microcontrollers from Atmel.
Atmel Studio is used as the development environment for writing C programs for AVR microcontrollers. It is a full-featured integrated development environment (IDE) that uses the GCC C software tools for AVR microcontrollers and is free to download.
At a glance:
Start learning to program from the very first chapter
No programming experience is necessary
Learn by doing – type and run the example programs
A fun way to learn the C programming language
Ideal for electronic hobbyists, students and engineers wanting to learn the C programming language in an embedded environment on AVR microcontrollers
Use the free full-featured Atmel Studio IDE software for Windows
Write C programs for 8-bit AVR microcontrollers as found on the Arduino Uno and MEGA boards
Example code runs on Arduino Uno and Arduino MEGA 2560 boards and can be adapted to run on other AVR microcontrollers or boards
Use the AVR Dragon programmer/debugger in conjunction with Atmel Studio to debug C programs
Develop your own custom home automation devices
Espressif's ESP8266 and ESP32 microcontrollers have brought DIY home automation to the masses. However, not everyone is fluent in programming these microcontrollers with Espressif's C/C++ SDK, the Arduino core, or MicroPython. This is where ESPHome comes into its own: with this project, you don’t program your microcontroller but configure it.
This book demonstrates how to create your own home automation devices with ESPHome on an ESP32 microcontroller board. You’ll learn how to combine all kinds of electronic components and automate complex behaviours. Your devices can work completely autonomously, and connect over Wi-Fi to your home automation gateways such as Home Assistant or MQTT broker.
By the end of this book, you will be able to create your own custom home automation devices the way you want. Thanks to ESPHome and the ESP32, this is within everyone’s grasp.
Set up an ESPHome development environment and create maintainable configurations
Use buttons and LEDs
Sound a buzzer and play melodies
Read measurements from various types of sensors
Communicate over a short distance with NFC, infrared light, and Bluetooth Low Energy
Show information on various types of displays
Downloads
Software
TINA Design Suite is a professional, powerful and affordable circuit simulator. It is a circuit designer and PCB design software package for analysing, designing, and real-time testing of analogue, digital, IBIS, VHDL, Verilog, Verilog AMS, SystemC, MCU, and mixed electronic circuits and their PCB layouts.
In this book, top-selling Elektor author, Prof. Dr. Dogan Ibrahim aims to teach the design and analysis of electrical and electronic circuits and develop PCB boards using both TINA and TINACloud. The book is aimed at electrical/electronic engineers, undergraduate electronic/electrical engineering students at technical colleges and universities, postgraduate and research students, teachers, and hobbyists. Many tested and working simulation examples are provided covering most fields of analogue and digital electrical/electronic engineering. These include AC and DC circuits, diodes, zener diodes, transistor circuits, operational amplifiers, ladder diagrams, 3-phase circuits, mutual inductance, rectifier circuits, oscillators, active and passive filter circuits, digital logic, VHDL, MCUs, switch-mode power supplies, PCB design, Fourier series, and spectrum. Readers do not need to have any programming experience unless they wish to simulate complex MCU circuits.
Clever Tricks with ATmega328 Pro Mini Boards
With a simple Pro Mini board and a few other components, projects that 20 or 30 years ago were unthinkable (or would have cost a small fortune) are realized easily and affordably in this book: From simple LED effects to a full battery charging and testing station that will put a rechargeable through its paces, there’s something for everyone.
All the projects are based on the ATmega328 microcontroller, which offers endless measuring, switching, and control options with its 20 input and output lines. For example, with a 7-segment display and a few resistors, you can build a voltmeter or an NTC-based thermometer. The Arduino platform offers the perfect development environment for programming this range of boards.
Besides these very practical projects, the book also provides the necessary knowledge for you to create projects based on your own ideas. How to measure, and what? Which transistor is suitable for switching a certain load? When is it better to use an IC? How do you switch mains voltage? Even LilyPad-based battery-operated projects are discussed in detail, as well as many different motors, from simple DC motors to stepper motors.
Sensors are another exciting topic: For example, a simple infrared receiver that can give disused remote controls a new lease on life controlling your home, and a tiny component that can actually measure the difference in air pressure between floor and table height!
Analogue Electronics and Microcontrollers Projects
Hobbyist electronics can be a fun way to learn new skills that can be helpful to your career. Those who understand the basics of electronics can design their own circuits and projects. However, before you run, you need to learn to walk.
It all starts with analogue electronics. You should be familiar with the simple components and circuits and understand their basic behaviors and the issues you may encounter. The best way to do this is through real experiments. Theory alone is not enough. This book offers a large number of practical entry-level circuits, with which everyone can gain the basic experience.
Through the widespread introduction of microcontrollers, a new chapter in electronics has begun. Microcontrollers are now performing more and more tasks that were originally solved using discrete components and conventional ICs. Starting out has become easier and easier thanks to platforms including Bascom, Arduino, micro:bit. The book introduces numerous manageable microcontroller applications. It’s now a case of less soldering and more programming.
In this book the author presents all essential aspects of microcontroller programming, without overloading the reader with unnecessary or quasi-relevant bits of information. Having read the book, you should be able to understand as well as program, 8-bit microcontrollers.
The introduction to microcontroller programming is worked out using microcontrollers from the PIC series. Not exactly state-of-the-art with just 8 bits, the PIC micro has the advantage of being easy to comprehend. It is offered in a DIP enclosure, widely available and not overly complex. The entire datasheet of the PIC micro is shorter by decades than the description of the architecture outlining the processor section of an advanced microcontroller. Simplicity has its advantages here. Having mastered the fundamental operation of a microcontroller, you can easily enter into the realms of advanced softcores later.
Having placed assembly code as the executive programming language in the foreground in the first part of the book, the author reaches a deeper level with ‘C’ in the second part. Cheerfully alongside the official subject matter, the book presents tips & tricks, interesting measurement technology, practical aspects of microcontroller programming, as well as hands-on options for easier working, debugging and faultfinding.
Cool Projects for Test, Measurement, and Control
The Raspberry Pi has dominated the maker scene for many years. Freely accessible I/O pins have made it one of the most popular processor boards of all time. However, the classic Raspberry Pi has no analog inputs. Direct measurement of analog values is therefore not possible. Consequently, photodiodes, NTCs, Hall sensors, etc. cannot be read directly. In addition, the pins are connected directly to the exposed contacts, i.e. without a driver or protection circuit. This can quickly destroy the central controller and thus the entire Raspberry Pi.
These problems can be elegantly solved with the Pico. As a front-end, it can easily handle a wide range of measurement tasks. In addition, the Pico is much cheaper than a classic Raspberry Pi 4 or 5. If a faulty circuit leads to the destruction of the Pico, this is relatively easy to handle. This makes the combination of a classic Raspberry Pi 4 or 5 and the Pico an ideal pair.
The book introduces the broad and highly topical field of modern controller technology using the combined force of a Raspberry Pi 4 or 5 and a Raspberry Pi Pico. In addition to a detailed introduction to the operation and functionality of the controller boards themselves, the book also focuses on data acquisition and processing with digital processors. Especially the combination of both systems offers a wide range of interesting possibilities.
Some practical projects from the contents:
USB between Raspberry Pi 4 or 5 and Pico
I²C Communication and Pico as an I²C device
Voltmeter and Computer Thermometer
Pico W as a Web Server and WLAN Scanner
Frequency Meters and Generators
OLED Displays on Raspberry Pi 4 or 5 and Pico
Energy Saving Monitor
Which Astronauts are in Orbit?
Mini Monitor for Current Bitcoin Exchange Rate
Le monde de l'électronique est à la fois vaste et… tout petit ! Voici un livre qui confirme ces deux constatations contradictoires. En effet, en électronique, tout touche à tout, d'une manière ou d'une autre. Le plus petit détail peut avoir les plus grandes conséquences, et pas toujours celles que l'on attendrait.
L'objectif de l'auteur de cette série d'articles autonomes intitulée hors-circuits, réunis ici en un livre, n'est pas de vous tenir par la main. Robert Lacoste, électronicien professionnel de haut-niveau, vous donne des pistes pour comprendre ce qui paraît mystérieux. Il vous guide juste assez pour vous permettre ensuite de progresser tout seul. Avec lui, non seulement vous repousserez vos propres limites, mais saurez aussi détecter celles du matériel et du logiciel que vous utilisez. En vous invitant à repasser par les notions de physique de base, il vous permettra de séparer les véritables progrès techniques des laïus commerciaux.
Les bases, ça peut mener loin
D'où vient la sensibilité d'un récepteur d'ondes radio ? Pourquoi le téléchargement d'une vidéo sur votre portable est-il beaucoup plus lent à la campagne qu'en centre-ville ? Si pour vous la réponse technique à des questions comme celles-ci (et bien d'autres que vous n'osez peut-être même pas vous poser) n'est pas évidente, ce livre vous aidera à y voir plus clair. Oui, on peut être à l'aise avec les microcontrôleurs, mais dérouté par le comportement d'un simple transistor. Vous sentez-vous concerné par de telles interrogations ? Ce livre est donc pour vous.
Sans aucune formule mathématique qui ne soit pas à la portée d'un lycéen, il balaye tout le champ de l'électronique, depuis l'analogique jusqu'au traitement numérique du signal en passant par le domaine si redouté des hautes-fréquences. La théorie ne s'y éloigne jamais beaucoup de la loi d'Ohm ! Avec des mots simples, l'auteur explique comment ça marche, pourquoi parfois ça ne marche pas comme on veut, et comment mieux utiliser différentes techniques dans vos propres projets pour que ça marche.
Liste des sujets abordés :
adaptation d'impédance : qu'est-ce-que c'est ?
petite introduction aux microrubans
jouons avec la réflectométrie temporelle
circuits imprimés : éviter les bourdes en HF et avec les fréquences élevées
le marquage CE pour les béotiens
le quartz
magie de la PLL VCO & PLL : pour obtenir des fréquences à la fois précises, stables et variables
synthèse numérique directe : une introduction
comprendre l'amplificateur à transistor : sexagénaire vaillant
ampli de classe A, B, C, D, E, F, G, H : quesako ?
le filtrage numérique sans stress : les filtres FIR
le filtrage numérique sans stress : les filtres CIC
le filtrage numérique sans stress : les filtres IIR
l'ABC des CA/N DNL, INL, SNR, SINAD, ENOB, SFDR et consorts
l'ABC des CA/N sigma-delta, quésaco ?
bruit et sensibilité des récepteurs
échange débit contre portée
The short-wave technique has a very particular appeal: It can easily bridge long distances. By reflecting short-wave signals off the conductive layers of the ionosphere, they can be received in places beyond the horizon and therefore can reach anywhere on earth. Although technology is striving for ever higher frequencies, and radio is usually listened to on FM, DAB+, satellite or the Internet, modern means of transmission require extensive infrastructure and are extremely vulnerable. In the event of a global power outage, there is nothing more important than the short-wave. Amateur radio is not only a hobby, it’s also an emergency radio system!
Elektor’s SDR-Shield is a versatile shortwave receiver up to 30 MHz. Using an Arduino and the appropriate software, radio stations, morse signals, SSB stations, and digital signals can be received.
In this book, successful author and enthusiastic radio amateur, Burkhard Kainka describes the modern practice of software defined radio using the Elektor SDR Shield. He not only imparts a theoretical background but also explains numerous open source software tools.
This book discusses the basic components of any alarm system.
All alarm systems have two basic functions. First, they monitor their environment looking for a change such as a door or window opening or someone moving about in the room. Second, they alert the legal owner or user to this change. The system described in this book uses a scanning type software to detect intruders. It behaves like a guard dog, pacing up and down the fence line on the lookout for either an intruder or a familiar person. If you have an alarm key, you can disarm the system and enter.
With the scanning method, the software is easy to write and explain. It can scan eight alarm zones plus two special fire zones in about one second.
You don’t have to be an electrical engineer to install an alarm system, just a decent carpenter, painter, and plasterer! Because this alarm system runs on 12 volts, you don’t have to be a licensed electrician either to install it. The alarm system presented here uses Python software on the Raspberry Pi combined with some elementary electronic circuits. The code described in the book, as well as CAD files and a bill of materials for the alarm panel, are available for free downloading. The book provides the reader with examples of typical configurations coming straight from the author‘s experience. After reviewing the hardware components typically used in common alarm systems, the author shows how to plan one yourself.
To implement a modular alarm, no matter if it is for a single house or for a business or restaurant, the book shows how to skillfully combine a Raspberry Pi with small auxiliary electronic circuits. These are not installation instructions but food for thought that will enable readers to find a solution to their needs.
Get Cracking with the Arduino Nano V3, Nano Every, and Nano 33 IoT
The seven chapters in this book serve as the first step for novices and microcontroller enthusiasts wishing to make a head start in Arduino programming. The first chapter introduces the Arduino platform, ecosystem, and existing varieties of Arduino Nano boards. It also teaches how to install various tools needed to get started with Arduino Programming. The second chapter kicks off with electronic circuit building and programming around your Arduino. The third chapter explores various buses and analog inputs. In the fourth chapter, you get acquainted with the concept of pulse width modulation (PWM) and working with unipolar stepper motors.
In the fifth chapter, you are sure to learn about creating beautiful graphics and basic but useful animation with the aid of an external display. The sixth chapter introduces the readers to the concept of I/O devices such as sensors and the piezo buzzer, exploring their methods of interfacing and programming with the Arduino Nano. The last chapter explores another member of Arduino Nano family, Arduino Nano 33 IoT with its highly interesting capabilities. This chapter employs and deepens many concepts learned from previous chapters to create interesting applications for the vast world of the Internet of Things.
The entire book follows a step-by-step approach to explain concepts and the operation of things. Each concept is invariably followed by a to-the-point circuit diagram and code examples. Next come detailed explanations of the syntax and the logic used. By closely following the concepts, you will become comfortable with circuit building, Arduino programming, the workings of the code examples, and the circuit diagrams presented. The book also has plenty of references to external resources wherever needed.
An archive file (.zip) comprising the software examples and Fritzing-style circuit diagrams discussed in the book may be downloaded free of charge below.
Learn programming for Alexa devices, extend it to smart home devices and control the Raspberry Pi
The book is split into two parts: the first part covers creating Alexa skills and the second part, designing Internet of Things and Smart Home devices using a Raspberry Pi.
The first chapters describe the process of Alexa communication, opening an Amazon account and creating a skill for free. The operation of an Alexa skill and terminology such as utterances, intents, slots, and conversations are explained. Debugging your code, saving user data between sessions, S3 data storage and Dynamo DB database are discussed.
In-skill purchasing, enabling users to buy items for your skill as well as certification and publication is outlined. Creating skills using AWS Lambda and ASK CLI is covered, along with the Visual Studio code editor and local debugging. Also covered is the process of designing skills for visual displays and interactive touch designs using Alexa Presentation Language.
The second half of the book starts by creating a Raspberry Pi IoT 'thing' to control a robot from your Alexa device. This covers security issues and methods of sending and receiving MQTT messages between an Alexa device and the Raspberry Pi.
Creating a smart home device is described including forming a security profile, linking with Amazon, and writing a Lambda function that gets triggered by an Alexa skill. Device discovery and on/off control is demonstrated.
Next, readers discover how to control a smart home Raspberry Pi display from an Alexa skill using Simple Queue Service (SQS) messaging to switch the display on and off or change the color.
A node-RED design is discussed from the basic user interface right up to configuring MQTT nodes. MQTT messages sent from a user are displayed on a Raspberry Pi.
A chapter discusses sending a proactive notification such as a weather alert from a Raspberry Pi to an Alexa device. The book concludes by explaining how to create Raspberry Pi as a stand-alone Alexa device.
Multitasking and multiprocessing have become a very important topic in microcontroller-based systems, namely in complex commercial, domestic, and industrial automation applications. As the complexity of projects grows, more functionalities are demanded from the projects. Such projects require the use of multiple inter-related tasks running on the same system and sharing the available resources, such as the CPU, memory, and input-output ports. As a result of this, the importance of multitasking operations in microcontroller-based applications has grown steadily over the last few years. Many complex automation projects now make use of some form of a multitasking kernel.
This book is project-based and its main aim is to teach the basic features of multitasking using the Python 3 programming language on Raspberry Pi. Many fully tested projects are provided in the book using the multitasking modules of Python. Each project is described fully and in detail. Complete program listings are given for each project. Readers should be able to use the projects as they are, or modify them to suit their own needs.
The following Python multitasking modules have been described and used in the projects:
Fork
Thread
Threading
Subprocess
Multiprocessing
The book includes simple multitasking projects such as independently controlling multiple LEDs, to more complex multitasking projects such as on/off temperature control, traffic lights control, 2-digit, and 4-digit 7-segment LED event counter, reaction timer, stepper motor control, keypad based projects, car park controller, and many more. The fundamental multitasking concepts such as process synchronization, process communication, and memory sharing techniques have been described in projects concerning event flags, queues, semaphores, values, and so on.
Third, extended and revised edition with AVR Playground and Elektor Uno R4
Arduino boards have become hugely successful. They are simple to use and inexpensive. This book will not only familiarize you with the world of Arduino but it will also teach you how to program microcontrollers in general. In this book theory is put into practice on an Arduino board using the Arduino programming environment.
Some hardware is developed too: a multi-purpose shield to build some of the experiments from the first 10 chapters on; the AVR Playground, a real Arduino-based microcontroller development board for comfortable application development, and the Elektor Uno R4, an Arduino Uno R3 on steroids.
The author, an Elektor Expert, provides the reader with the basic theoretical knowledge necessary to program any microcontroller: inputs and outputs (analog and digital), interrupts, communication busses (RS-232, SPI, I²C, 1-wire, SMBus, etc.), timers, and much more. The programs and sketches presented in the book show how to use various common electronic components: matrix keyboards, displays (LED, alphanumeric and graphic color LCD), motors, sensors (temperature, pressure, humidity, sound, light, and infrared), rotary encoders, piezo buzzers, pushbuttons, relays, etc. This book will be your first book about microcontrollers with a happy ending!
This book is for you if you are a beginner in microcontrollers, an Arduino user (hobbyist, tinkerer, artist, etc.) wishing to deepen your knowledge,an Electronics Graduate under Undergraduate student or a teacher looking for ideas.
Thanks to Arduino the implementation of the presented concepts is simple and fun. Some of the proposed projects are very original:
Money Game
Misophone (a musical fork)
Car GPS Scrambler
Weather Station
DCF77 Decoder
Illegal Time Transmitter
Infrared Remote Manipulator
Annoying Sound Generator
Italian Horn Alarm
Overheating Detector
PID Controller
Data Logger
SVG File Oscilloscope
6-Channel Voltmeter
All projects and code examples in this book have been tried and tested on an Arduino Uno board. They should also work with the Arduino Mega and every other compatible board that exposes the Arduino shield extension connectors.
Please note
For this book, the author has designed a versatile printed circuit board that can be stacked on an Arduino board. The assembly can be used not only to try out many of the projects presented in this book but also allows for new exercises that in turn provide the opportunity to discover new techniques. Also available is a kit of parts including the PCB and all components. With this kit you can build most of the circuits described in the book and more.
Datasheets Active Components Used (.PDF file):
ATmega328 (Arduino Uno)
ATmega2560 (Arduino Mega 2560)
BC547 (bipolar transistor, chapters 7, 8, 9)
BD139 (bipolar power transistor, chapter 10)
BS170 (N-MOS transistor, chapter 8)
DCF77 (receiver module, chapter 9)
DS18B20 (temperature sensor, chapter 10)
DS18S20 (temperature sensor, chapter 10)
HP03S (pressure sensor, chapter 8)
IRF630 (N-MOS power transistor, chapter 7)
IRF9630 (P-MOS power transistor, chapter 7)
LMC6464 (quad op-amp, chapter 7)
MLX90614 (infrared sensor, chapter 10)
SHT11 (humidity sensor, chapter 8)
TS922 (dual op-amp, chapter 9)
TSOP34836 (infrared receiver, chapter 9)
TSOP1736 (infrared receiver, chapter 9)
MPX4115 (analogue pressure sensor, chapter 11)
MCCOG21605B6W-SPTLYI (I²C LCD, chapter 12)
SST25VF016B (SPI EEPROM, chapter 13)
About the author
Clemens Valens, born in the Netherlands, lives in France since 1997. Manager at Elektor Labs and Webmaster of ElektorLabs, in love with electronics, he develops microcontroller systems for fun, and sometimes for his employer too. Polyglot—he is fluent in C, C++, PASCAL, BASIC and several assembler dialects—Clemens spends most of his time on his computer while his wife, their two children and two cats try to attract his attention (only the cats succeed). Visit the author’s website: www.polyvalens.com.Authentic testimony of Hervé M., one of the first readers of the book:'I almost cried with joy when this book made me understand things in only three sentences that seemed previously completely impenetrable.'
40+ Projects using Arduino, Raspberry Pi and ESP32
This book is about developing projects using the sensor-modules with Arduino Uno, Raspberry Pi and ESP32 microcontroller development systems. More than 40 different sensors types are used in various projects in the book. The book explains in simple terms and with tested and fully working example projects, how to use the sensors in your project. The projects provided in the book include the following:
Changing LED brightness
RGB LEDs
Creating rainbow colours
Magic wand
Silent door alarm
Dark sensor with relay
Secret key
Magic light cup
Decoding commercial IR handsets
Controlling TV channels with IT sensors
Target shooting detector
Shock time duration measurement
Ultrasonic reverse parking
Toggle lights by clapping hands
Playing melody
Measuring magnetic field strength
Joystick musical instrument
Line tracking
Displaying temperature
Temperature ON/OFF control
Mobile phone-based Wi-Fi projects
Mobile phone-based Bluetooth projects
Sending data to the Cloud
The projects have been organized with increasing levels of difficulty. Readers are encouraged to tackle the projects in the order given. A specially prepared sensor kit is available from Elektor. With the help of this hardware, it should be easy and fun to build the projects in this book.
This book details the use of the ARM Cortex-M family of processors and the Arduino Uno in practical CAN bus based projects. Inside, it gives a detailed introduction to the architecture of the Cortex-M family whilst providing examples of popular hardware and software development kits. Using these kits helps to simplify the embedded design cycle considerably and makes it easier to develop, debug, and test a CAN bus based project. The architecture of the highly popular ARM Cortex-M processor STM32F407VGT6 is described at a high level by considering its various modules. In addition, the use of the mikroC Pro for ARM and Arduino Uno CAN bus library of functions are described in detail.
This book is written for students, for practising engineers, for hobbyists, and for everyone else who may need to learn more about the CAN bus and its applications. The book assumes that the reader has some knowledge of basic electronics. Knowledge of the C programming language will be useful in later chapters of the book, and familiarity with at least one microcontroller will be an advantage, especially if the reader intends to develop microcontroller based projects using CAN bus.
The book should be useful source of reference to anyone interested in finding an answer to one or more of the following questions:
What bus systems are available for the automotive industry?
What are the principles of the CAN bus?
What types of frames (or data packets) are available in a CAN bus system?
How can errors be detected in a CAN bus system and how reliable is a CAN bus system?
What types of CAN bus controllers are there?
What are the advantages of the ARM Cortex-M microcontrollers?
How can one create a CAN bus project using an ARM microcontroller?
How can one create a CAN bus project using an Arduino microcontroller?
How can one monitor data on the CAN bus?
All you need to know about good acoustics and sound systems in performance and worship spaces!
Everyone knows that the ability to hear music in balance and to understand speech is essential in any space used for performance or worship. Unfortunately, in the early 21st century, we find that buildings with good acoustics are the exception rather than the rule. Much of the fault leading to this result can be traced to the widespread perception that acoustics is a black art. In fact, scientific acoustics as developed in the last century is a well-defined engineering practice that can lead to predictable excellent results.
A basic, non-engineering understanding of acoustics will help building owners, theater managers, ministers and teachers of music, performers, and other professionals to achieve their goals of excellent acoustics in venues with which they work. Performers having a basic understanding of acoustics will be able to make the most of the acoustics of the venue in which they perform.
This book helps those responsible for providing good acoustics in performance and worship spaces to understand the variables and choices entailed in proper acoustic design for performance and worship. Practicing acoustical consultants will find the book a useful reference as well. The level of presentation is comfortable and straightforward without being simplistic. If correct acoustical principles are incorporated into the design, renovation, and maintenance of performance and worship venues, good acoustics will be the result.
Ready to explore the world around you? By attaching the Sense HAT to your Raspberry Pi, you can quickly and easily develop a variety of creative applications, useful experiments, and exciting games.
The Sense HAT contains several helpful environmental sensors: temperature, humidity, pressure, accelerometer, magnetometer, and gyroscope. Additionally, an 8x8 LED matrix is provided with RGB LEDs, which can be used to display multi-color scrolling or fixed information, such as the sensor data. Use the small onboard joystick for games or applications that require user input. In Innovate with Sense HAT for Raspberry Pi, Dr. Dogan Ibrahim explains how to use the Sense HAT in Raspberry Pi Zero W-based projects. Using simple terms, he details how to incorporate the Sense HAT board in interesting visual and sensor-based projects. You can complete all the projects with other Raspberry Pi models without any modifications.
Exploring with Sense HAT for Raspberry Pi includes projects featuring external hardware components in addition to the Sense HAT board. You will learn to connect the Sense HAT board to the Raspberry Pi using jumper wires so that some of the GPIO ports are free to be interfaced to external components, such as to buzzers, relays, LEDs, LCDs, motors, and other sensors.
The book includes full program listings and detailed project descriptions. Complete circuit diagrams of the projects using external components are given where necessary. All the projects were developed using the latest version of the Python 3 programming language. You can easily download projects from the book’s web page. Let’s start exploring with Sense HAT.
Architecture, Programming and Applications
The MSP430 is a popular family of microcontrollers from Texas Instruments. In this book we will work with the smallest type, which is the powerful MSP430G2553. We will look at the capabilities of this microcontroller in detail, as it is well-suited for self-made projects because it is available in a P-DIP20 package.
We will take a closer look at the microcontroller and then build, step by step, some interesting applications, including a 'Hello World' blinking LED and a nice clock application, which can calculate the day of the week based on the date.
You also will learn how to create code for the MSP microcontroller in assembler. In addition to that, we will work with the MSP-Arduino IDE, which makes it quite easy to create fast applications without special in-depth knowledge of the microcontrollers.
All the code used in the book is available for download from the Elektor website.
EAGLE – the “Easily Applicable Graphical Layout Editor“ is a professional-grade CAD (computer aided design) software package for the design and drafting of electronic schematics as well as the design and fabrication of printed circuit boards (PCBs).
This publication, the ‘EAGLE Advanced User Guide’ provides the experienced EAGLE user with insight into using some of the more advanced features of EAGLE software. It is not a guide to teach the reader the basic concepts of EAGLE, nor does it discuss the ‘how to’ of the EAGLE interface and the simpler operations and commands of the software. That is the purpose of the author’s previous title EAGLE V6 Getting Started Guide also published by Elektor.
This book is intended as an enduring document covering the more advanced modules, commands, and functions which make up EAGLE. It is hoped that this book will sit on the desk or the bookshelf of the EAGLE user, and provide a quick, succinct reference to assist with more complex applications and uses of EAGLE – an ‘EAGLE User’s Companion’, if you like.
Complementing the EAGLE Advanced User Guide, the EAGLE User Language manual is included in this book in unabridged form, reproduced with permission of CadSoft GmbH.
At the time of writing, the material in this book covers version 7 of the EAGLE software suite.
Dans ce livre, Rémy Mallard initie les débutants à la programmation des microcontrôleurs PIC de Microchip. Après une introduction (pas trop longue) à des principes essentiels de programmation, il propose des chapitres qui regroupent les informations théoriques et pratiques nécessaires à la réalisation de chaque montage.
Il fait la part belle aux « petits » microcontrôleurs 8 bits parce qu'ils sont bon marché et faciles à trouver. Toutefois comme il l'écrit : « ce n'est ni vouloir s'enfermer dans sa coquille, ni faire preuve d'insociabilité, que de s'attacher à ces petites bêtes… Cette famille 8 bits, même si on la qualifie « de base », permet tout de même de disposer de comparateurs, d'oscillateur interne, de modules de conversion analogique/numérique (CAN), de modules de communication à deux fils ou série, de générateurs à rapport cyclique variable entre autres ». C'est pourquoi les réalisations proposées vont bien au-delà du simple chenillard à LED et couvrent un grand nombre de besoins. Le lecteur apprendra comment interfacer des capteurs avec un microcontrôleur, comment acquérir et stocker des données, ou encore comment établir une liaison USB ou Ethernet pour transmettre des données. Toutes ces techniques, combinées les unes avec les autres comme des briques, permettront au lecteur de créer par la suite des montages encore plus ambitieux.
Le logiciel des différents montages est codé en langage Pascal. mikroPascal, l'environnement de développement proposé par MikroElektronika et utilisé par l'auteur, dispose dans sa version gratuite de toutes les fonctions (éditeur, débogueur, simulateur, compilateur, pilotage des programmateurs) de la version payante, mais la taille du code est limitée à 2 Ko (ce qui suffisant pour la plupart des projets du livre). Le lecteur a le choix du programmateur pour transférer le code dans le microcontrôleur (matériel MikroElektronika ou Microchip).
Après la lecture de ce livre, gagné par la bonne humeur communicative de Rémy et fort de sa longue expérience (qu'il partage volontiers), le lecteur n'aura qu'une seule envie : aller plus loin (transposer le code dans d'autres langages, le porter sur d'autres plates-formes de développement, s'attaquer aux PIC32…).
+++ L'auteur +++
Rémy Mallard est un touche-à-tout. Outre ses activités en électronique et informatique, il prête sa voix pour des documentaires et livres audio, compose de la musique, pratique la vidéo et écrit des nouvelles dont plusieurs ont été publiées.
Il s'est intéressé à son premier schéma de circuit électronique à l'âge de dix ans. À son quatorzième anniversaire, il achève la fabrication de sa radio locale (microphone, casque, platine pour disques vinyle, table de mixage, compresseur de modulation, égaliseur, émetteur FM et antenne). Armé d'un BAC F2 (électronique), il entame sa carrière professionnelle chez TDF puis la poursuit comme expert technique dans le domaine de la radio.
Aujourd'hui, il continue à se former aux métiers de la comédie et de l'écriture.
Comme il le dit : '...la clé de la réussite tient pour une grande part dans l'intérêt qu'on porte aux choses. Les bagages scolaires sont bien entendu appréciés, mais la motivation (l'envie de regarder les choses par le côté et non par le devant) est un plus certain. Soyez intéressé et montrez que vous aimez apprendre, simplement. Et surtout, expérimentez ! Faites des choses de vos petits doigts, ne vous contentez pas de rester derrière votre simulateur informatique. Si un composant grille ou explose devant vos yeux, dites-vous que vous avez de la chance (sauf si bien sûr un fragment incandescent s'est fiché dans votre rétine), et essayez de comprendre ce qui s'est passé, plutôt que de laisser tout tomber. Faites de vos échecs la clé de votre réussite.'