Coursework, notes, and progress while attending NYU's Interactive Telecommunications Program (ITP)

Responsive plant: sensors & movement

Initial interaction: distance sensors & motor

So far the most complicated aspect of our project has been determining the mechanism to turn the plant! We’ve experimented a lot at the advice of our peers, Making Things Move, and Ben Light.

Prototyping with gears and a lazy susan

Prototyping with gears, lazy susan, cardboard, and a 360 servo

First, we tested with a lazy susan, some gears, and a 360 servo motor. We figured to get the precision we needed we should use a stepper motor, which we got to work with an EZ driver (as opposed to an H bridge). The EZ driver has pins for power (it needs 5V), direction, speed, and the stepper motor itself. Once we got our proximity sensors, we tested a very initial sketch that controls the speed and direction of the turn based on where the sensor detect something.

img_1660

Testing form

We spent some time figuring out how to connect the gears to the bottom of the lazy susan, and considered whether we needed a slip ring for the wires that will be connected to the plant with the arduino that will be in the base. After meeting with Ben Light, we think that by using a rubber stopper on our motor and placing this next to we can control the lazy susan directly, but we still need to build this to see if it works.

Sensor data to node.js

My goal is to save sensor data to a database so the first piece of this was getting the serial lab related to this to work. I successfully got the moisture and microphone data into the browser! Now I just need to write the code that sends the data to an MongoDB database (I’m using an MLab account), and serve it as an API.

CO2 sensor calibration

We’re working with this MG-811 sensor module, since this seemed to be one of the least expensive CO2 sensors available, and since we were able to find some sample code to go along with it. To figure out how to calibrate it, we’ve referenced documentation here and for a similar sensor module. From our understanding, this sensor works by outputting a voltage, and as the CO2 concentration increases the voltage output decreases. The code that goes along with it sets a voltage equal to 400ppm as a sort of baseline, and then does math to express changing voltage as CO2 concentration.

Going through the MG-811 documentation led us to think the only way to get an accurate reading (although maybe a relative reading is good enough for this project) is to calibrate it with some other equipment, otherwise we might never know the true CO2 concentration of the environment. Another limitation of our sensor may be that it’s not meant to detect concentrations below 400ppm–we’re trying to see if this limitation could be overcome, and whether changing the math in the sample code will render the data somehow inaccurate.
img_1675

CO2 sensor testing with a breadboard

We have tapped Marina, George, and former ITP-er Nick Johnson (currently at CUSP) to help us think through how we can calibrate the sensor and connect us to people that might have helpful equipment. After a very helpful e-mail exchange with Nick, who directed us here, here, and here, we think that one solution could be to leave the sensor running at ITP to get baseline voltage readings, and assume this is 400ppm. We should definitely set this up this week!

Box diagram for initial interaction

Aaron Parsekian helped us think through all of the elements we have discussed including the project and where they should go for the distance-sensing and plant movement interaction:

img_1678

Working from this system diagram for interaction #1

Wireless?

The lowest priority piece right now, and the part I’m least sure will work, is sending the data wirelessly to node rather than having wires. We thought we might be able to use a huzzah wifi module, but to test it on the floor we need to get the mac address from the device, and I’ve already run into trouble. **UPDATE: Was able to read the mac address by printing it in loop instead of setup.

screen-shot-2016-11-26-at-11-00-01-pm

Garbled mac address

Once we can connect the device to the sandbox network on the floor, I’m still not sure how we will send the data from multiple environment sensors, especially since this works at a higher baud rate.

Updated Project Timeline

We are behind on some things we intended to have complete by now, and ‘/’ indicates these are in progress!

Dates Tasks Complete?
11/16/2016-11/22/2015 Adafruit order (motor, sensors) x
Experiment with sensors (infrared, CO2) /
Buy & weigh plant
Sensor data to node.js x
Node.js to p5 x
Buy motor with right amount of torque
Plan construction of plant holder x
11/23/2016-11/29/2015 Make first interaction work: approach plant and it turns /
Create visualization in P5 based on what we learn about sensor output
Write Node.js code to read sensor data & set up database /
11/30/2016-12/6/2015 Connect sensors to node to p5
Build coin box (scrap wood and copper tape)
12/7/2016-12/13/2015 Make second interaction work: add reaction for coin drop
Build stand alone website
12/14/2016 Project Due!

Updated BOM

Item Quantity Amount ($) Link to purchase Did we get it?
Plant 1 $20.00 Not yet
Pot/Plant holder 1 $10.00 Not yet
Lazy susan 1 $4.48 http://www.homedepot.com/p/Everbilt-6-in-Square-Lazy-Susan-Turntable-with-400-lb-Load-Rating-49548/203661089?cm_mmc=SEM|THD|google|&mid=sXHAZG02o|dc_mtid_8903tb925190_pcrid_111414437105_pkw__pmt__product_203661089_slid_&gclid=Cj0KEQiA6_TBBRDInaPjhcelt5oBEiQApPeTF2Fa17c1-6Yvlaw5TNzVQrrl1r3-p2UoFVOWTScYFREaAnIT8P8HAQ Currently borrowing for prototyping
Gear kit 1 $12.99 http://www.robotshop.com/en/vex-gear-kit.html Borrowed
Rubber stopper (small) 1 $1.95 http://www.robotshop.com/en/vex-gear-kit.html Borrowed
Rubber stopper (large) 1 $3.60 Yes
Screws and nuts assorted $6.00 Yes
125oz/in Stepper Motor 1 $23.95 https://www.sparkfun.com/products/13656 Smaller motor borrowed
EZ driver 1 $14.95 https://www.sparkfun.com/products/12779 Yes
IR distance sensor (10-80cm) 3 $44.85 https://www.adafruit.com/products/164 Yes
MG-811 CO2 Gas Sensor Module 1 $58.95 https://www.jameco.com/z/SEN0159-DFRobot-CO2-Sensor-Arduino-Compatible-_2213270.html Yes
Adafruit Feather HUZZAH w/ ESP8266 WiFi 1 $15.95 https://www.adafruit.com/products/2821 Jasmine has this
Arduino Mega 1 $45.95 https://www.adafruit.com/product/191 Jasmine has this if needed
Slip ring 1 14.95 https://www.sparkfun.com/products/13064 Yes
Moisture sensor 1 $4.95 https://www.sparkfun.com/products/13322 Yes
Microphone (w/breakout) 1 $5.95 https://www.sparkfun.com/products/12758 Yes
Photocells 2 1.90 https://www.adafruit.com/products/161 Jasmine has these if needed
scrap (wood/cardboard) some School
copper tape some School
Total $263.62

Post a Comment

Your email is kept private. Required fields are marked *