Posts

Showing posts from July, 2023

MicroPython/CircuitPython, enter bootloader programmatically, without BOOT button.

Image
MicroPython/CircuitPython, enter bootloader programmatically, without BOOT button. (Tested on Raspberry Pi Pico) In case the Raspberry Pi Pico is flashed MicroPython : import machine machine.bootloader() In case of CircuitPython : import microcontroller microcontroller.on_next_reset(microcontroller.RunMode.BOOTLOADER) microcontroller.reset()

2.13" 250x122 e-paper (ssd1680) displayed on Raspberry Pi pico/CircuitPython

Image
Exercise to display on  2.13" 250x122 e-paper (with ssd1680 driver) , using  Raspberry Pi Pico running CircuitPython 8.2.0. - reference: CircuitPython SSD1680 Library: https://docs.circuitpython.org/projects/ssd1680/en/latest/index.html Quickstart using Adafruit eInk/ePaper displays with CircuitPython: https://learn.adafruit.com/quickstart-using-adafruit-eink-epaper-displays-with-circuitpython Connection between Raspberry Pi Pico and 2.13" 250x122 e-paper (ssd1680) e-paper Pico GPIO ------------------ 1 BUSY GP0 2 RES GP5 3 D/C GP1 4 CS GP4 5 SCL GP2 6 SDA GP3 7 GND GND 8 VCC 3V3 4x2 header on 2.13" 250x122 e-paper (ssd1680) +-----------+      GP5 |RES BUSY| GP0      GP4 |CS D/C | GP1      GP3 |SDA SCL | GP2      3V3   |VCC GND | GND +-----------+ Libraries needed: adafruit_ssd1680.mpy adafruit_display_t...

Prepare MicroPython Bluetooth service example on Raspberry Pi Pico W

Image
With recent release of MicroPython firmware for Raspberry Pi Pico W , bluetooth is now supported. This video show steps to prepare Bluetooth service example on Raspberry Pi Pico W, with MicroPython v1.20.0 on 2023-06-27. Refer to updated Connecting to the Internet with Raspberry Pi Pico W book (2023-06-14) , chapters of Bluetooth added. Read Chapter 6. Working with Bluetooth in MicroPython Copy the code in 6.1. Advertsing a Bluetooth service (create a custom service in MicroPython and advertise it), save in Raspberry Pico Pi W, name "ble_advertising.py". Copy the code in 6.2. An example Bluetooth service. This example demonstrates a simple temperature sensor peripheral. The sensor’s local value is updated every ten seconds, and any connected central device will be notified of the change. In this example, read Temperature from machine.ADC(4), It's ADC connected to internal temperature sensor. Then test with nRF Connect App. Updated@2023-10-10: ~  MicroPyt...