M5Stack Electronic Blueprints - Don Wilcher - E-Book

M5Stack Electronic Blueprints E-Book

Don Wilcher

0,0
26,39 €

-100%
Sammeln Sie Punkte in unserem Gutscheinprogramm und kaufen Sie E-Books und Hörbücher mit bis zu 100% Rabatt.

Mehr erfahren.
Beschreibung

As an embedded systems developer or an IoT developer, you can often face challenges in maintaining focus on prototyping a product concept while using a specific high-level programming language for implementation. To overcome these challenges, the M5Stack Core platform uses an ESP32 microcontroller and block code that allows you to focus on product creation and application instead of the high-level programming language. M5Stack Electronics Blueprints presents various design and prototyping approaches as well as UI layout and electronics interfacing techniques that will help you to become skilled in developing useful products effectively.
This book takes you through a hands-on journey for a better understanding of the ESP32 microcontroller and the M5Stack Core's architecture. You’ll delve into M5Stack Core topics such as electronic units, light, sound, motion devices, interfacing circuits, SNAP circuit kits, Arduino applications, and building Bluetooth and Wi-Fi IoT devices. Further, you’ll explore various M5Stack core applications using a project-based learning method, including the fascinating 32-bit microcontroller device technology.
By the end of this book, you’ll be able to design and build interactive, portable electronic controllers, IoT, and wearable devices using the M5Stack Core.

Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:

EPUB
MOBI

Seitenzahl: 236

Veröffentlichungsjahr: 2023

Bewertungen
0,0
0
0
0
0
0
Mehr Informationen
Mehr Informationen
Legimi prüft nicht, ob Rezensionen von Nutzern stammen, die den betreffenden Titel tatsächlich gekauft oder gelesen/gehört haben. Wir entfernen aber gefälschte Rezensionen.



M5Stack Electronic Blueprints

A practical approach for building interactive electronic controllers and IoT devices

Dr. Don Wilcher

BIRMINGHAM—MUMBAI

M5Stack Electronic Blueprints

Copyright © 2023 Packt Publishing

All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.

Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author(s), nor Packt Publishing or its dealers and distributors, will be held liable for any damages caused or alleged to have been caused directly or indirectly by this book.

Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.

Group Product Manager: Rahul Nair

Publishing Product Manager: Surbhi Suman

Senior Editors: Divya Vijayan and Athikho Sapuni Rishana

Technical Editor: Shruthi Shetty

Copy Editor: Safis Editing

Project Coordinator: Ashwin Kharwa

Proofreader: Safis Editing

Indexer: Subalakshmi Govindhan

Production Designer: Ponraj Dhandapani

Marketing Coordinator: Gaurav Christian

Senior Marketing Coordinator: Nimisha Dua

First published: March 2023

Production reference: 1180123

Published by Packt Publishing Ltd.

Livery Place

35 Livery Street

Birmingham

B3 2PB, UK.

ISBN 978-1-80323-030-6

www.packtpub.com

To my children Tiana, D’Vonn, and D’Mar, for allowing me to see them grow into wonderful young adults and for supporting my work as an electrical engineer, educator, scholar, researcher, and author. To Juwon, for asking critical questions about the M5Stack Core projects demonstrated in my lab. To my granddaughter Winter, for allowing me to play and learn through her eyes as a child. To Larita and Matthew, thank you for embracing me as your son. To my natural parents, thank you for providing a strong work ethic and an educational mindset. To my wife, Dr. Mattalene Wilcher, for being my loving partner throughout our joint life journey.

– Dr. Don Wilcher

Foreword

Don Wilcher has succeeded again with this new book about using the economical M5Stack Core microcontroller. This remarkable controller is designed to interface with a variety of circuits simply by stacking them atop the compact 5 cm x 5 cm M5Stack Core package. This and its block coding capability greatly simplify the design and implementation of compact controller packages for use in robotics, automation, wireless controllers, scientific applications, and a wide variety of other projects.

