Hello people, I've been strolling around the DIY scene for quite a while now and also did some small microcontroller stuffs. Some days ago friend of mine asked me if I could build a programmable firework ignition controller for him. I thought this is a very good project/reason to build something that is actually usefull :P.
Ofcouse the first thing I do is online research about similiar projects. There are a few but not quite what I had in mind how I would do it. Also I've found some solution and ideas here on the arduino forum. The following are my thoughts and ideas about how I would do it and hope you can point out mistakes and bad ideas as well as give me some of your ideas! ;D
- A controller that sends digital signal to about 20-30 channels connected to a relais or igniter (My friend says those channels only needs to source/sink very low current each, no further specifications yet)
- There should be a LCD and buttons to toggle through the channels and set a delay in half second steps
- A "secure" main switch or a key switch would be nice.
- the timing should be accurate enough to keep the fault tollerance under 1s when the last channel is ignited 15minutes after countdown starts (this should be no problem I guess)
- As this is the first version of the controller, I would like to keep it as simple and use as many ready to use components and boards as possible. So I will probably use an phi-2-shield (Phi-2 shield | Liudr's Blog). It has:
- 20x4 LCD, with backlight
- RTC, EEPROM
- there is a library for easy menu creation and navigation, as far as I understand
- I will put it on top of an arduino mega 2560, so I won't have to worry about pins and memory.
- behind the 30 (or what ever number of channels) digital out put pins I will put the popular darlington arrays ULN2803A that we all love in projects with steppermotors. This will ensure that the digital pins of the mega 2560 doesn't have to sink/source much current AND also it keeps the pins save from possible backwards flowing currents, as I don't know yet what kind of relais or igniter he will hook up to the channel I provide. The ULN2803A are cheap and I don't see any reason not to use them, or using transistors instead.
- In my opinion the ULN2803A darlington arrays will provide an exellent way to hookup the secure/key swtich: as the ULN2803A sinks all of it's outgoing pins to a common ground, I could just put this security switch between. So if this switch is not closed, the Arduino mega 2560 can still send out high (5V) signals to the darlington array, but nothing will happen on the outgoing side of it ---> no unwanted ignition.
- I have little experience with circuit design, so I'm not sure if I should include debouncing capacitors at the output pins of the darlington array or at the digital output pins of the arduino to eliminate effects of floating pins at start or static discharge of some sorts when I turn the keylock to prevent accidental ignitions. The effects of such little things could be dessasterous...
I'm looking for the simplest solution for the first version of the controller. My plan is to create a array with the length of the channelcount, it will store the second/milisecond of the ignition for that channel counting from the start time 't0', this t0 is set via millis() when the START button is pressed. There will be a function that checks if the next scheduled ignition time is reached, this function is beeing triggered by a timer that is set at every 100ms. That should do the job right? This scheduled time array can be stored on the EEPROM of the phi-2 shield, so a powerloss would be no problem.
Using the buzzer that is already on the board I can create a beep for each ignition (for demo purposes, when the keylog is not turned) and also some signals to alarm the user that the countdown has begun.
For the first firmware version, I think the RTC will not be used. As the start of the programm will be manually triggered with a button. Maybe I will just include a clock function for the fun of it.
I will try to provide schematics as soon as I have confirmation that my thoughts above are not terribly wrong :D. And I will also try to update infos about my little project in this topic.
Thank you in advance for your help!