Hackster is hosting Impact Spotlights: Smart Home. Watch the stream live on Thursday!Hackster is hosting Impact Spotlights: Smart Home. Stream on Thursday!
SetNFix
Created June 6, 2019 © CERN-OHL

Arduino Circuit Breaker

Circuit breaker to protect motor from overload

IntermediateFull instructions provided129
Arduino Circuit Breaker

Things used in this project

Hardware components

Arduino UNO
Arduino UNO
×1
SparkFun Low Current Sensor Breakout - ACS712
SparkFun Low Current Sensor Breakout - ACS712
×1
Power Relay, SPDT
Power Relay, SPDT
×1
Resistor 1k ohm
Resistor 1k ohm
×1
1N4007 – High Voltage, High Current Rated Diode
1N4007 – High Voltage, High Current Rated Diode
×1
General Purpose Transistor NPN
General Purpose Transistor NPN
2N2222
×1

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)
Solder Wire, Lead Free
Solder Wire, Lead Free
Mastech MS8217 Autorange Digital Multimeter
Digilent Mastech MS8217 Autorange Digital Multimeter

Story

Read more

Schematics

Arduino Circuit Breaker

Code

Arduino Circuit Breaker

Arduino
Download the code
int Crnt = A0; 
float voltage;
int anval;
int relay = 12;
float amps;

void setup() {
  // put your setup code here, to run once:
  Serial.begin(9600);
  pinMode(Crnt,INPUT);
pinMode(relay,OUTPUT);
digitalWrite(relay,HIGH);
}

void loop() {
  // put your main code here, to run repeatedly:
anval = analogRead(Crnt);
voltage = (anval/1024.0)*5000;


  amps=((voltage-2490)/66);
  Serial.print("amps : ");
 Serial.println(amps);
  delay(150);
if (amps < 0){amps =amps*-1;}

  if (amps >.8){// When hold the motor, it takes a current more than 800mA.
    digitalWrite(relay,LOW);delay(1000);}

}

Credits

SetNFix
17 projects • 35 followers
I am an accountant in profession but, I would more prefer to work with electronics based innovations.
Contact

Comments

Please log in or sign up to comment.