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 <stdio.h> | |
#include <sys/types.h> | |
#include <sys/stat.h> | |
#include <fcntl.h> | |
#include <unistd.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include "joystick.h" |
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 <stdlib.h> | |
#include <unistd.h> | |
#include <stdio.h> | |
#include <string.h> | |
#include <fcntl.h> | |
#include <errno.h> | |
#include <linux/i2c-dev.h> | |
#define BYTES2SHORT(X) (X[0] << 8 | X[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
#include <stdlib.h> | |
#include <unistd.h> | |
#include <stdio.h> | |
#include <string.h> | |
#include <fcntl.h> | |
#include <errno.h> | |
#include <sys/ioctl.h> | |
#include <linux/i2c-dev.h> |
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
#!/bin/bash | |
set -e | |
BIN_NAME=shairport-sync | |
BIN_SRC=/usr/bin | |
BINARY="${BIN_SRC}/${BIN_NAME}" | |
PATCH_DIR=/tmp/shairport-patch | |
PATCH_BIN="${PATCH_DIR}/${BIN_NAME}" | |
PATCH_NAME="${PATCH_DIR}/string" |
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
#!/bin/sh | |
ip_flip() { | |
if [ $1 -eq 4 ] | |
then | |
FIRST=$(echo $TUNNEL_IP | cut -d . -f 1-3). | |
LAST=$(echo $TUNNEL_IP | cut -d . -f 4) | |
fi | |
if [ $1 -eq 6 ] |
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 in console | |
// enable popups for website first | |
if (!('lastLat' in window)) { | |
window.lastLat = 0; | |
} | |
if (!('lastLon' in window)) { | |
window.lastLon = 0; | |
} | |
setInterval(function() { | |
$.getJSON(location.href.replace('/tracking', '/status')).then(function(data){ |
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
#!/bin/bash | |
log_dt() { | |
date '+%d.%m.%y %H:%M:%S' | |
} | |
DAY_OF_WEEK=$(date +%u) | |
if [ $DAY_OF_WEEK -eq 1 ] | |
then |
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
const cacheId = 'cache-v1'; | |
function fetchAndCache(request, cache) { | |
return fetch(request).then(function(response) { | |
return cache.put(request, response.clone()).then(function() { | |
return response; | |
}); | |
}); | |
} |
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 <stdio.h> | |
#include <stdlib.h> | |
#include <stdint.h> | |
#ifdef _MSC_VER | |
#include <intrin.h> /* for rdtscp and clflush */ | |
#pragma optimize("gt",on) | |
#else | |
#include <x86intrin.h> /* for rdtscp and clflush */ | |
#endif |
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
# This will issue a production (valid and trusted) certificate | |
certbot certonly --agree-tos --manual --preferred-challenge=dns --manual-auth-hook=./hook.sh --register-unsafely-without-email --manual-public-ip-logging-ok -d '*.example.com' -d 'example.com' --server https://acme-v02.api.letsencrypt.org/directory |
OlderNewer