Skip to content

Instantly share code, notes, and snippets.

View abythell's full-sized avatar

Andrew Bythell abythell

View GitHub Profile
@abythell
abythell / rxtx.xml
Last active December 31, 2015 13:59
Ant tasks for distributing Java projects that use RXTX binaries.
<!--
rxtx.xml
Copyright 2013 Andrew Bythell <abythell@ieee.org>
Ant tasks for distributing Java applications with platform-specific RXTX
libraries as zip files. To use:
1. Get and unzip RXTX - http://rxtx.qbang.org/pub/rxtx/rxtx-2.2pre2-bins.zip into your project directory.
2. Copy this file (rxtx.xml) into the RXTX directory.
3. Include rxtx.xml in your build.xml.
@abythell
abythell / camdate-java-install.sh
Last active December 15, 2015 23:19
A script to download, build, and install CamDate, a Java application built using libgphoto2-jna. CamDate sets the current system time to the current time on a USB-attached camera.
#!/bin/bash
#
# Automatically download, build, and install CamDate, a tool
# to set the System Time on a Raspberry Pi using a gphoto2-suppored
# camera.
#
#
# Check if root
#
@abythell
abythell / camdate.sh
Created April 8, 2013 17:54
Use gphoto2 to set the system time from a USB-attached camera. Handy for use on a Raspberry Pi which does not have a real-time clock or network connection for NTP.
#!/bin/bash
# Set system date using gphoto2 camera
#
# Make sure a root user is running this script
#
if [[ $EUID -ne 0 ]]; then
echo "Must run as root/sudo"
exit -1
fi
@abythell
abythell / arduino-firmware-stk500.diff
Created January 8, 2013 19:50
Patch for Arduino firmware for programming via STK500
diff --git a/hardware/arduino/firmwares/atmegaxxu2/arduino-usbdfu/makefile b/hardware/arduino/firmwares/atmegaxxu2/arduino-usbdfu/make
index 1fb4ed3..a2782ac 100755
--- a/hardware/arduino/firmwares/atmegaxxu2/arduino-usbdfu/makefile
+++ b/hardware/arduino/firmwares/atmegaxxu2/arduino-usbdfu/makefile
@@ -116,7 +116,7 @@ OBJDIR = .
# Path to the LUFA library
-LUFA_PATH = ../..
+LUFA_PATH = ../../LUFA