View pyglet_ogl.py
import pyglet
pyglet.options['shadow_window'] = False
window = pyglet.window.Window()
print("OpenGL info:")
print(window.context.get_info().get_version())
print(window.context.get_info().get_renderer())
print(window.context.get_info().get_vendor())
View frame_buffer_test.py
import pyglet
required_extensions = [
'GL_ARB_framebuffer_object',
'GL_EXT_framebuffer_object',
'GL_EXT_framebuffer_blit',
'GL_EXT_framebuffer_multisample',
'GL_EXT_packed_depth_stencil',
]
View tornado-lightning.ino
//
// PIN MAPPINGS
//
const int num_relays = 8;
const int relays[] = {2, 3, 4, 5, 6, 7, 8, 9};
const int input_pin = A0;
const int input_threshold = 50;
//
View tornado-relay-tester.ino
const int num_relays = 8;
const int relays[] = {2, 3, 4, 5, 6, 7, 8, 9};
const int duration = 1000;
void setup() {
for (int i = 0; i < num_relays; i++) {
pinMode(relays[i], OUTPUT);
digitalWrite(relays[i], HIGH);
}
View ardubotics-light-avoider.ino
/*
* LIGHT AVOIDER ROBOT
*
* A simple Arduino based obstacle avoider robot that uses two light dependent resistors to
* measure the amount of light in its environment and then move to the area with less light.
*
* Abhik Pal
* (abhik@ardubotics.com)
*
* Released under The MIT License (MIT)
View ardubotics-line-follower.ino
/*
* LINE FOLLOWER ROBOT
*
* An Arduino based robot that uses an infrared sensor array to follow a line.
*
* Abhik Pal
* (abhik@ardubotics.com)
*
* Released under The MIT License (MIT)
*/
View ardubotics-accelerometer-calibrate.ino
/*
* Callibration sketch for the accelerometer.
*
* Simply prints out the values from the x, y, and z axes to the serial monitor. These values can be
* used to calibrate the sensor.
*
* To use this code with the tilt controlled robot, keep the accelerometer flat and then record the
* readings for x and the y axes. The calibrated_x and calibrated_y in the tilt-robot sketch should
* be set to these base values.
*
View ardubotics-basic-ardubot.ino
/*
* BASIC ARDUBOT
*
* A simple Ardubot that demonstrates a basic set of movements.
*
* Abhik Pal
* (abhik@ardubotics.com)
*
* Released under The MIT License (MIT)
*/
View ardubotics-joystick-robot.ino
/*
* Joystick Controlled Robot
*
* An arduino based robot that can be controlled using an analog joystick.
*
* Abhik Pal
* (abhik@ardubotics.com)
*
* Released under The MIT License (MIT)
*/
View ardubotics_joystick_serial.ino
/*
* Joystick and the serial monitor.
*
* This sketch outputs data from the joystick at 9600 baud to the 'Serial Monitor' (the serial
* monitor needs to be opened to view this data).
*
* CIRCUIT:
* - Joystick VCC to Arduino 5V, joystick GND to Arduino GND
* - Joystick vertical axis to A0, horizontal to A1
* - Joystick pushbutton connected to digital pin 2 using a pull-up resistor