Resetting Arduino via Code

I’m imagining a circumstance where I might want my arduino to reset itself if a condition occurs.  Right now the program is alerting me of this condition, then I have to go and press the reset button.  Not hard, but annoying.

The reset pin is how I’ve wired an external reset button:  a momentary switch grounds the reset pin (making it LOW), and the board resets.  I think I can create the same thing with code

Here’s what I’ll use:

int led = 13;//pin 13 as OUTPUT LED pin
int resetPin = 12;

I’ll connect my reset pin to a digital pin.  Then the code will use a digital.write to bring that pin low, resetting the board.  Here’s a fritzing.org diagram:

reset arduino without manual button

Follow and Like Us:

Throwback: My Electronics Box from Fourth Grade

During my last trip home, this mammoth had been uncovered in our garage. I brought it home with me and just decided to pull it out.

Going through the drawers I found ruptured batteries, parts from all kinds of electronics I gutted, and even my windshield wiper glasses! This box represents many memories, countless hours of creating, and an early indicator of my attraction to electronics.
electronics tinker box

Follow and Like Us:

Plant Hospital

cucumber revived in nutrient solution

When I first transferred my plants into the NFT rails, most of them shot roots down and found the nutrient water. But not all of them.  I poured cups of the nutrient water over these ones several times each day until their roots were long enough.  This worked well except for two cucumber starts.  I …

My Data Table

My Smart Garden Data
Displaying 21-40 of 35 « 1 2
Time Air Temp Humidity WaterTemp Sun Rain pH DB Moisture Alarm?
2016-06-07 10:29:09 1c003a001647353236343033 0 0
2016-06-07 10:40:04 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:41:01 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:42:01 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:43:01 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:44:01 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:45:02 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:46:02 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:47:01 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:48:02 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:49:01 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-07 10:50:02 /mygarden/particleadd.php?data=temp1=85&hum=80&w1=70&w2=72&sun=95&alarm=0&ph=7.5&wet=0&id=1c003a001647353236343033 1c003a001647353236343033 85 80 70 72 95 0
2016-06-19 20:11:45 /mygarden/trigger.php?data=t=49&id=102 102 0 0
2016-06-19 20:13:32 /mygarden/trigger.php?data=Getting low 0 0
2016-06-19 20:13:34 /mygarden/trigger.php?data=Getting low 0 0
Displaying 21-40 of 35 « 1 2
Follow and Like Us:

Internet of Gardening Arduino Controller is nearly ready

When it gets dark, I move into my office where I’ve been building my arduino garden controller.  I’m nearly finished!

I started creating a wiring diagram with fritzing.org in case I ever accidentally mess something up.  I don’t want to lose my progress!

Internet of Farming arduino garden system

Follow and Like Us:

Root growth after 1 week on NFT rails

Check out this progress!  Maybe my wife is right.  Plants really do want to live!

root development aquaponic garden NFT

Follow and Like Us: