View BLE_with_color_indicator.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
This example acts as a BLE HID keyboard to peer devices. | |
It get's keycode from UART RX. | |
Color indication: | |
* BLUE_LED is blinking when not connected and steady blue when connected | |
* NEOPIXEL alternate between RED / GREEN / BLUE every time a keycode is transmitted (up and down event) | |
""" | |
import time |
View code.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
adapted from http://helloraspberrypi.blogspot.com/2021/01/raspberry-pi-picocircuitpython-st7789.html | |
""" | |
# Adapted for 240x240 MiniPiTFT from @Pimoroni | |
# Based on https://gist.github.com/wildestpixel/86ac1063bc456213f92972fcd7c7c2e1 | |
# Found thanks to https://www.recantha.co.uk/blog/?p=20820& | |
import os | |
import board |
View 1st_readme.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Please find below the various piece of code that together control my RGB light to loop in Rainbow. | |
Every two seconds, it change from one colour to another based on the value of the second. | |
So it compute 30 differents RGB value in a "circle", all with the same Saturation and Brightness both forced to 1.0 | |
The transition from one colour to another is done in one seconds. | |
The name of my Tradfri RGB light bulb is "light.couleur" | |
A link to my video on Twitter: | |
https://twitter.com/DavidGlaude/status/1059596285991366657 |
View adafruit_st25dv16.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# SPDX-FileCopyrightText: Copyright (c) 2021 Tim Cocks for Adafruit Industries | |
# | |
# SPDX-License-Identifier: MIT | |
""" | |
`adafruit_st25dv16` | |
================================================================================ | |
CircuitPython driver for the I2C EEPROM of the Adafruit ST25DV16 Breakout |
View code.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
import board | |
import digitalio | |
import storage | |
import usb_hid | |
from adafruit_hid.mouse import Mouse | |
import usb_cdc | |
#usb_hid.enable(devices=(usb_hid.MOUSE,)) ###AttributeError: 'module' object has no attribute 'MOUSE' |
View code.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from adafruit_magtag.magtag import MagTag | |
from adafruit_progressbar.progressbar import ProgressBar | |
# BELGIUM | |
POPULATION = 11589616 | |
DATA_SOURCE = "https://raw.githubusercontent.com/owid/covid-19-data/master/public/data/vaccinations/country_data/Belgium.csv" | |
magtag = MagTag(url=DATA_SOURCE) | |
magtag.network.connect() |
View super_multi.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Turn on all the LEDs from each Buzz! controler one after the other. | |
Work with both kind of wired Buzz! controler. | |
Require to install hid library, not an easy task. | |
""" | |
import hid | |
import time |
View simple_test.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from keypad import Keys | |
import board | |
import time | |
pins = [board.BUTTON_A, board.BUTTON_B] | |
keys = Keys(pins, value_when_pressed=False, pull=True) | |
while True: | |
if keys.events.overflowed: | |
keys.events.clear() |
View code.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# mlx90640_pygamer learn guide: | |
# * https://learn.adafruit.com/adafruit-mlx90640-ir-thermal-camera/circuitpython-thermal-camera# | |
# | |
# SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries | |
# SPDX-License-Identifier: MIT | |
# | |
# Adapted by David Glaude for 240x240 screen. | |
# | |
# 1) RedRobotics Pico to Zero Adaptor v0.2: | |
# * https://www.tindie.com/products/redrobotics/pico-2-pi-adapter-board/ |
View emojiclock
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CircuitPython Discord rotating clock emoji (spam). | |
# Type an emoji in Discord... do nothing else, with your ItsiBitsy nrF. | |
# Press the button to replace that emoji by another one every second. | |
import time | |
import board | |
import usb_hid | |
from digitalio import DigitalInOut, Direction | |
from adafruit_hid.keyboard import Keyboard |
NewerOlder