Recently I designed a High voltage circuit based on AVR microcontroller. I need your opinion or any suggestion or improvements I could add to the presented project.
Microcontroller is responisible for giving appropriate PWM pulse (of known frequency) to the MOSFET transistor. Pwm signal from the uC goes to the optocoupler (18V) and then to a buffer (18V). Circuit has two main sources one is 5V for uC and second which would be 20V from transformer (This gives me 18V for the gate of MOSFET and optocoupler and buffer).
Additionally I added keypad, LCD, and Buzzer for better controlling circuit.
Below link gives overall idea what are ignition coil driver circuits:
Anyway I have few questions regarding circuit:
1. Do I need necessarily use optocoupler? I have two power sources and I wonder can spikes from the ignition coils can do much harm to the uC if they go through common ground. Or asking the same question in different way - does common ground in this case is dangerous to the microcontroller?
Are 3.6kOhm ok in optocouplers? It gives 5mA CE current according to my calculations.
2. Could you explain me what exactly do ER and CS pins in IR2121 device and how should I use them?
Can I leave them unused?
3. Can buzzer be supplied by 18V?
4. The most important question do all components fit together well?
5. what would you improve in the design...
6. Buffer gives 2 A on output isnt it more than Enough for the Mosfet? I mean such high current can be a trade off for the speed of the Buffer. (higher delays)
7. I set 30mA for the input of optocouplers diodes. Atmega 8 gives me max 40 mA so I think uC withstand Anyway datasheet doesn`t say anything about optimal imput current of optocouplers. Isn`t it 10mA?
Below I am attaching diagram of the circuit and links to datasheets of used devices:
1. MOSFET http://www.audiolabga.com/pdf/17N80C3.pdf
2. Optocoupler http://www.tme.eu/dok/06_optoelektronika/4n25.pdf
3. Buffer http://www.tme.eu/dok/04_uklady_scalone/ir2121.pdf