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 python2.7 | |
# script by Sparks N Smoke based on Alex Eames at http://RasPi.tv | |
import RPi.GPIO as GPIO | |
from time import sleep | |
GPIO.setmode(GPIO.BCM) | |
GPIO.setup(20, GPIO.IN, pull_up_down = GPIO.PUD_UP) # Button 0 | |
GPIO.setup(21, GPIO.IN, pull_up_down = GPIO.PUD_UP) # Button 1 | |
GPIO.setup(22, GPIO.IN, pull_up_down = GPIO.PUD_UP) # Button 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
// I2C device class (I2Cdev) demonstration Processing sketch for MPU6050 DMP output | |
// 6/20/2012 by Jeff Rowberg <[email protected]> | |
// Updates should (hopefully) always be available at https://github.com/jrowberg/i2cdevlib | |
// | |
// Changelog: | |
// 2012-06-20 - initial release | |
/* ============================================ | |
I2Cdev device library code is placed under the MIT license | |
Copyright (c) 2012 Jeff Rowberg |
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
// I2C device class (I2Cdev) demonstration Arduino sketch for MPU6050 class using DMP (MotionApps v2.0) | |
// 6/21/2012 by Jeff Rowberg <[email protected]> | |
// Updates should (hopefully) always be available at https://github.com/jrowberg/i2cdevlib | |
// | |
// Changelog: | |
// 2013-05-08 - added seamless Fastwire support | |
// - added note about gyro calibration | |
// 2012-06-21 - added note about Arduino 1.0.1 + Leonardo compatibility error | |
// 2012-06-20 - improved FIFO overflow handling and simplified read process | |
// 2012-06-19 - completely rearranged DMP initialization code and simplification |
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 | |
# KCtest4.py - All references to picamera have been removed, to allow | |
# MJPG-Streamer to be used to transmit JPEG images over WiFi network | |
import time | |
import os.path | |
import sys | |
import pygame |
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 | |
# KCtest3.py - Records a video using picamera | |
import time | |
import os.path | |
import sys | |
import pygame | |
import pygame.mixer |
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 | |
# KCtest1.py | |
import time | |
import os.path | |
import sys | |
import pygame | |
import pygame.mixer |
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
// | |
// PiBot arduino code - PiBot_Firmware_Alpha | |
// James Torbett 2014 | |
// v. 0.1 | |
// EARLY ALPHA RELEASE | |
// | |
// Todo: | |
// ADC implementation | |
// Temperature (thermistor) | |
// Voltages |
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 | |
# test_pibot_hardware.py | |
import time | |
import os.path | |
import sys | |
import pygame | |
import pygame.mixer |
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 | |
# robot_teleop.py | |
import pibot | |
import time | |
TURN_TIME = 0.2 | |
bot = pibot.PiBot() |
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 | |
# monitor_ultrasonic.py | |
import time | |
import pibot | |
bot = pibot.PiBot() | |
while True: |