harry88
- #1
With my busy schedule I'm always forgetting to dose the Excel my tank needs so I decided to invent a solution! I've made a Bluetooth controlled Arduino dosing system. The way it works is you set the time on the Kindle that you would like to dose every day and every day at that time the kindle sends a signal to the Arduino telling it to dose for a certain number of seconds set in the Arduino code. I chose to have the Arduino handle the dosing duration time for safety measures in case for whatever reason the Bluetooth failed. I plan on buying one of cheap dosing pumps off Amazon to handle the dosing. I eventually plan to add in more sensors such as temperature and PH so real time data about the aquarium can be displayed on the Kindle. What I love about this is there is so much room to expand it and add more things such as more dosing pumps and sensors and etc. The Bluetooth controller is a JY-MCU and I'm using an Arduino Nano. The relay I'm using is just a Paralax single relay board I had laying around. The reason I didn't solder a normal relay is is really only just because I didn't have the space and I like the screw Terminals on the Paralax relay. I plan on adding this all into a Radio-shack project box with the dosing pump mounted on the box as well.

The code is super simple and basic. When the Arduino receives "1" from the kindle via Bluetooth it turns on the pump for the delay amount. I might add a potentiometer to control the delay amount to allow calibration without reprogramming. I made the Android app in MIT Appinventor. The Arduino code is as follows.
int pumpPin = 9;
int state = 0;
int flag = 0;
void setup() {
pinMode(pumpPin, OUTPUT);
digitalWrite(pumpPin, LOW);
Serial.begin(9600);
}
void loop() {
if(Serial.available() > 0){
state = Serial.read();
flag=0;
}
if (state == '1') {
digitalWrite(pumpPin, HIGH);
delay(5000);
digitalWrite(pumpPin,LOW);
if(flag == 0){
state = 0;
flag = 1;
}
}
}
Here is also the "Schematic" I made for the wiring (sorry for the bad drawing.)
That's all for now hope you enjoyed I will be happy to answer any questions.
(Also not sure if this is in the right place)


The code is super simple and basic. When the Arduino receives "1" from the kindle via Bluetooth it turns on the pump for the delay amount. I might add a potentiometer to control the delay amount to allow calibration without reprogramming. I made the Android app in MIT Appinventor. The Arduino code is as follows.
int pumpPin = 9;
int state = 0;
int flag = 0;
void setup() {
pinMode(pumpPin, OUTPUT);
digitalWrite(pumpPin, LOW);
Serial.begin(9600);
}
void loop() {
if(Serial.available() > 0){
state = Serial.read();
flag=0;
}
if (state == '1') {
digitalWrite(pumpPin, HIGH);
delay(5000);
digitalWrite(pumpPin,LOW);
if(flag == 0){
state = 0;
flag = 1;
}
}
}
Here is also the "Schematic" I made for the wiring (sorry for the bad drawing.)

That's all for now hope you enjoyed I will be happy to answer any questions.
(Also not sure if this is in the right place)