Posts with the tag MicroPython:

LEGO Mindstorms EV3 Python - OpenWeather

I had a post Arduino OpenWeatherMap Client several years ago which documents an OpenWeather client on Arduino UNO. After so many years, people are still interested in reading that post. This encourages me to re-implement it on a more powerful platform - LEGO EV3 Intelligent Brick using MicroPython. This project demonstrates how to turn LEGO EV3 into an IoT device and change LED light color. Please refer to my previous post LEGO EV3 MicroPython - Random Shapes on how to install MicroPython image for LEGO EV3.

LEGO Mindstorms EV3 Python - Rock Paper Scissors Game

Do you want to play the Rock Paper Scissors game with your EV3? If yes, there you go: This project demonstrates how to react to EV3 Intelligent Brick button events, play built-in sound files, and make decisions using MicroPython. Please refer to my previous post LEGO EV3 MicroPython - Random Shapes on how to install MicroPython image for LEGO EV3. Game Design Rock paper scissors (also known by other permutations such as scissors paper rock, or ro-sham-bo) is a hand game usually played between two people, in which each player simultaneously forms one of three shapes with an outstretched hand.

LEGO Mindstorms EV3 Python - I ❤️ Vancouver

My LEGO EV3 robot loves Vancouver, here is what it says: This project shows how to draw texts and PNG images on EV3 Intelligent brick screen. Please refer to my previous post LEGO EV3 MicroPython - Random Shapes on how to install MicroPython image for LEGO EV3. The media Module LEGO EV3 MicroPython media module describes media such as fonts, images, and sounds. The Font class in media.ev3dev represents a font for writing text.

LEGO Mindstorms EV3 Python - Random Shapes

In 2019, LEGO released an official MicroPython image for Lego EV3, which can “use your EV3 Brick to unleash the power of Python programming”. EV3 MicroPython version v2.0 was released very recently to support more sensors and new features. Installation The installation follows the standard way to flash an embedded Linux system onto an micro SD card. You don’t need to worry about bricking your EV3 because it is a separate OS running from the SD card.

Connect ESP32 to Azure Iot Hub using MicroPython

This post documents necessary steps to connect an ESP32-DevKitC kit to Azure Iot Hub using MicroPython and the MQTT protocol. I am going to use the latest firmware released from MicroPython downloads. Dependencies This project requires the following MicroPython dependencies: MicroPython’s asynchronous scheduling library micropython-uasyncio. A simple MQTT client for MicroPython micropython-umqtt.simple. CPython urllib.parse module ported to MicroPython micropython-urllib.parse. CPython hmac module ported to MicroPython micropython-hmac. It is very simple to download and install dependencies through MicroPython’s upip package manager.

micropython-uasyncio

Asynchronous I/O isn’t new in Python. Since Python 3.4, asyncio is part of the standard library. From A simple introduction to Python’s asyncio and I quote here: Asyncio is all about writing asynchronous programs in Python. Asyncio is a beautiful symphony between an Event loop, Tasks and Coroutines all coming together so perfectly. I agree and I love the pluggable event loop model. Asynchronous I/O isn’t unique to Python.