Skip to content

Instantly share code, notes, and snippets.

View yeyus's full-sized avatar
🍝

Jesús F. Trujillo yeyus

🍝
View GitHub Profile
@yeyus
yeyus / gist:5476308
Created April 28, 2013 08:43
Vagrant curl Bad CPU Type on Core Duo OS X 10.6.8
Vagrant comes with its own curl version at /Application/Vagrant/embedded/bin directory. This curl was compiled against a 64bit machine so you should replace it with a suitable version into your computer...
The stack trace for the error is:
Downloading or copying the box...
/Applications/Vagrant/embedded/gems/gems/vagrant-1.2.2/lib/vagrant/util/subprocess.rb:84:in `rescue in execute': Bad CPU type in executable - curl (Vagrant::Util::Subprocess::LaunchError)
from /Applications/Vagrant/embedded/gems/gems/vagrant-1.2.2/lib/vagrant/util/subprocess.rb:77:in `execute'
from /Applications/Vagrant/embedded/gems/gems/vagrant-1.2.2/lib/vagrant/util/subprocess.rb:23:in `execute'
from /Applications/Vagrant/embedded/gems/gems/vagrant-1.2.2/lib/vagrant/util/downloader.rb:122:in `block in download!'
from /Applications/Vagrant/embedded/gems/gems/vagrant-1.2.2/lib/vagrant/util/busy.rb:19:in `busy'
from /Applications/Vagrant/embedded/gems/gems/vagrant-1.2.2/lib/vagrant/util/downloader.rb:121:in `download!'
@yeyus
yeyus / index.html
Created June 28, 2013 07:16
Orientation detection for full-screen parallax
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Orientation Test</title>
<script src="http://cdnjs.cloudflare.com/ajax/libs/jquery/2.0.2/jquery.min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/modernizr/2.6.2/modernizr.min.js"></script>
<script src="orientation.js"></script>
<link rel="stylesheet" href="style.css">
</head>
@yeyus
yeyus / simavr-install.md
Last active August 29, 2015 14:03
simavr install and dependencies

Dependencies

  • elfutils
  • libelf1
  • libelf-dev
  • freeglut3 (req. by OpenGL sample code)
  • freeglut3-dev (req. by OpenGL sample code)
  • libglib2.0-dev
  • gcc-avr
  1. Clone https://github.com/gmacario/easy-build
  2. cd easy-build/build-yocto
  3. ./build.sh
  4. ./run.sh
  5. -- Now you should be inside the build-yocto docker container --
  6. cd /work
  7. source /opt/yocto/poky/oe-init-build-env <>
  8. bitbake -k core-image-minimal
@yeyus
yeyus / wpa-cli-linux.txt
Created November 1, 2014 22:43
wpa through console in linux
wpa_passphrase myrouter mypassphrase > wpa.conf
iwlist scan
wpa_supplicant -Dwext -ieth1 -c/root/wpa.conf
wpa_cli status
@yeyus
yeyus / gist:7695050d129c8ffc3427
Created January 26, 2015 07:42
GIF recording linux
xdotool getmouselocation --shell (get mouse location)
byzanz-record --x=1101 --width=610 --y=44 --height=950 InstagramViewer.gif --duration=20 --delay=0
@yeyus
yeyus / XMLDefault.cnf.xml
Created March 2, 2015 06:58
Cisco 7960 XMLDefault.cnf.xml
<Default>
<callManagerGroup>
<members>
<member priority="0">
<callManager>
<ports>
<ethernetPhonePort>2000</ethernetPhonePort>
<mgcpPorts>
<listen>2427</listen>
<keepAlive>2428</keepAlive>
@yeyus
yeyus / arduino-hex-burn.sh
Created April 29, 2015 04:33
burn .hex to arduino board through serial using vanilla bootloader
#/bin/sh
# burn myhex.hex file
/usr/share/arduino/hardware/tools/avrdude -C/usr/share/arduino/hardware/tools/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P /dev/ttyUSB0 -b57600 -D flash:w:myhex.hex:iç
# verify contents of flash against myhex.hex
/usr/share/arduino/hardware/tools/avrdude -C/usr/share/arduino/hardware/tools/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P /dev/ttyUSB0 -b57600 -D flash:v:myhex.hex:i