Skip to content

Instantly share code, notes, and snippets.

@wkliang
wkliang / ek21-bookmark-let.js
Created October 11, 2016 18:42
ek21 bypass noisy script
javascript:(function(e, s) {
e.src = s;
e.onload = function() {
alert('gist injected');
};
document.head.appendChild(e);
})(document.createElement('script'), 'https://gist.githubusercontent.com/anonymous/d6004fc355bf7c4a41cbfa3d746c350e/raw/591a1c972b33dbef58bdeed7b95560d80b547e85/ek21.js');
@wkliang
wkliang / trigger.sh
Last active January 10, 2024 06:54
raspberry pi 5 sysfs + udev to control gpio
#!/bin/bash
if [ $1 == 'CH1' ] ; then # gpio 26, PIN37
ch=425
elif [ $1 == 'CH2' ] ; then # gpio 20, PIN38
ch=419
elif [ $1 == 'CH3' ]; then # gpio 21, PIN40
ch=420
else
echo "Parameter error"