If you want to get up to speed with integrating one of the latest microcontrollers with a variety of external devices and circuits, this book is for you. Don is a hands-on engineer with outstanding communication skills. Moreover, he has built, programmed, and tested the systems he describes in this book. I was especially interested in Chapter 2’s description of interfacing an M5Stack Core microcontroller with a tri-color LED, and there’s much, much more in this remarkable book.

Don Wilcher is a master electronics communicator, and I am pleased to recommend this book to hobbyists, educators, companies, and anyone interested in designing, assembling, and programming an M5Stack Core microcontroller.

Forrest M. Mims II

www.forrestmims.org

“One of the 50 best brains in science.” Discover Magazine

Contributors

About the author

Dr. Don Wilcher is an electrical engineer, educator, maker, scholar, researcher, and entrepreneur experienced in mechatronics, embedded control systems, and electrical-electronics technologies. He has worked in a variety of product, systems engineering, management, and supervisory roles in the consumer, manufacturing, and automotive industries. He has extensive experience in designing and analyzing electromechanical and electronic control systems and prototyping wearable devices. Besides his industrial experience, Dr. Don Wilcher has reviewed the curriculum and industry standards for engineering, STEM, career, and technical education programs. He has redesigned technical courses in manufacturing, robotics, and mechatronics, and developed instructional materials for such curricula. He has designed and delivered webinars on emerging technologies such as embedded IoT, physical computing, mobile robotics concepts, and electronics prototyping methods. Currently, Dr. Don Wilcher is providing consultancy around virtual reality mechatronics, plant safety, and robotics course modules with industry standards alignment, writing technical and maker space project articles for EETech Media. He is actively involved in developing and delivering emerging engineering webinars for the Design News Continuing Education Center.

I want to thank my colleagues who have been close to me and supported me, and especially my wife Mattalene, my children, my friends, and my parents.

About the reviewer

Lensey C. King Jr. has worked in the electrical industry for three decades as a residential, commercial, and industrial electrician. He has received an Associate in Applied Science degree in automotive/automated manufacturing technology from Jefferson State Community College. Lensey is a licensed master electrician/electrical contractor for the states of AL, GA, and VA. He is working as a business development manager and partner of Multi-Skill Training Services in Alabama, where he is responsible for closing the “skills gap” in the manufacturing industries by offering customized industrial maintenance training. He is also the owner of EM&T, an electrical contracting company that focuses on maintenance service work and EV charging station repair.

Table of Contents

Preface

Part 1: M5Stack Electronics Hardware Architecture

1

Exploring the M5Stack Core

Technical requirements

Welcome to the M5Stack Core

Powering and resetting the M5Stack Core

Overview of the M5Stack Core hardware architecture

EA3036 DC-DC converter (power management)

Power amplifier

ESP32 subsystem

USB-UART and accessories

UI design basics

Input controls

Design considerations

UiFlow overview

Communicating with the M5Stack Core

Requirements

Communication setup

Summary

2

Hands-On with M5Stack Units

Technical requirements

Introducing M5Stack units

Interacting with an RGB LED unit

Programming the M5Stack Core to operate the RGB LED unit

An interactive RGB LED unit

Interacting with an IR remote unit

Programming the M5Stack Core to operate the IR remote unit

Basic IR handheld remote tester

Interacting with an angle sensor unit

The angle sensor unit circuit analysis

Programming the M5Stack Core to read the angle sensor unit

Interacting with a motion sensor unit

Programming the M5Stack Core to detect a human body with the motion sensor unit

Summary

3

Lights, Sound, and Motionwith M5Stack

Technical requirements

Introducing M5Stack Core hardware

Using the M5Stack Core vibration motor unit

Attaching the M5Stack Core to the vibration motor unit

Programming the M5Stack Core to operate the vibration motor unit

Building a mountable vibration motor unit

Programming the M5Stack Core to operate the mountable vibration motor unit

Using the M5Stack Core speaker

Programming the M5Stack Core to produce a sound

Adding a speaker icon to the TFT LCD

Coding an M5Stack Core RGB LED flasher

Programming the M5Stack Core to operate the RGB LED as a flashlight

Programming the M5Stack Core to operate the RGB LED as an LED flasher

Coding an M5Stack Core interactive emoji

Summary

Interactive quiz answers

Part 2: M5Stack Electronic Interfacing Circuit Projects

4

It’s a SNAP! Snap Circuits and the M5Stack Core

Technical requirements

What are Snap Circuits?

What is a Snap LED MC module?

Building an M5Stack Core Snap Circuits numbers and letters device

Game selection procedure

The M5Stack Core controller’s software

Building an M5Stack Core Snap Circuits alarm device

Building an M5Stack Core Snap Circuits counter with a sound device

Summary

Interactive quiz answers

5

Solderless Breadboarding with the M5Stack

Technical requirements

An introduction to electronic interfacing circuits

Building a discrete transistor LED electronic flasher

Building a discrete transistor DC motor driver circuit

Building a littleBits temperature sensor M5Stack Core simulator monitor

An M5Stack controller littleBits LED flasher

Summary

Interactive quiz answers

Quiz answers

6

M5Stack and Arduino

Technical requirements

M5Stack Core2 touchscreen UI controls introduction

Building a touch control inverting switch

Building a touch control counter

Building a touch control relay controller

Building a touch control LED dimmer controller

Summary

Interactive quiz answers

Quiz answers

Part 3: M5Stack IoT Projects

7

Working with M5Stack and Bluetooth

Technical requirements

The ESP32 microcontroller Bluetooth chipset

UiFlow BLE coding blocks pallet overview

Detecting an M5Stack Core Bluetooth signal with the Nordic Semiconductor nRF toolbox

Building an M5Stack Bluetooth messenger device

Building an M5Stack Bluetooth receiver controller

Creating a Bluetooth RGB LED light with sound

Summary

Interactive quiz answers

Quiz answers

8

Working with the M5Stack and Wi-Fi

Technical requirements

An introduction to Wi-Fi with the ESP32

Wi-Fi setup for the M5Stack Core controller

Detecting Wi-Fi networks with an M5Stack scanner – part 1

Detecting Wi-Fi networks with an M5Stack scanner with an LED indicator – part 2

Creating an access point and web server with an M5Stack Core controller

Summary

Interactive quiz answers

Quiz answers

Index

Other Books You May Enjoy

Preface

Suppose you are interested in learning new approaches to developing portable electronic controllers to operate electromechanical loads such as a DC motor or introducing new prototyping techniques for interactive product development using littleBits or SNAP circuits as augmentation tools. In that case, the M5Stack Electronic Blueprints book is for you. This book provides coverage of the design, development, and prototyping workflow process of building interactive electronic controllers and IoT device applications. You will learn how to create a physical M5Stack Core controller device based on the ESP32 microcontroller using discrete electronic components, Arduino C/C++, and UIFlow Blockly code (no-code) programming languages.

The ESP32 subsystem is the heart of the M5Stack Core controller. Here, internal circuits, such as a 3W audio amplifier, LED bars, USB-C ports, push button switches, a thin film transistor (TFT) touch screen, and general-purpose input-output (GPIO) ports, are managed by the ESP32 subsystem. You will learn about the structure of the ESP32 subsystem architecture in this book. The ESP32 microcontroller has an internal Bluetooth chipset and Wi-Fi support circuitry. You will learn how to create IoT controllers and scanners using the M5Stack internal Wi-Fi and Bluetooth chipsets. Finally, human computing interaction (HCI)-based techniques for creating effective and aesthetically appealing user interfaces for product engagement will be presented in this book.

Who this book is for

The M5Stack Electronic Blueprints book topics will assist you in exploring electronic controllers, Bluetooth, Wi-Fi-based IoT device development, and Arduino interfacing techniques using an ESP32 microcontroller-based platform. The M5Stack Core allows ease in developing new concepts for prototyping automation controls, wearables, interactive electronic controllers, and investigating wireless product technologies.

Therefore, the audience for this book includes the following:

STEM, engineering, and technical educatorsPracticing engineersElectronics, automation, production, and industrial maintenance techniciansMakersSTEM and career and technical learnersElectronic circuit hobbyistsInventors and academic researchers

What this book covers

Chapter 1, Exploring the M5Stack Core, explains the inner workings of the M5Stack Core, ESP32 microcontroller subsystem architecture, and internal supporting hardware electronics.

Chapter 2, Exploring M5Stack Units, explores M5Stack units for control and detection. The units are small electronic circuits such as the IR remote, environment sensor, RGB LED, motion sensor, and angle sensor. The M5Stack units are vital components for developing wearable electronics. You will use the M5Stack UIFlow Blockly code and the Arduino IDE C/C++ code to investigate the function of the extendable electronic devices.

Chapter 3, Lights, Sound, and Motion with the M5Stack, explores small wearable devices, including an electronic flashlight, an emergency flasher, a tone generator, an interactive emoji, and a haptic controller. The M5Stack has several electronic devices such as a microphone, an Inertial Measurement Unit (IMU), RGB LED bars, a vibration motor, and a speaker.

Chapter 4, It’s a SNAP! Snap Circuits and the M5Stack Core, covers SNAP circuits, which are electronic parts mounted on colored plastic shapes. Each shape has snap elements that allow the construction of electronic circuits. You will learn how to enhance the SNAP circuits user experience with an M5Stack Core controller by providing interfacing controls to operate the snap-based electronic devices.

Chapter 5, Solderless Breadboarding with M5Stack, provides wiring instructions for using a solderless breadboard and discrete electronic components. Touchscreen controllers and electronic sensors will be created using the M5Stack Core controller and the UIFlow Blockly code programming language. You will build hardware devices such as an electronic flasher, littleBits LED flasher, and DC motor controller in this chapter.

Chapter 6, M5Stack and Arduino, explains how to use electronic interface circuit techniques for wiring the M5Stack Core 2 controller to an Arduino Uno. You will investigate using electronic interfacing circuits and portable touchscreen controls for operating and monitoring Arduino Uno electronic devices, such as a touch-control inverting switch, a touch-control digital counter, and a touchscreen LED dimmer controller.

Chapter 7, Working with the M5Stack and Bluetooth, looks at the embedded Bluetooth chipset that is part of the ESP32 microcontroller. You will build a wireless controller using the embedded Bluetooth chipset. You will explore a wireless transmitter and receiver to operate RGB LEDs, small DC motors, and sound/tone generators using the M5Stack Core Bluetooth chipset. You will learn how to work wireless devices using a smartphone or tablet and a mobile Bluetooth UART utility services app.

Chapter 8, Working with M5Stack and Wi-Fi, explains the Wi-Fi support circuitry integrated within the ESP32 microcontroller’s system architecture. You will conduct Wi-Fi experiments to scan and detect wireless network nodes in this chapter. You will explore visual detection indicators and audible alarms. This chapter will introduce you to the use of the Arduino IDE and an API to program Wi-Fi-enabled detection devices.

To get the most out of this book

The basic skill set the reader is assumed to have includes the following knowledge characteristics:

A desire to learn about the ESP32 microcontrollerThe ability to identify basic electrical and electronic component symbols such as resistors, capacitors, tactile push button switches, wires, LEDs, and transistors on circuit schematic diagramsBasic knowledge of the Arduino electronics prototyping platformBasic knowledge of the Arduino Integrated Development Environment (IDE)The ability to modify Application Programming Interface (API) codeThe ability to read electronic circuit schematic diagramsThe ability to wire electronic circuits using a solderless breadboard

To gain new skills in interfacing circuits, wearables, and embedded controller development, you should have a background in reading electronic circuit schematic diagrams. You should also be comfortable with using solderless breadboards. Finally, you should be able to identify electronic components such as transistors, resistors, and electrical male and female pin header connectors.

Software/hardware covered in the book

Operating system requirements

UIFlow Blockly code

Windows, macOS, or Linux

Arduino IDE

ECMAScript 11

After installing the UIFlow Blockly code software, a reset of the development system is required to complete the installation process. Having knowledge and experience of using a digital multimeter will aid you in troubleshooting interfacing circuits and wiring concerns with the projects presented in this book.

If you are using the digital version of this book, we advise you to type the code yourself or access the code from the book’s GitHub repository (a link is available in the next section). Doing so will help you avoid any potential errors related to the copying and pasting of code.

Download the example code files

You can download the example code files for this book from GitHub at https://github.com/PacktPublishing/M5Stack-Electronic-Blueprints. If there’s an update to the code, it will be updated in the GitHub repository.

We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing/. Check them out!

Download the color images

We also provide a PDF file that has color images of the screenshots and diagrams used in this book. You can download it here: https://packt.link/873X7.

Conventions used

There are a number of text conventions used throughout this book.

Code in text: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: “The name of the app is M5GO.py.”

Bold: Indicates a new term, an important word, or words that you see onscreen. For instance, words in menus or dialog boxes appear in bold. Here is an example: “Select System info from the Administration panel.”

Tips or important notes

Appear like this.

Get in touch

Feedback from our readers is always welcome.

General feedback: If you have questions about any aspect of this book, email us at [email protected] and mention the book title in the subject of your message.

Errata: Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you have found a mistake in this book, we would be grateful if you would report this to us. Please visit www.packtpub.com/support/errata and fill in the form.

Piracy: If you come across any illegal copies of our works in any form on the internet, we would be grateful if you would provide us with the location address or website name. Please contact us at [email protected] with a link to the material.

If you are interested in becoming an author: If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, please visit authors.packtpub.com.

Share Your Thoughts

Once you’ve read M5Stack Electronic Blueprints, we’d love to hear your thoughts! Please click here to go straight to the Amazon review page for this book and share your feedback.

Your review is important to us and the tech community and will help us make sure we’re delivering excellent quality content.

Download a free PDF copy of this book

Thanks for purchasing this book!

Do you like to read on the go but are unable to carry your print books everywhere?

Is your eBook purchase not compatible with the device of your choice?

Don’t worry, now with every Packt book you get a DRM-free PDF version of that book at no cost.

Read anywhere, any place, on any device. Search, copy, and paste code from your favorite technical books directly into your application.

The perks don’t stop there, you can get exclusive access to discounts, newsletters, and great free content in your inbox daily

Follow these simple steps to get the benefits:

Scan the QR code or visit the link below

https://packt.link/free-ebook/9781803230306

Submit your proof of purchaseThat’s it! We’ll send your free PDF and other benefits to your email directly

Part 1: M5Stack Electronics Hardware Architecture

The learning objective for Part 1 is to acclimate you to the M5Stack controllers’ internal electronics hardware. To accomplish this goal, you will perform basic coding tasks using the UIFlow software. The tasks include setting up USB communications between the host development system and the M5Stack Core controller, UI basics, operating the internal RGB LED bars and speaker-tone generator, and exploring the electronic circuit unit modules.

This part has the following chapters:

Chapter 1, Exploring the M5Stack CoreChapter 2, Hands-On with M5Stack UnitsChapter 3, Lights, Sound, and Motion with the M5Stack

1

Exploring the M5Stack Core

You are the proud owner of a small and powerful microcontroller development platform called the M5Stack Core. The M5Stack Core uses the Espressif ESP32 microcontroller to allow you to create a variety of programmable electronic gadgets and devices. You can build programmable gadgets such as touchscreen controllers, Wi-Fi-operated devices, wearables, robots, and portable electronic games using the M5Stack Core. In addition, with the M5Stack Core, you can add visually appealing graphics and sound to your electronic creations easily and effectively using the Arduino Integrated Development Environment and the UiFlowBlockly code programming environment.

By the end of this chapter, you will understand the ESP32 microcontroller and the internal supporting electronics hardware. You will understand the M5GO Core hardware architecture’s inner workings. Finally, you will know about applying the internal support electronics hardware to create an interactive electronic widget device.

In this chapter, we’re going to cover the following main topics:

