The 1-Wire protocol is a proprietary standard for serial data communication from Maxim Integrated. This protocol is a low-speed, half-duplex, bidirectional, low-power master-slave data communication standard used by several devices, including temperature sensors, real-time clocks, EEPROMs, identification (intellectual property protection) devices, timers, and iButtons. There can be only one master device on a 1-wire standard…
How to use ESP32’s sleep and wake-up modes in MicroPython
In a previous article, we covered sleep modes in ESP8266. ESP32 is another popular Wi-Fi development board from Expressif systems. It’s more feature-rich than ESP8266, but also more power-hungry. The power consumption of ESP32 can reach up to 790 mA when the Wi-Fi and Bluetooth are both operational — nearly double that of ESP8266, which…
MicroPython – SPI Protocol in ESP8266 and ESP32
SPI and I2C are the common serial communication protocols used by sensors for communicating with microcontrollers and microcomputers. Both protocols are master-slave protocols. The sensors often take the part of a slave device within an embedded ecosystem. Most of the time, a sensor only requires sending data to the microcontroller/microcomputer. This remains true even if…
MicroPython – I2C protocol in ESP8266 and ESP32
Sensors use slave-master protocols for interfacing with microcontrollers and microcomputers. Among many different slave-master protocols, I2C and SPI protocols are the common serial communication protocols widely found in embedded devices. Both protocols let the microcontroller/microcomputer take the master role and allow interfacing of several sensors and embedded blocks on a common bus. This tutorial will…
MicroPython: Serial data communication in ESP8266 and ESP32 using UART
Microcontroller boards require communicating data with a lot of other devices that include sensors, actuators, other microcontrollers, and microcomputers. This data transfer or exchange is carried over serial interfaces using standard protocols like UART, I2C, SPI, 1-wire, etc. UART is one of the common serial data communication protocols available on almost every microcontroller. UART is…
Understanding the basics of MicroPython programming
MicroPython is a software implementation of the Python 3 programming language for microcontrollers. Nearly all major microcontroller platforms are supported by MicroPython’s firmware. MicroPython eases the development of embedded systems in a couple of ways. For one, it lets users program microcontrollers and microcomputers in a common programming language (such as Python, which is currently…
MicroPython – Generating PWM on ESP8266 and ESP32
Pulse Width Modulation (PWM) is one of the five basic functionalities in any microcontroller. The other four are digital input, digital output, analog input, and serial data communication. Most microcontrollers do not have a built-in digital-to-analog converter to output analog signals. However, most of the microcontrollers have one or more PWM output interfaces. PWM signals…
MicroPython – Digital input/output in ESP8266 and ESP32
The first step in programming embedded devices is to perform digital input/output. Digital input/output refers to reading parallel data. The same logical signals are utilized for switching and control operations. MicroPython, an embedded firmware, essentially includes libraries to control digital input/output and other hardware functions. MicroPython can be uploaded and run on a variety of…
What is MicroPython?
MicroPython implements the Python 3 programming language for microcontrollers and microcomputers. It is a firmware solution designed to implement high-level language features of Python into low-level hardware platforms. The firmware is optimized to run in constrained environments while allowing a small subset of Python 3 standard libraries into embedded programming. MicroPython firmware can run in…
RPi Python Programming 07: Python basics (part 2)
In the previous tutorial, we learned about Python’s syntax — meaning its identifiers, keywords, comments, statements, literals, and data types. We also learned that Python is object-oriented and that these objects can be mutable or immutable. Python objects that point to a group of values are iterable, which, in this case, is referred to as…
How to Make First Python Program with Beaglebone Black
Beaglebone black supports various high level languages such as a C, C++ and scripting languages like java, python. Programming of application is mostly written in C language for controller or processor. Python is an interpreted language and great library source available for BBB. At low level, programming in python is efficient and responds quicker than C language.This tutorial talks about making first python program with Beaglebone Black. So in case you are not aware of basic python programming then I suggest you to go through the same before proceeding.