The idea of my project is making a smoke and CO detector with different alarm options such as sound, light, and bird movement to make an attention in cases of high levels of smoke and CO levels.
CO is one of the most harmful gases for humans. and with the increasing of different source that produce it. We need all the time to reminder to help us to notice the changes in the surrounding in order to keeping the humans safe.
The inspiration came from two sources, the first one was a research project that I had been working on it during my research work. The second one is from a previous student here.
1. LaserWorkV6 Application which used to prepare the design before cutting process.
2. Fusion 360 which used for sketching the enclosure.
3. Cura to make the bird.
4. Grabcad to use the use the electronic component on it and joint them with my design.
I started with sketching the right and left sides with one t - slot in each side and two tabs below and two uppers. Also, I made two rectangles in the ends of each side to fit with the front and back sides with it.
After I finished the two sides, I use the project tool to open some holes for the component such as the Arduino and adaptor holes.
The second thing I had been made is the front and back parts with the same way of right and front and I also open 2 rectangles in each end of the two sides to make a joint with the right and left parts and also 2 tabs (one above and one below to fit with the top part and base part).
Top was very easy to do as I used the project tool and made all tabs on the surface, and I then extrude it. After I finished this part, I bring the component dimensions (LCD, LEDs, Gas sensor) and make holes for each component according to the dimensions of the project components.
Here I only used the project tool to determine the tabs positions in the bottom part and then I extruded it.
After all of that I had been joined all parts together and the electronic components.
The locally machine which called El Malky ML149 CO2 Laser Cutter for cutting the front frame of glasses.
Plywood 3mm sheet that used in the cutting process.
1. LaserWorkV6 Application which used to prepare the design before cutting process.
Click to Green circular button to turn on the machine.
From the PC connected to machine open Laserwork software and import my file.
Adjust the power and speed according to required conditions.
Click download to be able to upload the file to the machine.
From machine, click file and then I choose my file name.
Move the machine nozzle to determine the dimensions of the desirable design and reduce the wood waste.
Fix the plywood well to make sure that the nozzle will cut as design setting.
Click frame, until you determined the area of cutting.
Turn on the cooling bottom.
Close the door of the machine and click start.
Prusa i3 MK3 Printer which used for printing the bird.
PLA Filament which is the polymer which consist of the required design.
1.UltiMaker Cura Program that used to prepare the design arms dimension and determine the requied time and amount of filament that will be used before printing.
Upload the G - code on the memory of the printer.
Insert the memory in the printer.
Clean the surface of printer with Alcohol before start.
Choose the file of my design and click start.
After printing, remove the support to get the required product.
1.Arduino uno board:
The board used for the connections of breadboard containing wires and the remaining wires of the components.
3. CO and smoke sensor:
The sensor is detecting the presence of smoke and CO (input)
5.Resistor:
The 220 ohm resistor used to reduce the flow of current in order to give the required amount of electric current for each component.
7. Arduino Cable:
The cable used to connect the Arduino uno board with PC to allow the board programming.
9. Bottom:
I used bottom to make the circuit turn on and turn off. (input)
2. Breadboard:
This board used to connect the components with the Arduino board in order to reduce the number of used wires.
4. LED:
LED used to be green at the save mode and when the CO or smoke level increase green LED will be turn off and the red one will be turned on. (output)
6. Jumper wires:
Those wires used for connections between component, breadboard, and Arduino board.
8. Buzzer:
The buzzer to give sound with the increasing level of smoke and CO. (output)
10. LCD
I used LCD to print the mode either save or not. (output)
According to the circuit, I used 2 LEDs (one is red and the other is green. I connected with two resistors (220 ohm) to reduce the current reaches to them. And I connect the positive of the LEDs as the following:
Red: Arduino pin 7
Green: Arduino pin 8
I used LCD with 4 pins, and I connected the VCC with the positive and the ground by ground. and the SDA with analog pin A4 and the SCL with the analog pin A5.
For servo motor I connected the positive with the positive of the breadboard and the negative with ground and the final with pin 9 in Arduino.
For buzzer, I connected the negative with pin 6 in Arduino and finally the positive with the positive of the breadboard.
I used also a gas and CO sensor and connect the positive with the positive of the breadboard, and ground with ground and the final pin with analong A0 in the arduino board.
My power source will be 9 V adaptor. I used it according to the used component on my circuit and how much current each component need.
I need 5 V to work the servo motor, and the other components will need also different volts, So I decided to use the 9 V adaptor in order to be able to give each component the required volt to work.
The code here is responsible for the detection process, we started with define the inputs and outputs of the circuit. At the first I tested the sensor, and I determined the threshold of detection process. then I made some options, when the detected value greater than the threshold, the light turns to red, buzzer gives alarm, screen write a warning message and finally the bird change its orientation.
If the value of detection less than threshold, the green light will be high, screen write save mode, and the bird return to its starting position.
I started with jointing the top and sides. the circuit was ready to be hold in the enclosure. I started with LCD and then I put the sensor and LEDs in their metal pockets.
After I fix those components in the box, I tried to put the buzzer in its hole. But it needs a lot of extra wires which was impossible to add additional wires due to the very narrow area.
After this I started to put the top arduino and breadboard. But here was the problem. The additional wires i used for LCD to be long and for LEDs. It made me suffer to be able to fit the box with all components.
Finally, I become able to put the bottom and take the demo video as shown. But really it wasn't easy at all.
The problem appeared when I was starting the testing circuit actions, I tried it for about 8 hours continuously to make sure that the circuit is work. I tried a lot to fix the wires to take the demo video. The all problems lie in the small area of the enclosure.
At the end and as shown in the video, the device is turned on and the green light is high, LCD with sentence said, "Save Mode" and the bird in the right position. when I close the smoke of the cardboard, the light become red, buzzer give alarm and LCD written a new sentence "CO detected" and finally bird change his orientaion.
I faced mainly two challenges in this project:
The first one is the bird that considers as an indication tool is printed with very small dimensions and thickness, so my instructor Eman advise me to reprint it in the time of adding extra features.
The second one was when I add all component in my project in the enclosure, I found a huge difficulty to be able to fit them. So, when I add the extra feature, I will fabricate the box again with dimensions larger than previous one to be suitable more for the number of components.
According to the circuit troubleshooting I faced some problems as some wires is get out from the breadboard and it takes a long time to check the whole circuit in each time and determine the wire belongs to which component.
For the circuit programing, when I integrated the circuits together, some codes didn't work such as servo code. But Mego and Eman helps in, and the problem was the definition of the servo in my circuit.
I will do two things:
Reprint the bird with thickness more suitable to my enclosure.
fabricated the sides of the enclosure with much length to contain the component freely.