Steelmesh
Newbie level 3
I am attempting to build a 35amp PWM motor controller for a brushed DC motor application (electric bike).
I successfully sizzled a n-fet for first test. I was able to spin up the motor, then it burned out and stuck on. After that, I hooked up the current sensor, and successfully sizzled the IR2110-2 driver, it was cooking on top.
I picked up 1-4 amps during the last test, spun it up lightly a few times, then throttled it back down to 0%. After a couple seconds, I noticed a funky smell and something boiling on top of the IR2110.
Here is the circuit...any ideas why I smoked it?
The OpAmp is really the ACS756 current sensor:
**broken link removed**
**broken link removed**
Arduino Code
_____________________________________________
__________________________________________________ _-
I successfully sizzled a n-fet for first test. I was able to spin up the motor, then it burned out and stuck on. After that, I hooked up the current sensor, and successfully sizzled the IR2110-2 driver, it was cooking on top.
I picked up 1-4 amps during the last test, spun it up lightly a few times, then throttled it back down to 0%. After a couple seconds, I noticed a funky smell and something boiling on top of the IR2110.
Here is the circuit...any ideas why I smoked it?
The OpAmp is really the ACS756 current sensor:
**broken link removed**
**broken link removed**
Arduino Code
_____________________________________________
Code C - [expand] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 // Alpha Motor Control program written by Steelmesh // IR2110 Driver // 75321 N-mosfet // ACS756 hall effect current sensor, two 0.1uf caps for VIN/VOUT // Hall Sensor pins: (1)VCC- 5v Arduino, (2)GND- Ground Arduino, (3)VIOUT- Analog Input Arduino, (4) from power source, (5) to load int LIN = 3; //Low PWM to IR2110 LIN int hallIn = 2; //signal from Hall Sensor int ampLimit = 10; //manual input int sensorCal = 511; //manual input int sensorSpec = 40; //40 mV per Amp void setup() { Serial.begin(9600); } void loop() { int throttleIn = analogRead(4); //Read throttle, declare integers int pulse = constrain(throttleIn, 200, 800); pulse = map(pulse, 200, 800, 0, 254); int ampRead = analogRead(hallIn); //Read hall sensor output ampRead = constrain(ampRead, sensorCal, 1023); //constrain to manual sensor calibration int actualAmp = ampRead - sensorCal; //Declare new int for conversion actualAmp = (actualAmp * 4.9) / sensorSpec; //4.9 * Analog signal =~ mV, divide by example: "ACS756 spec: 40mV/1A" int hallMv = analogRead(hallIn) * 4.9; //debugging to view mV Serial.print("Pulse: "); Serial.print(pulse); Serial.print(" "); Serial.print("Amps: "); Serial.print(actualAmp); Serial.print(" "); Serial.print("Hall mv: "); Serial.print(hallMv); Serial.println(""); if (actualAmp > ampLimit) //current limiter function { pulse = 0; //turn off via pulse analogWrite(LIN, pulse); Serial.println("OVERLIMIT!!"); delay(100); } else { analogWrite(LIN, pulse); //Within 'if' statement to ensure if actualAmp > ampLimit, it won't command analogWrite(throttle function) } delay(100); //Serial.print sake }
__________________________________________________ _-
Last edited by a moderator: