Skip to content

Instantly share code, notes, and snippets.

@mathieue
mathieue / udp-multi-socat.sh
Created August 28, 2012 23:57
udp multiplexer with socat
socat - udp4-listen:8125,fork | tee >(socat - udp-sendto:127.0.0.1:8135) >(socat - udp-sendto:127.0.0.1:8140)
@Nokius
Nokius / ac100-kernel.md
Last active June 29, 2023 18:40
ARCH LINUX WITH MAINLINE KERNEL FOR TOSHIBA AC100 [paz00 / dynabookaz]

ARCH LINUX WITH MAINLINE KERNEL FOR TOSHIBA AC100

all u need

  • 1-2 hours of your life
  • build envirment for the Kernel
  • device with Ubuntu and nvflash
  • AC100
  • mini-usb cabel
  • usb-stick >512MB
@EndingCredits
EndingCredits / Mopidy Pi
Last active December 8, 2022 22:23
Setting up mopidy and MPD/http clients
Install mopidy: ##N.B: You might need to do this as per instructions on `https://docs.mopidy.com/en/latest/installation/debian/`
`sudo apt-get update && sudo apt-get install mopidy`
Set the mopidy to run automatically via `sudo systemctl enable mopidy`
Now we need to set up configuration files.
Since we're going to be running mopidy as a service, we need to edit `/etc/mopidy/mopidy.conf`(see https://docs.mopidy.com/en/latest/service/#service)
Add the following to to configuration file:
@meanevo
meanevo / compile-haproxy.sh
Last active October 25, 2022 07:42 — forked from ryzy/a.sh
Compile HAProxy from source on CentOS 7
# Make sure you have these installed
yum install -y make gcc perl pcre-devel zlib-devel
# Download/Extract source
wget -O /tmp/haproxy.tgz http://www.haproxy.org/download/1.7/src/haproxy-1.7.2.tar.gz
tar -zxvf /tmp/haproxy.tgz -C /tmp
cd /tmp/haproxy-*
# Compile HAProxy
# https://github.com/haproxy/haproxy/blob/master/README
make \
TARGET=linux2628 USE_LINUX_TPROXY=1 USE_ZLIB=1 USE_REGPARM=1 USE_PCRE=1 USE_PCRE_JIT=1 \
@miekg
miekg / udpserv.go
Created May 10, 2017 09:29
Simple udp server in Go
package main
import (
"log"
"net"
)
func main() {
// listen to incoming udp packets
pc, err := net.ListenPacket("udp", ":1053")
@jarek-przygodzki
jarek-przygodzki / node_exporter-as-systemd-service.md
Last active May 31, 2024 16:11
Installing node_exporter as systemd serivice
sudo useradd --system --shell /bin/false node_exporter
curl -fsSL https://github.com/prometheus/node_exporter/releases/download/v1.3.1/node_exporter-1.3.1.linux-amd64.tar.gz \
  | sudo tar -zxvf - -C /usr/local/bin --strip-components=1 node_exporter-1.3.1.linux-amd64/node_exporter \
  && sudo chown node_exporter:node_exporter /usr/local/bin/node_exporter
@amcolash
amcolash / ATTiny + Micronucleus
Last active April 23, 2024 21:28
ATTiny85 + micronucleus using an AVR programmer
This gist is a list of instructions that I used to program my ATTiny85s with Micronucleus. They worked for me, but your mileage may vary! I would highly recommend starting by looking at the SparkFun article linked at the bottom for schematics and more in-depth info. This gist is mostly just a copy/paste list.
## Required:
- ATTiny85
- AVR programmer
- 1 uF capacitor
- Micronucleus FW: https://github.com/micronucleus/micronucleus/releases
- avrdude: http://www.nongnu.org/avrdude/
## Setup:
@miguelmota
miguelmota / send.sh
Created January 16, 2019 06:19
Golang UDP server example
echo 'hello world' > /dev/udp/0.0.0.0/3000
@luk6xff
luk6xff / ARMonQEMUforDebianUbuntu.md
Last active October 12, 2024 02:46 — forked from bruce30262/ARMDebianUbuntu.md
Emulating ARM with QEMU on Debian/Ubuntu

You might want to read this to get an introduction to armel vs armhf.

If the below is too much, you can try Ubuntu-ARMv7-Qemu but note it contains non-free blobs.

Running ARM programs under linux (without starting QEMU VM!)

First, cross-compile user programs with GCC-ARM toolchain. Then install qemu-arm-static so that you can run ARM executables directly on linux

If there's no qemu-arm-static in the package list, install qemu-user-static instead

@cr3ative
cr3ative / jiggler.md
Last active July 11, 2024 08:38
Making an inexpensive USB Mouse Jiggler, with slightly better USB Descriptor (PID, VID, Manufacturer)

Making a half-convincing USB Mouse Jiggler on the cheap

I object to USB Mouse Jigglers being £20-£30 on Amazon for something a microcontroller should be able to do with ease, in an unconfigurable/unknown state when it comes to how they describe themselves to the host machine.

We can do better, with a reprogrammable version for about £6.

There are existing guides to each part of this, and I've linked them inline. Here's a great one for people less familiar with Arduino, but this guide assumes basic knowledge of Arduino.

Hardware