Upstream issue: mchehab/rasdaemon#17
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
esphome: | |
name: esp_tdisplay | |
platform: ESP32 | |
board: featheresp32 | |
wifi: | |
ssid: "some ssid" | |
password: "wifipassword" | |
# Enable fallback hotspot (captive portal) in case wifi connection fails |
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
#!/usr/bin/env python3 | |
"""Do you _need_ to call threading.Thread.join() to clean-up threads on python if they exit cleanly? | |
""" | |
import threading | |
import time | |
def do_a_thing(idx): | |
print(f"starting {idx}") | |
time.sleep(1) |
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
class ZipInfoTimeless(zipfile.ZipInfo): | |
def __init__(self, *args, **kwargs): | |
# Patch year to 1980 if given a datetime before 1980. Also jump through hoops because tuples are | |
# immutable. | |
if 'date_time' in kwargs and kwargs['date_time'][0] < 1980: | |
dt = list(kwargs['date_time']) | |
dt[0] = 1980 | |
kwargs['date_time'] = tuple(dt) | |
elif len(args) > 1 and args[1][0] < 1980: | |
dt = list(args[1]) |
http://www.tpdz.net/productinfo/398300.html
Contents of card directory files under /proc/asound
for reference.
MX3
Contents of card directory files under /proc/asound
for reference.
Control
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
#!/usr/bin/env python3 | |
# | |
# Falcon + zipfile streaming content using os.pipe() to minimize RAM usage to a | |
# pipes worth of data. | |
# | |
# This test program generated a nearly 500 MB zip file with various compression | |
# arguments supported by the python3 standard library. | |
# | |
# Usage for debug webserver: | |
# $ ./app.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
# Run this tool and feed it stuff. | |
# $ python3 udp-test.py | |
# | |
# Emulate a remote client sending data: | |
# $ cat /dev/urandom | nc -u 127.0.0.1 7502 | |
# | |
# Cancel netcat and try again, second attempt will fail because the source port | |
# likely changed (not guaranteed, but statistically likely) | |
# |
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
# | |
# Proof of Concept | |
# | |
# Compose a docker image of an upstream images so that binaries packages in one | |
# image can be incorporated into another. | |
# | |
# TODO This copies, would be nice if there was a way to attach an image to a | |
# container like `docker run --volumes-from` does for containers. | |
# These FROMs used as a way to distribute files via an image |
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
#include <iostream> | |
#include <cxxabi.h> | |
using namespace std; | |
// To execute C++, please define "int main()" | |
int main() { | |
auto words = { "Hello, ", "World!", "\n" }; | |
int status; |