Welcome to the M5Stack CoreOverview of the M5Stack Core hardware architectureUI design basicsUiFlow overviewCommunicating with the M5Stack Core

Technical requirements

To engage with the chapter’s learning content, you will need the M5GO IoT Starter Kit to explore the internal/external hardware electronics and software coding of your first basic application. The UiFlow code block software will be required to build and run the M5Stack Core application.

You will require the following:

M5BurnerThe M5Stack CoreThe M5GO IoT Starter kitUiFlow Blockly code programming software

Here is the GitHub repository for supporting software resources: https://github.com/PacktPublishing/M5Stack-Electronic-Blueprints/tree/main/Chapter01.

Welcome to the M5Stack Core

In this section, you will learn the basic functions and features of the M5Stack Core. You will be able to perform the following tasks upon completing the lessons in this section:

Power and reset the M5Stack CorePrepare the unit for programmingIdentify the three programmable user-interface buttonsIdentify the external ports for connecting electronic unitsIdentify the USB portIdentify the LED barsSelect your stored applicationsChange the initial setup operation of the M5Stack Core

Upon completing this section, you will have a solid foundation of the external features and internal functions of the M55tack Core. Being able to complete these tasks will be important for programming and testing software applications that you create with your M5Stack Core. We will start the discussion with an overview of the M5Stack Core external features.

Powering and resetting the M5Stack Core

Turning on the M5Stack Core is quite easy to do. The M5Stack Core has a small red power button, as seen in Figure 1.1. The small red power button is located on the left side of the M5Stack Core. You turn on the M5Stack Core with a single press of the power button. You reset the M5Stack Core with a quick double press of the power button:

Figure 1.1 – The M5Stack Core power button location

Once the M5Stack Core is powered on, a UiFlow splash screen is displayed on the liquid crystal display (LCD), as seen in the following screenshot:

Figure 1.2 – UiFlow splash screen displayed after powering on the M5Stack Core

Initially, the M5Stack Core is programmed with 11 demonstration activities. The 11 demonstration activities are shown in thefollowing diagram:

Figure 1.3 – UiFlow M5Stack Core demonstration activities

Next, let us learn about each demonstration activity through an accompanying explanation. We will explore the internal features of the M5Stack Core through a series of hands-on demonstrator activities:

Demo 1 on/off: To turn off the M5Stack Core, a quick double press of the power button will accomplish this task, as seen here:

Figure 1.4 – The on/off operation of the M5Stack Core

Demo 2 speaker: Press the center button on the M5Stack Core to hear a sound from the internal speaker:

Figure 1.5 – Speaker demonstrator

Demo 3 microphone: Speak into the pinhole microphone located on the side of the M5Stack Core. While speaking into the microphone, observe the line and sound wave images. Let’s see how this looks in the following figure:

Figure 1.6 – Microphone demonstrator

Demo 4 gyro: Tilt the M5Stack Core and observe the ball movement on the LCD screen. The movement is accomplished using a gyroscope and an accelerometer, as can be seen in Figure 1.7:

Figure 1.7 – Gyro demonstrator

Demo 5 RGB LEDs: This demonstrator will glow and dim the sidebar RGB LEDs of the M5Stack Core. There is one LED bar on each side of the M5Stack Core:

Figure 1.8 – RGB bar demonstrator

Demo 6 ports explanation: The different electrical ports and their specific functions will be explored in this demonstration:

Figure 1.9 – Extension port demonstrator

Congratulations, you have completed exploring the internal features of the M5Stack Core. We will now learn about four sensor units from the M5GO IoT Starter Kit, which are shown in the following photo:

Figure 1.10 – The M5GO IoT Starter Kit

Demo 7 environment sensor: The temperature and humidity levels are displayed on the LCD upon connecting the sensor to extension port A of the M5Stack Core:

Figure 1.11 – Environment sensor demonstrator

Demo 8 passive infrared (PIR) sensor: Attach the PIR sensor to extension port B of the M5Stack Core. You can observe a color change in the circle when placing your hand in front of the sensor. The color change response of the circle also occurs when you move your hand away from the PIR sensor. The following diagram illustrates the motion sensor’s response to a hand moved away from the PIR sensor:

