Skip to content

Instantly share code, notes, and snippets.

🏠
Working from home

David Cotterill-Drew Robotonics

🏠
Working from home
Block or report user

Report or block Robotonics

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@Robotonics
Robotonics / GUI_2
Created Jul 12, 2014
Arduino sketch to display temp+humidty data from DHT11 sensor on ST7735 TFT LCD
View GUI_2
#include <Adafruit_GFX.h> // Core graphics library
#include <Adafruit_ST7735.h> // Hardware-specific library
#include <SPI.h>
#include <dht.h> // dht temp humidity sensor library
#define cs 10
#define dc 9
#define rst 8
#define DHT11_PIN 3
@Robotonics
Robotonics / Arduino Xinda IR remote
Created Jul 17, 2014
Arduino IRremote library usage with cheap 20 button IR remote from Xinda
View Arduino Xinda IR remote
#include <IRremote.h>
int RECV_PIN = 11;
IRrecv irrecv(RECV_PIN);
decode_results results;
void setup()
{
View opencv_show_webcam_detect_face.py
#!/usr/bin/env python2
"""
OpenCV example. Show webcam image and detect face.
"""
import cv2
TRAINSET = "/usr/share/OpenCV/lbpcascades/lbpcascade_frontalface.xml"
DOWNSCALE = 4
@Robotonics
Robotonics / ADS7843 Calibrate function
Created Jun 8, 2012
Calibration routine for ADS7843
View ADS7843 Calibrate function
void ADS7843_Calibrate(void)
{
static Coordinate *Pos;
uint16_t MatriceA[3][3] = {{1,1,1},{1,1,1},{1,1,1}}; // MatriceA for values of ADC ADS7843
uint8_t i,j; // Inserts itself into a matrix
uint32_t detA; // determinant matriceA
int32_t transA[3][3]; // transpose matriceA
float invA[3][3]; // Invert MatriceA
float pom; // to save 1/detA
@Robotonics
Robotonics / main.c
Created Nov 17, 2012
uart debugging example for the msp430 launchpad using usci
View main.c
/*
* Program that takes commands via Async Serial, which could be useful for debugging.
* LEDs are green when transmitting data, and red when receiving data.
*
* G2553 Pinout:
* 1.0 - red status led
* 1.1 - uart input
* 1.2 - uart output
* 1.6 - green status led
*
View gist:4150414
https://www.evernote.com/shard/s247//sh/d4b767ad-9459-4493-b9e7-67e42a50acee/42a821d110aa5fa3decdc86528bfb07b
@Robotonics
Robotonics / CatAndMouse.ino
Created Nov 23, 2015 — forked from mbparks/CatAndMouse.ino
The Wiring code for the Arduino Esplora. Reads the Joystick X, Y, and Joystick Button. As well as the Up, Down, Left, and Right buttons. Then sets status to Processing sketch via Serial communication. Cat and Mouse is a two player game where my one player uses the Esplora and acts as the cat. The other user uses the computer's mouse and plays th…
View CatAndMouse.ino
//////////////////////////////////////////////
// CAT AND MOUSE GAME
// Author: Mike Parks
//
//////////////////////////////////////////////
// INCLUDE LIBRARIES
#include <Esplora.h>
// DECLARE GLOBAL VARIABLES
View main.c
#include "lm4f120h5qr.h"
#include "inc/hw_memmap.h"
#include "inc/hw_types.h"
#include "driverlib/i2c.h"
#include "driverlib/debug.h"
#include "driverlib/gpio.h"
#include "driverlib/pin_map.h"
#include "I2C_Stellaris_API.h"
#include "utils/uartstdio.h"
@Robotonics
Robotonics / srf02.c
Created Jan 27, 2013
I2C driver for SRF02
View srf02.c
/*
* srf02.c
*
* Created on: 26 Jan 2013
* Author: David
*/
//includes
#include "lm4f120h5qr.h"
#include "inc/hw_memmap.h"
@Robotonics
Robotonics / cmps03.c
Created Jan 27, 2013
I2C driver for cmps03 electronic compass
View cmps03.c
/*
* cmps03.c
*
* Created on: 26 Jan 2013
* Author: David
*/
// driver for cmps03 electronic compass
You can’t perform that action at this time.