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
import serial | |
import pygame | |
import struct | |
import os | |
import sys | |
import time | |
class TextPrint: | |
def __init__(self): | |
self.reset() | |
self.font = pygame.font.Font(None, 30) |
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/bash | |
LOCKFILE=/tmp/bkpmysql | |
if [ -e ${LOCKFILE} ] && kill -0 `cat ${LOCKFILE}` | |
then | |
echo "Já rodando!" | |
exit | |
fi | |
trap "rm -f ${LOCKFILE}; exit" INT TERM EXIT | |
echo $$ > ${LOCKFILE} |
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
import serial | |
import time | |
PORT = "/dev/ttyUSB0" # If windows, change it to COMX | |
PINCODE = "1234" # Change it to your PIN | |
DEVNAME = "mybt" # Change it to your device name | |
BAUDRATE= 115200 # Change it to your baudrate | |
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
#Name # offset length datatype | |
adler32 # 0x00 0x04 LE int | |
adlerSeed # 0x04 0x04 LE int | |
playerID # 0x08 0x08 string (null term) | |
region # 0x14 0x04 LE int | |
avatarID # 0x18 0x04 LE int | |
level # 0x1C 0x04 LE int | |
totalCalories # 0x20 0x04 LE float | |
totalV02 # 0x24 0x04 LE float | |
numberRunningSteps # 0x28 0x08 LE int64 |
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
char buff[3]; | |
char recv = 0; | |
void setup() { | |
Serial.begin(115200); | |
} | |
void loop() { | |
if(Serial.available() > 0) { | |
buff[recv] = Serial.read(); |
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
/* | |
_____ _ _ _____ ____ | |
| ___(_) ___ ___| |_ __ _| ___/ ___| | |
| |_ | |/ _ \/ __| __/ _` | |_ \___ \ | |
| _| | | __/\__ \ || (_| | _| ___) | | |
|_| |_|\___||___/\__\__,_|_| |____/ | |
Fiesta 2 Raw Extract | |
*/ |
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/bash | |
for i in folder/* | |
do | |
if grep -q "Delivered-To: email@nobody" "$i" | |
then | |
mv "$i" destfolder/ | |
else | |
echo "NOK" # Doesnt have Delivery To | |
fi |
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
#!/usr/bin/python | |
#encoding:UTF-8 | |
import os, smtplib, shutil, syslog, subprocess, cgi, commands, re, MySQLdb | |
from datetime import date, timedelta | |
from email.mime.multipart import MIMEMultipart | |
from email.mime.text import MIMEText | |
from htmlentitydefs import codepoint2name | |
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/bash | |
for i in $(seq 0 $1) | |
do | |
wget http://cdn.photosynth.net/ps2/$2/packet/l1/img`printf %04d ${i%.*}`.jpg | |
done |
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
#!/usr/bin/env python | |
''' | |
_____ ____ _ | |
| ___| __/ ___|| | ___ _ | |
| |_ | '__\___ \| |/ / | | | | |
| _|| | ___) | <| |_| | | |
|_| |_| |____/|_|\_\\__, | | |
|___/ |
OlderNewer