Figure 1.12 – PIR sensor demonstrator

Demo 9 RGB unit: You explored the RGB LED bars in the fifth demonstrator activity. You will investigate the RGB LEDs packaged in this extension unit. This RGB LED unit will only light up when properly attached to extension port B. This diagram shows the wiring connector being attached to the RGB LED to connect to extension port B:

Figure 1.13 – RGB unit demonstrator

Demo 10 infrared (IR) Remote unit: You can attach the IR Remote unit to extension port B using a wiring connector, as shown in Figure 1.14. Next, you take an ordinary IR handheld remote and point it toward the IR Remote unit. You can press any button on the IR handheld remote and observe the detection effect on the M5Stack Core LCD:

Figure 1.14 – IR Remote demonstrator

Demo 11 angle sensor: You can test the knob on the angle sensor as shown in Figure 1.15, and observe the RGB LED bars getting brighter or dimmer:

Figure 1.15 – Angle sensor demonstrator

Congratulations, you have learned about the M5Stack Core demonstrators. You have learned how to operate external sensors that are packaged with the M5GO IoT Starter Kit.

Note

To reinstall the firmware with the Demo app, use the M5Burner software. Select version 1.7.5 of the UIFLOW Core firmware. The name of the app is M5GO.py.

You have also learned how internal devices such as the RGB bar, microphone, and gyro operate using the appropriate M5Stack Core demonstrators. These mini hands-on demonstration activities allowed a glimpse into the M5Stack Core’s hardware architecture.

In the next section, we will dive deeper into the M5Stack Core’s hardware architecture by reviewing the electronic circuit schematic diagrams and the technical specifications of the ESP32-based programmable controller.

Overview of the M5Stack Core hardware architecture

In the previous section, you learned about the basic internal and external electronic features of the M5Stack Core. You investigated these basic features by using the M5Stack Demo app and specific IoT Starter Kit sensor units. In this section, you will learn about the embedded electronic subcircuits used to operate the M5Stack Core. The M5Stack Core’s hardware architecture consists of the following four electronic subcircuits:

Power managementAudio amplifierESP32 subsystemUSB-UART and accessories

The M5Stack Core hardware architecture system block diagram is illustrated in Figure 1.16:

Figure 1.16 – M5Stack Core hardware architecture system block diagram

EA3036 DC-DC converter (power management)

The EA3036 direct current to direct current (DC-DC) converter is a power management integrated circuit (IC). The EA3036 IC can be powered by one lithium-ion (Li-Ion) battery. The input voltage range for the EA3036 is 2.7 V (volt) DC to 5.5 V DC. The IC can also be powered by a basic 5 V DC adapter or phone charger. The EA3036 integrates three synchronous buck converters into one convenient 20-pin quad flat no-lead (QFN) IC package. Let us learn more about the EA3036 DC-DC converter by reviewing the IC’s physical pin packaging, shown in Figure 1.17, and the internal electronic circuits:

Figure 1.17 – EA3036 IC QFN package

The EA3036 DC-DC converter provides the 3.3 V (3V3) voltage source to operate the ESP32 microcontroller and support electronic circuit peripherals. Electronic circuit peripherals include the audio amplifier (N54148), A, B, C, and reset pushbutton switches, the LCD, the universal asynchronous receiver transmitter (CP2104) IC, and the USB-Micro (IP5306) circuit. The M5Stack Core Li-ion battery can power these subcircuits efficiently and effectively. The electronic circuit schematic and functional block diagrams for the EA3036 DC-DC converter are provided in the following diagram:

Figure 1.18 – The EA3036 DC-DC converter electronic circuit schematic and functional block diagrams

The EA3036 DC-DC converter can be used to source the appropriate voltage and current for the M5Stack Core’s N54148power amplifier.

Power amplifier

As illustrated in Demo 2, the M5Stack Core has an audio power amplifier. The NS4148 is a 3-watt (W