Update on March 2014:
Mechaphytum Animus is getting complicated... Now she has a fan to control temperature and a humidifier to control environmental humidity... I took this recent pic to show that she is alive... A camera and wifi is the next on the todo list...
At last I managed to complete the design of watering system which is controlled by the soil sensor connected to relay 1... I used the air pump of a faulty blood pressure meter from my garbage bin to pressurize an enclosed beverage bottle which sends water to the plant housing by the help of some aquarium pipe...the system is designed as safe as possible from water spills because we all know that water and electronics is not a good combination...
Update on Feb 2014:
This is the Mechaphytum Animus V1... Still working on problematic Jansen legs, I decided to build my plantoid without legs as V1... It has a recycled body borrowed from an old stereo rack cabin, a sun tracker circuit aligning the plant to the max lighting conditions on a turntable, soil, capacitive and galvanic response sensors as well as environmental temperature and humidity sensors... All electronics are placed in front of the cabin for easy access, the Arduino, a relay board and mood led, a 4post usb hub for future connections such as camera and wifi... 12v 5amp regulated power supply is placed inside the cabin...
I also retired my Hoya Carnosa which was too big and the new candidate plantoid plant is a Kalanchoe which is smaller and has big succulent leaves for sensor attachment...
As a robotics fan and botanical hobbyist I decided to work on Plantoids... the wonderful work of DJUltis and GroG inspired me to work on this project... As a start, I made a datalogging setup for monitoring one of my plants, a Hoya Carnosa ( randomly selected among my hundreds of plants just for her closeness to my working environment)... the data is collected with many sensors, mainly environmental and plant signalling... I made a simple resistive sensor sticking EKG electrodes to both sides of a leaf and reading with Arduino. I had a soil humidity sensor and connected that to the pot too. A temp sensor reads the environmental temperature ( had all kinds of temp sensors but selected DS18B20 because it is digital, accurate and easy to use)... I have a RTC module, air humidity sensors and BMP85 barometric sensor too but will add them later... As a broke hobbyist I made a diy datalogger from one of my micro-sd card readers lying around. the setup can be seen from the above pic... while carrying out this datalogging I learned much about how the plant reacts to her environment...
GroG just reminded me of the ThingsSpek service of MRL and will be integrating that to my project soon... so anyone interested can monitor my plant's health remotely... Just in case anyone may be interested the software side, i am attaching here my datalogging Arduino sketch for reference...
/*Read DS18B20 Temp sensor for plant signal datalogging* Dincer Hepguler 2013* DS18B20 code from: sheepdogguides.com/arduino/ar3ne1tt.htm* Code lightly adapted from code from nuelectronics.com*/#include <SD.h>// Pin definitions - attaches a variable to a pin.// On the Ethernet Shield, CS is pin 4. Note that even if it's not// used as the CS pin, the hardware CS pin (10 on most Arduino boards,// 53 on the Mega) must be left as an output or the SD library// functions will not work.const int chipSelect = 10;const int LeafSensor = A2; // A2 pin is used to read the value of the Leaf Sensorint LeafState;const int SoilSensor = A0; // A0 pin used to read val of soil sensorint SoilState;int NumReadings = 20; //number of readings per avarage//float Deg;#define TEMP_PIN 3 //D3 pin for ds18b20 signal linevoid OneWireReset(int Pin);void OneWireOutByte(int Pin, byte d);byte OneWireInByte(int Pin);void setup() {digitalWrite(TEMP_PIN, LOW);pinMode(TEMP_PIN, INPUT); // sets the digital pin as input (logic 1)pinMode(LeafSensor, INPUT); //defines A2 pin as inputpinMode(10, OUTPUT); //make sure the chip select pin10 is set to outputSerial.begin(9600);while (!Serial) {; // wait for serial port to connect. Needed for Leonardo only}Serial.print("Initializing SD card...");// see if the card is present and can be initialized:if (!SD.begin(chipSelect)) {Serial.println("Card failed, or not present");// don't do anything more:return;}Serial.println("card initialized.");delay(100);Serial.print("Leaf: Soil: Temp:\n");}void loop(){// make a string for assembling the data to log:String dataString = "";LeafState = analogRead(LeafSensor); // reads LeafSensor and stores to LeafState variableLeafState = map(LeafState, 0,1023,0,255);dataString += String(LeafState);dataString += "\t";SoilState = ReadSensorAvg();SoilState = map(SoilState, 0,1023,0,255);dataString += String(SoilState);dataString += "\t";int HighByte, LowByte, TReading, SignBit, Tc_100, Whole, Fract;OneWireReset(TEMP_PIN);OneWireOutByte(TEMP_PIN, 0xcc);OneWireOutByte(TEMP_PIN, 0x44); // perform temperature conversion, strong pullup for one secOneWireReset(TEMP_PIN);OneWireOutByte(TEMP_PIN, 0xcc);OneWireOutByte(TEMP_PIN, 0xbe);LowByte = OneWireInByte(TEMP_PIN);HighByte = OneWireInByte(TEMP_PIN);TReading = (HighByte << 8) + LowByte;SignBit = TReading & 0x8000; // test most sig bitif (SignBit) // negative{TReading = (TReading ^ 0xffff) + 1; // 2's comp}Tc_100 = (6 * TReading) + TReading / 4; // multiply by (100 * 0.0625) or 6.25Whole = Tc_100 / 100; // separate off the whole and fractional portionsFract = Tc_100 % 100;//float Deg = Tc_100 * 0.01;dataString += String(Whole);dataString += ",";dataString += String(Fract);if (SignBit) // If its negative{Serial.print("-");}//LeafState = analogRead(LeafSensor); // reads LeafSensor and stores to LeafState variable//delay(1);//Serial.print(Whole);//Serial.print(".");//if (Fract < 10)//{// Serial.print("0");//}//Serial.print("Temp:");//Serial.print(Fract);//Serial.print("\t");//Serial.print(Deg);//Serial.print("\t");//Serial.print("LeafState:");//Serial.print(LeafState);//Serial.print("\n");// open the file. note that only one file can be open at a time,// so you have to close this one before opening another.File dataFile = SD.open("datalog.txt", FILE_WRITE);// if the file is available, write to it:if (dataFile) {dataFile.println(dataString);dataFile.close();// print to the serial port too:Serial.println(dataString);}// if the file isn't open, pop up an error:else {Serial.println("error opening datalog.txt");}delay(1000); // 5 second datalog delay. Adjust as necessary}void OneWireReset(int Pin) // reset. Should improve to act as a presence pulse{digitalWrite(Pin, LOW);pinMode(Pin, OUTPUT); // bring low for 500 usdelayMicroseconds(500);pinMode(Pin, INPUT);delayMicroseconds(500);}void OneWireOutByte(int Pin, byte d) // output byte d (least sig bit first).{byte n;for(n=8; n!=0; n--){if ((d & 0x01) == 1) // test least sig bit{digitalWrite(Pin, LOW);pinMode(Pin, OUTPUT);delayMicroseconds(5);pinMode(Pin, INPUT);delayMicroseconds(60);}else{digitalWrite(Pin, LOW);pinMode(Pin, OUTPUT);delayMicroseconds(60);pinMode(Pin, INPUT);}d=d>>1; // now the next bit is in the least sig bit position.}}byte OneWireInByte(int Pin) // read byte, least sig byte first{byte d, n, b;for (n=0; n<8; n++){digitalWrite(Pin, LOW);pinMode(Pin, OUTPUT);delayMicroseconds(5);pinMode(Pin, INPUT);delayMicroseconds(5);b = digitalRead(Pin);delayMicroseconds(50);d = (d >> 1) | (b<<7); // shift d to right and insert b in most sig bit position}return(d);}int ReadSensorAvg(){ //subroutine for reading sensor n times and avarageint i=0;int SoilState=0;for (i=0; i < NumReadings; i++){SoilState = SoilState + analogRead(SoilSensor); //read sensor n timesdelay(10); //delay between reads for more stability}SoilState = SoilState / NumReadings; //avaragereturn SoilState;}
Looks like the beginnings of
Looks like the beginnings of a brainstem! Looking awesome!
thx ...
thanks DJUltis... wish me luck.... and patience...
Working on using ThingSpeak service...
I tried to add MRL ThingSpeak service to my datalogging process.. loaded the py script of the service and made necessarry adjustments... tried to poll A2 pin with no luck.. just received a max number and blocked there... later tried a digital poll with D3 pin which is attached to a PIR sensor and the system worked.... couldnt see the realtime graph on the ThingSpeak site at first but later when i stopped the service the graphs were updated to new logged data... system is Worky!!!.. at least to some extent... :)the screen captures are here as you can see... However there is a bug in saving the py scripts in MRL... if you save the script from the py tab unpredicted changes occur during saving... my saved scripts doesnt work.. so i first copy and paste the script to Notepad++ and save it from there ...
WORKY!
Nice Borsaci! It's great you got it working so quickly. I have the bug of "saving" scripts on my list...
I'm excited to see your project develop. DJ and you are making an excellent team.. great to see new ideas and species evolve
THanks ...
thx DJUltis... wish me luck.... :)
Part of tonight datalogging...
Wanted to share with you part of tonight's datalogging results... its very cold outside here at minus degrees and its snowing outside. my Hoya is near the terrace door and a little cold surrounding... after few hrs of datalogging i saw that green led on soil sensor is lit, indicating that the soil is dry... so i watered the plant while datalogging and saw some changes in the log window.
then i tried to increase the surrounding temp blowing with a hot air hair dryer for a while. then stopped the torture on the plant and graphed the log file to post here... you can see the part of the log below with some explanations...
Edit on 13.Dec.2013:
Still working on datalogging and better plant response tracking... Trying to create a good interface between the plant and the robot, i need a reliable and usable sensor setup between them... actually the datalogging process taught me a lot in the last few days but i have to improve sensor and data quality... As you can see from the below datalog session that the plant is giving realtime responses to environmental changes but the sensor data from the resistive sensor attached to the plant leaf is not reliable... the relative plant response can be read clearly but the data structure is not consistent enough to be used in a software... The sensor displays a different scale everytime its powered on, values decaying for a while to stabilize in the end...
So I decided to carry on with a new approach to improve data reliability... I know that plants are good conductives and receptors as living tissue... In order to read in-plant activity I made a different sensor reading in a new way... it is a simple antenna signal meter consisting of a small coil, a Germanium diode and a trimer, small enough to attach to the plant stem... So it now reads the signals more reliable via the same Arduino analog port... will display my results in the next few days...
Interested how your new
Interested how your new plantoid will evolve... Will it use mrl or are you going with straight Arduino sketch only in the v1 / v2 version?
Mechaphytum Animus V1...
This version runs with std Arduino sketch which I wrote but will be adding MRL into the project as soon as I add the camera and wifi... Until now I havent worked on the Plantoid service and dont know how it works and what it does... May have some questions to you while adding MRL to the Plantoid...
Here is my controlling Arduino sketch for V1:
Borsaci, thanks for the
Borsaci, thanks for the update !
It is getting more complicated ! TURNTABLE !!! 75 rpm ? How are you managing such slow turning?
Does music make a difference in mood ?
Mechaphytum Animus V1...
Thx Grog,
I am still working on her... The turntable is the reason that I borrowed the chassis from an old stereo rack lying around... I replaced the main axis with a hollow metal pipe through which I managed to pass the 8 necessary wires for connections between the plant and the processor... I also used the belt system to slow down the motion of the tracking mechanism... Nowadays I am working on the watering system which I am designing... I am using the air pumping part of a faulty blood pressure meter from my garbage bin for the purpose... It will be an insulated close enclosure for safety purposes... We all know that water and electronics together is not a good mix... :)
I hope music makes a difference in the mood of the plant.... Hehe... :)