I hereby claim:
- I am pfeerick on github.
- I am pfeerick (https://keybase.io/pfeerick) on keybase.
- I have a public key ASDnUoeLmUrvFSkRC51KpJD7BftOaXoHqJ--LdLzZPQQrAo
To claim this, I am signing this object:
sudo apt-get update -qq && sudo apt-get install -y wget unzip cmake make build-essential git python3 python3-pip | |
wget "https://developer.nordicsemi.com/nRF5_SDK/nRF5_SDK_v15.x.x/nRF5_SDK_15.3.0_59ac345.zip" -O /tmp/nRF5_SDK_15.3.0_59ac345.zip && unzip -q /tmp/nRF5_SDK_15.3.0_59ac345.zip -d /opt/ && rm nRF5_SDK_15.3.0_59ac345.zip | |
wget "https://developer.arm.com/-/media/Files/downloads/gnu-rm/9-2020q2/gcc-arm-none-eabi-9-2020-q2-update-x86_64-linux.tar.bz" -O - | tar -xj -C /opt/ | |
git clone https://github.com/JuulLabs-OSS/mcuboot.git /opt/mcuboot && pip3 install -r /opt/mcuboot/scripts/requirements.txt | |
pip3 install adafruit-nrfutil |
#!/bin/bash | |
OCD_SCRIPTS=/home/pfeerick/repos | |
openocd -f ${OCD_SCRIPTS}/stlink.cfg -f ${OCD_SCRIPTS}/flash_app.ocd |
#!/bin/bash | |
function openGPIO | |
{ | |
#test if GPIO sysfs entry exists, create if necessary | |
if [ ! -e "/sys/class/gpio/gpio359" ]; then | |
# echo "DEBUG: export 359" | |
echo 359 > "/sys/class/gpio/export" | |
sleep 0.1 | |
fi |
#!/bin/bash | |
function openGPIO | |
{ | |
#test if GPIO sysfs entry exists, create if necessary | |
if [ ! -e "/sys/class/gpio/gpio359" ]; then | |
# echo "DEBUG: export 359" | |
echo 359 > "/sys/class/gpio/export" | |
fi |
#include <SPI.h> | |
#include "nRF24L01.h" | |
#include "RF24.h" | |
//needed for printDetails | |
#define printf Serial.printf | |
#define sprintf(...) os_sprintf( __VA_ARGS__ ) | |
#define CE_PIN 10 | |
#define CSN_PIN 5 |
I hereby claim:
To claim this, I am signing this object:
#!/bin/bash | |
USERNAME="" | |
PASSWORD="" | |
URL="http://192.168.0.156/snapshot.jpg?user=${USERNAME}&pwd=${PASSWORD}" | |
TIMESTAMP=$(date +%F_%T) | |
OUTPUT_DIR="/home/rock64/ipcam-snapshots" | |
curl "${URL}" --output "${OUTPUT_DIR}/${TIMESTAMP}.jpg" |
import gzip | |
import shutil | |
import os | |
Import("env") | |
def compressFirmware(source, target, env): | |
""" Compress ESP8266 firmware using gzip for 'compressed OTA upload' """ | |
SOURCE_FILE = env.subst("$BUILD_DIR") + os.sep + env.subst("$PROGNAME") + ".bin" | |
if not os.path.exists(SOURCE_FILE+'.bak'): |
#!/bin/bash | |
#elevate to root to ensure no permission errors | |
#[ `whoami` = root ] || exec su -c $0 root | |
if [[ $EUID -ne 0 ]]; then | |
echo "i2cset usually needs sudo powers to run, please login if prompted to avoid permission errors" | |
exec sudo $0 | |
fi | |
echo "Set all Port A pins (GPA0-7) as outputs..." |