Skip to content

Instantly share code, notes, and snippets.

@threebytesfull
threebytesfull / Snowflake.elf
Last active November 26, 2017 19:51
Built with latest code in master
@threebytesfull
threebytesfull / Nanode_MAC.pde
Created June 11, 2011 20:56
Sample code to read the MAC address on a Nanode V5.
// Nanode_MAC
// Rufus Cable, June 2011 (threebytesfull)
// Sample code to read the MAC address from the 11AA02E48 on the
// back of the Nanode V5 board.
// This code is hacky and basic - it doesn't check for bus errors
// and will probably fail horribly if it's interrupted. It's best
// run in setup() - fetch the MAC address once and keep it. After
// the address is fetched, it puts the chip back in standby mode
@threebytesfull
threebytesfull / fstab
Created May 12, 2011 11:05
Example /etc/fstab on Mac OS X 10.6 to disable auto-mounting of specific volumes
# You can find the volume UUID in Disk Utility. Select the volume on the left
# and then File->Get Info. See "Universal Unique Identifier".
#
# Options used below:
# ro for readonly (can be omitted)
# noauto to prevent auto-mount
# noatime to skip writing last access times (performance thing, optional)
#
# Remember to set the filesystem type (hfs, ntfs, etc) too
##########
# add to .bash_profile or whatever
# convenience function to determine location - uses domain from resolv.conf instead
# of network location (which may not always be set correctly)
function currentloc {
local location
local domain=$(cat /etc/resolv.conf | awk '/^domain/ { print $2 }')
case $domain in
*.mycompany.com)
location=work