Skip to content

Instantly share code, notes, and snippets.

/* MEAL Project (Mindful Eating through Ambient Light)
*
* This sketch takes input from 3 pressure sensors (FlexiForce 100 lb)
* and uses this data to track the weight of food consumed.
* It outputs changes in a light source in response (BlinkM RGB LEDs).
*
* For example:
*
* Plug in the device.
* Turn on the lamp by pressing the power button. Minimum load is recorded.
/* Pop-up Piano
* -----------
*
* Program to output musical tones in response to switches being closed.
*
* I referenced Tom Igoe's ToneTest and am importing the Tone library.
*
* Created by Corinna Sherman
* October 25, 2010
*
@corinnas
corinnas / AnalogInput.pde
Created October 13, 2010 17:11
Analog Inputs
/*
Show It
Demonstrates analog input by reading a light sensor on analog pin 0.
Also records the minimum and maximum sensor values that the sensor sees.
Whenever the program reads an analog sensor value that is smaller than the
current minimum, it replaces the recorded minimum with the new value.
Likewise for the maximum value.
Prints out in the form:
@corinnas
corinnas / Part1_BackNForthRobot.pde
Created October 13, 2010 17:04
DC Motor and H-bridge
/*
* Back-n-forth robot
*
* A device that moves forward until it bumps into something,
* then backward until it bumps into something, and so on.
*
* Two DC motors are controlled by a single H-bridge.
*
* If the touch sensor on the front of the robot is closed,
* the robot will change direction to move backward.
/*
* Mechanisms and Movement
*
* A device that uses two forms of mechanical movement,
* driven by a DC motor:
* it translates rotary motion (DC motor)
* to a rocking motion (4-bar linkage)
* to intermittent motion (dowel on pivot)
*
*