Skip to content

Instantly share code, notes, and snippets.

Les couacs du vote électronique, un tremplin bienvenu pour vous parler de résilience

Au lendemain des élections communales, j'observe la vague verte s'écouler dans les quotidiens, et m'amuse de la voir partager l'actualité avec d'autres titres évoquant les (très attendus, j'y viens!) couacs du vote électronique.

A Bruxelles, quarante-sept bureaux de votes ont ouvert avec deux heures de retard ou plus, cinq n'ont semble-t-il jamais ouvert. A Wavre, au delà des files interminables constatées, c'est le décompte qui a été fortement perturbé par une panne d'électricité.

Je suis un professionnel du secteur informatique, en charge du développement et du monitoring de systèmes informatiques souvent complexes, docteur de l'UCL dans l'équipe d'ingénierie informatique et... ces problèmes ne m'étonnent aucunement. J'irai même plus loin: personne ne les règlera jamais, c'est comme cela. Cela vous étonne? Moi pas.

Comme je suis me récemment intéressé à la notion de résilience dans le cadre d'initiatives de transition

@dglaude
dglaude / README.MD
Created October 20, 2025 00:26
AI generated BLE to USB-HID for Belgian French keyboard

I needed a way to type my computer from my phone, acting as a keyboard. But I cannot add software to my computer, so I needed to be a USB-HID device. I asked Gemini for help, and he produced this code, first for US EN keyboard, but then I addapted it for Belgian French.

For the Belgian French keyboard, I went to Neradoc repo, but Î could only find French keyboard: https://github.com/Neradoc/Circuitpython_Keyboard_Layouts

So Î went to his page: https://www.neradoc.me/layouts/ Gave it the Belgian French keyboar page: https://kbdlayout.info/kbdbe And it generated for me the needed Python file

@dglaude
dglaude / code.py
Created June 2, 2025 19:00
My network.py as it is before the "in the weed".
# How I use network.py
# ...
import network
socket_pool, ssl_context = network.init_network()
# ...
@dglaude
dglaude / boot.py
Last active March 13, 2025 00:40
MacroPad (CircuitPython) that implement Zaparoo protocol to select game on the MisterFPGA
import storage, usb_cdc
import board, digitalio
import usb_hid, usb_midi
# On the Macropad, pressing a key grounds it. You need to set a pull-up.
# If not pressed, the key will be at +V (due to the pull-up).
button = digitalio.DigitalInOut(board.KEY12)
button.pull = digitalio.Pull.UP
if button.value: # Disable devices only if button is not pressed.
@dglaude
dglaude / evcc.yaml
Created July 8, 2024 23:32
New working config of EVCC for Tesla with BLE HTTP Proxy (v1.2) and Teslamate, both on a Pi4
# Setup and IP addressing:
# 1) EVCC run on an NUC at 192.168.1.157 :7070
# 2) HomeWizard P1 meter reader at 192.168.1.98 :80
# 3) Shelly Pro EM - 50 as PV meter at 192.168.1.191 :80
# 4) TeslaWallConnector as Wall Charger at 192.168.1.42 :80
# 5) wimaha/TeslaBleHttpProxy as BLE proxy to control the Tesla at 192.168.1.157 :8080
# 6) teslamate-org/teslamate with mqtt broker at 192.168.1.35 :1883
network:
schema: http
@dglaude
dglaude / evcc.yaml
Created July 7, 2024 08:08
Working config of EVCC for Tesla with BLE HTTP Proxy and Teslamate
# Setup and IP addressing:
# 1) EVCC run on an NUC at 192.168.1.157 :7070
# 2) HomeWizard P1 meter reader at 192.168.1.98 :80
# 3) Shelly Pro EM - 50 as PV meter at 192.168.1.191 :80
# 4) TeslaWallConnector as Wall Charger at 192.168.1.42 :80
# 5) wimaha/TeslaBleHttpProxy as BLE proxy to control the Tesla at 192.168.1.157 :8080
# 6) teslamate-org/teslamate with mqtt broker at 192.168.1.35 :1883
network:
schema: http
@dglaude
dglaude / All keycode sorted (by column 2)
Last active March 16, 2024 19:51
Keyboard mapping CardPuter Card Computer
K.APPLICATION
K.Z
K.C
K.B
K.M
K.DOWN_ARROW
K.SPACEBAR
K.CAPS_LOCK
K.S
K.F
@dglaude
dglaude / code.py
Last active December 22, 2023 06:05
Playing an wav audio file on button press with "Feather RP2040 Prop-Maker" (update Debounce)
import supervisor
supervisor.set_next_code_file(None, reload_on_error=True)
import board
import audiocore
import audiobusio
import audiomixer
from digitalio import DigitalInOut, Direction, Pull
from adafruit_debouncer import Debouncer
@dglaude
dglaude / Ruxpin_wakeup.py
Created October 31, 2023 21:55
Halloween Teddy Ruxpin: Monitor time of fly distance and power off USB-A port for 5 minutes when there is activity.
# SPDX-FileCopyrightText: 2022 David Glaude (based on 2021 ladyada for Adafruit Industries)
# SPDX-License-Identifier: MIT
# SPDX-FileCopyrightText: 2017 Scott Shawcroft, written for Adafruit Industries
# SPDX-FileCopyrightText: Copyright (c) 2021 Carter Nelson for Adafruit Industries
#
# SPDX-License-Identifier: Unlicense
# Simple demo of the VL53L1X distance sensor.
# Will print the sensed range/distance every second.