A minimal HTTP server in python. It sends a JSON Hello World for GET requests, and echoes back JSON for POST requests.
python server.py 8009
Starting httpd on port 8009...
curl http://localhost:8009
{"received": "ok", "hello": "world"}
| # This script waits for the USB Wi-Fi adapter's installer drive to appear | |
| # (the fake driver CD that the device exposes when plugged in). Once detected, | |
| # it automatically ejects the drive so the device re-enumerates as a Wi-Fi adapter. | |
| # Intended to run at startup to make the adapter usable without manual intervention. | |
| param( | |
| [string]$VolumeLabel = "MERCUSYS", | |
| [int]$TimeoutSeconds = 60 | |
| ) | |
| Write-Host "Waiting for USB installer drive with label '$VolumeLabel'..." |
| #include <Wire.h> | |
| #include <PCF8574.h> | |
| #include <BLEDevice.h> | |
| #include <BLEUtils.h> | |
| #include <BLEScan.h> | |
| #include <math.h> | |
| // -------------------- State (placed early to avoid Arduino auto-prototype issues) -------------------- | |
| enum class State { Idle, Excited, Anxious, Friendly }; | |
| State chooseState(uint32_t nowMs); |
| /* | |
| Kaossilator Pro MIDI Arpeggiator | |
| ================================= | |
| An expressive, clock-synced, monophonic arpeggiator controlled entirely by the Kaossilator Pro | |
| via MIDI CC, Note, and Program Change messages. | |
| Compatible with Arduino Nano / Uno + MIDI IN (optocoupler or MIDI shield) | |
| === What is an Arpeggiator? === | |
| An arpeggiator takes chord notes and plays them one after another in a rhythmic pattern, |
| from machine import I2S, Pin, I2C | |
| import ulab | |
| from ulab import numpy as np | |
| import array | |
| import math | |
| import time | |
| import gc | |
| ################### | |
| # PIN CONFIGURATION |
| import numpy as np | |
| # Define RNA sequence | |
| seq = "AUGGCAUCGGC" | |
| N = len(seq) | |
A minimal HTTP server in python. It sends a JSON Hello World for GET requests, and echoes back JSON for POST requests.
python server.py 8009
Starting httpd on port 8009...
curl http://localhost:8009
{"received": "ok", "hello": "world"}
| table > *{ | |
| background-color: tan; | |
| } |
| function addHeaders(table, keys) { | |
| var row = table.insertRow(); | |
| for (var i = 0; i < keys.length; i++) { | |
| var cell = row.insertCell(); | |
| cell.appendChild(document.createTextNode(keys[i])); | |
| } | |
| } | |
| class TableFromJson extends HTMLElement { | |
| items = []; |
| [ | |
| { | |
| "Drink": "Cappuccino", | |
| "Preparation": "Espresso", | |
| "Temperature": "Hot", | |
| "Ingredients": "Equal amount of espresso and steamed milk", | |
| "Details": "Pour the espresso through the milk and serve." | |
| }, | |
| { | |
| "Drink": "Latte", |