Skip to content

Instantly share code, notes, and snippets.

"""
ELECROW
www.elecrow.com
"""
import lvgl as lv
import time
from espidf import VSPI_HOST
from ili9XXX import ili9488
USB refclock = GPS PPS connected via USB
teensy-X.lan = teensy based NTP servers (with hardware timestamps)
config:
refclock SOCK /var/run/chrony/chrony.ttyACM1.sock refid USB offset 0.000068 poll 3
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
#* USB 0 3 377 5 -7698ns[-7963ns] +/- 5688ns
^- teensy-1.lan 1 4 377 17 -609ns[ -609ns] +/- 19us
Initial exchange between ChargePro2.0 app and HQST solar charge controller
Frame 291: 20 bytes on wire (160 bits), 20 bytes captured (160 bits)
Encapsulation type: Bluetooth H4 with linux header (99)
Arrival Time: Jul 17, 2023 12:46:40.229311000 CDT
[Time shift for this packet: 0.000000000 seconds]
Epoch Time: 1689616000.229311000 seconds
[Time delta from previous captured frame: 0.011403000 seconds]
[Time delta from previous displayed frame: 0.012984000 seconds]
[Time since reference or first frame: 12.425451000 seconds]
@ddrown
ddrown / wsl2-ipv6.bat
Created May 26, 2023 03:45
IPv6 for WSL2
powershell -ExecutionPolicy Unrestricted .\wsl2-ipv6.ps1
# create the namespace "Z-compressed." with the mdbox format
namespace compressed {
type = private
hidden = no
separator = .
#subscriptions = no
prefix = Z-compressed.
location = mdbox:/home/vmail/%d/%n/compressed
list = yes
ignore_on_failure = yes
# generate the CA
client$ ssh-keygen -N '' -C user-ca -f ~/.ssh/ca
Generating public/private rsa key pair.
Your identification has been saved in /home/work/.ssh/ca
Your public key has been saved in /home/work/.ssh/ca.pub
The key fingerprint is:
SHA256:+b1N4C0pVYhMZ2m4XWqz8op50rEH9CAfFT0k9USRCOc user-ca
The key's randomart image is:
+---[RSA 3072]----+
| .o*B+o=|
/*
* Originally from a discord screenshot from an unknown author
* Needs at least g++ version 10.3.1
* output:
💩
🍊
🍉
🍒
🍓
🍍
@ddrown
ddrown / top_block.py
Created October 7, 2018 03:27
gnuradio startup time measurement
def main(top_block_cls=top_block, options=None):
+ start = datetime.datetime.now()
tb = top_block_cls()
tb.start()
+ finished = datetime.datetime.now() - start
+ sys.stderr.write("took %.3f s\n" % (finished.total_seconds()))
@ddrown
ddrown / leaf-uClibc-changes.diff
Last active May 3, 2017 04:49
uClibc-ng-1.0.17 pthread race condition crash
diff --git a/repo/toolchain/buildtool.cfg b/repo/toolchain/buildtool.cfg
index a07053b..c4cd0c4 100644
--- a/repo/toolchain/buildtool.cfg
+++ b/repo/toolchain/buildtool.cfg
@@ -69,6 +69,13 @@
Envname = UC_PATCH6
</File>
+<File sigaction-nop-pthread_cancel.patch>
+ Server = localrepo
Sample of SNTP traffic, source networks:
sprint 4.0%
verizon-wireless 3.4%
tmobile 2.9%
att-wireless 2.8%
comcast 2.1%
orange 1.8%
sky 1.6%
twc 1.0%