This file contains 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
//************************************************************************ | |
// MSP430G2231 Demo - Timer_A, PWM TA1, Up Mode, SMCLK | |
// | |
// Description: This program generates one PWM output on P1.2 using | |
// Timer_A configured for up mode. The value in CCR0, 1000-1, defines the | |
// PWM period and the value in CCR1 the PWM duty cycles. Using SMCLK, | |
// the timer frequenciy is about 1.1kHz with a 25% duty cycle on P1.2. | |
// Normal operating mode is LPM0. | |
// MCLK = SMCLK = default DCO (about 1.1MHz). | |
// |
This file contains 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
/* The setup for this code: | |
http://www.oz9aec.net/index.php/arduino/343-mpx4115a-pressure-sensor-with-arduino | |
*/ | |
#include <LiquidCrystal.h> | |
#include <Wire.h> | |
#define kpa2atm 0.00986923267 | |
// initialize the LCD library with the numbers of the interface pins | |
LiquidCrystal lcd(12, 11, 5, 4, 3, 2); |
This file contains 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
<html> | |
<head> | |
<script src="http://code.jquery.com/jquery-1.5.2.min.js"></script> | |
<script src="http://burritopizza.local/socket.io/socket.io.js"></script> | |
<script src="https://gist.github.com/raw/952547/f298c7e30d0978da0c78df0ff79436e883efbad2/gistfile1.txt"></script> | |
<script src="http://popcornjs.org/code/players/youtube/popcorn.youtube.js"></script> | |
<style type='text/css'> | |
body { | |
} |
This file contains 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
int currentValue = 0; | |
int values[] = {0,0}; | |
void setup() { | |
Serial.begin(9600); | |
} | |
void loop() { | |
if(Serial.available()){ |
This file contains 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
/* | |
* This work is free. You can redistribute it and/or modify it under the | |
* terms of the Do What The Fuck You Want To Public License, Version 2, | |
* as published by Sam Hocevar. See the COPYING file for more details. | |
*/ | |
/* | |
* Easing Functions - inspired from http://gizma.com/easing/ | |
* only considering the t value for the range [0, 1] => [0, 1] | |
*/ | |
EasingFunctions = { |
This file contains 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
// Includes functions for exporting active sheet or all sheets as JSON object (also Python object syntax compatible). | |
// Tweak the makePrettyJSON_ function to customize what kind of JSON to export. | |
var FORMAT_ONELINE = 'One-line'; | |
var FORMAT_MULTILINE = 'Multi-line'; | |
var FORMAT_PRETTY = 'Pretty'; | |
var LANGUAGE_JS = 'JavaScript'; | |
var LANGUAGE_PYTHON = 'Python'; |
This file contains 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
1. Open terminal inside your virtual machine and run: | |
sudo dd if=/dev/zero of=EMPTY bs=1M | |
sudo rm ./EMPTY | |
This will zeroify all the empty blocks on your disk. | |
2. Shutdown you virtual box. | |
3. Check what type of virtual drive do you have: VMDK or VDI. VirtualBox shrinking works only with VDI files. | |
If you have a VDI file, proceed to the last step, otherwise you'll need to perform an additional step of converting your VMDK file |
This file contains 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
Index: evrouter.c | |
=================================================================== | |
--- evrouter.c (revision 15) | |
+++ evrouter.c (working copy) | |
@@ -78,6 +78,7 @@ | |
#include <X11/Xutil.h> | |
#include <X11/keysym.h> | |
#include <X11/extensions/XTest.h> | |
+#include <X11/XKBlib.h> | |
This file contains 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
""" | |
Parse the pygotham json schedule and make ical output | |
for use w/ google calendar, etc. | |
NOTE if you are going to serve the result, apparently google cal won't parse | |
it unless the header Content-Type: text/calendar is set! | |
Really useful for testing output: http://icalvalid.cloudapp.net | |
and http://severinghaus.org/projects/icv/ | |
""" |
This file contains 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/sh | |
### | |
# SOME COMMANDS WILL NOT WORK ON macOS (Sierra or newer) | |
# For Sierra or newer, see https://github.com/mathiasbynens/dotfiles/blob/master/.macos | |
### | |
# Alot of these configs have been taken from the various places | |
# on the web, most from here | |
# https://github.com/mathiasbynens/dotfiles/blob/5b3c8418ed42d93af2e647dc9d122f25cc034871/.osx |
OlderNewer