This file contains hidden or 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
--- a/src/drivers/net/intel.c | |
+++ b/src/drivers/net/intel.c | |
@@ -181,21 +181,41 @@ static int intel_init_eeprom ( struct intel_nic *intel ) { | |
static int intel_fetch_mac_eeprom ( struct intel_nic *intel, | |
uint8_t *hw_addr ) { | |
int rc; | |
+ uint16_t offset; | |
/* Initialise EEPROM */ | |
if ( ( rc = intel_init_eeprom ( intel ) ) != 0 ) |
This file contains hidden or 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 <SoftwareSerial.h> | |
#include <Wire.h> | |
#include <NewPing.h> | |
#define TRIGGER_PIN 13 // Arduino pin tied to trigger pin on ping sensor. | |
#define ECHO_PIN 5 // Arduino pin tied to echo pin on ping sensor. | |
#define MAX_DISTANCE 100 // Maximum distance we want to ping for (in centimeters). Maximum sensor distance is rated at 400-500cm. | |
NewPing sonar(TRIGGER_PIN, ECHO_PIN, MAX_DISTANCE); // NewPing setup of pins and maximum distance. | |
SoftwareSerial mySerial(2, 3); // RX, TX, Serial is needed to debug |
This file contains hidden or 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 | |
for i in qtimageformats qtsvg qtjsbackend qtscript qtxmlpatterns qtdeclarative qtsensors qt3d qtgraphicaleffects qtjsondb qtlocation qtquick1 qtsystems qtmultimedia | |
do | |
cd ~/opt/qt5/$i && echo "Building $i" && sleep 3 && /usr/local/qt5pi/bin/qmake . && make -j5 && sudo make install && touch COMPILED | |
cd ~/opt/qt5/ | |
done | |
for i in qtimageformats qtsvg qtjsbackend qtscript qtxmlpatterns qtdeclarative qtsensors qt3d qtgraphicaleffects qtjsondb qtlocation qtquick1 qtsystems qtmultimedia |
This file contains hidden or 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 | |
#This script will download, set up, compile QT5, and set up the SDCard image ready to use. | |
#Pass -h to use https for git | |
OPT=~/opt | |
CC=$OPT/gcc-4.7-linaro-rpi-gnueabihf | |
CCT=$OPT/cross-compile-tools | |
MOUNT=/mnt/rasp-pi-rootfs | |
QTBASE=$OPT/qt5 |
This file contains hidden or 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 | |
sudo apt-get update -y | |
sudo apt-get install ruby1.9.1-full | |
sudo update-alternatives --set ruby /usr/bin/ruby1.9.1 | |
sudo mv /usr/bin/gem /usr/bin/gem.old | |
sudo update-alternatives --set gem /usr/bin/gem1.9.1 | |
wget https://opscode-omnibus-packages.s3.amazonaws.com/ubuntu/12.04/x86_64/chef-server_11.0.8-1.ubuntu.12.04_amd64.deb |
This file contains hidden or 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
__author__ = 'keyz' | |
import zmq | |
import sys | |
import random | |
PROXY_ADDRESS = "tcp://localhost:5559" | |
def main(): | |
context = zmq.Context() | |
print "Connecting to server..." |
This file contains hidden or 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 | |
mkdir frames | |
ffmpeg -i in.flv -f image2 -vf fps=fps=2 frames/%05d.png | |
ffmpeg -f image2 -i frames/%05d.png -i timelapse.mp3 -map 0 -map 1 -acodec copy -shortest -vcodec libx264 -r 30 out.mp4 | |
rm frames/* | |
rmdir frames |
This file contains hidden or 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
window.requestFileSystem(LocalFileSystem.PERSISTENT, 0, function (fileSystem) { | |
console.log('file system retrieved.'); | |
fs = fileSystem; | |
var dir = fs.root.getDirectory('tiles', null, function (directory) { | |
var absoluteCDVFileName = directory.toURL() + '/' + localFileName; | |
var name = 'test.mbtiles'; | |
mbTilesPlugin.open({name: name, url: absoluteCDVFileName, type: type}, success, fail); | |
}, fail); | |
},fail); |
This file contains hidden or 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
var totalProgress = 0; | |
var localFileName = 'test.sqlite'; | |
var remoteFile = "http://www.example.com/test.sqlite" | |
window.requestFileSystem(LocalFileSystem.PERSISTENT, 0, function (fileSystem) { | |
console.log('file system retrieved.'); | |
fs = fileSystem; | |
//Not exclusive, so success on create or open |
This file contains hidden or 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 | |
### BEGIN INIT INFO | |
# Provides: minecraft | |
# Required-Start: $local_fs $remote_fs | |
# Required-Stop: $local_fs $remote_fs | |
# Should-Start: $network | |
# Should-Stop: $network | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 |
OlderNewer