I'm always straggling with my sleep, I don't sleep well and have insomnia problems, so when I make some research about smart projects I found this Lumos lamp project
It's a lamp that turns on at night with a dim warm light to let you sleep in a relaxing way.
I like the idea but I want more, what if it had also relaxing music, even a clock so if you wake up overnight or in the morning you know the time and date without grabbing your mobile and bothering you to force wake up.
Fusion 360 to make the sketches and the whole design
coral draw to make some adjust to the flexible pattern
So it was not suitable to call it a Lumos without any harry potter design, so I choose to make it like the deathly hallows it's one of the famous symbols in HP world and start to make some sketches.
First I made a triangle for the base and offset it to make the outer and the inner, then a circle that doesn't touch the inner triangle, then a square in the middle and trim the lines to make the needed shape
then make the joints and the t-slot hole (make it one time and use circle pattern and mirror to make it symmetric and adjusted)
then I make some holes for the components to easily mount it (used project and dimension schematic for some parts)
then I copyed the base to doing the face exactle like it, but with a little diffrent cause i want to make an arylic parts side by side with the wood (explaine this in next step)
I noticed that their is some problems with grab cad parts dimensions so I grab the dimensions schematic from here
at last I make 3 copies to be easy to export and cut it with laser cad
then I make the inner sides and the orange dashed lines that I draw in the top and base sides helped me to know the dimension of these parts
same things in the outer sides and make a holes for the switches, power and USB port
now it's time to import a mesh pattern to make the circle sides flexible so I can make it around like circle
you can insert it as DXF from insert menu
once it inserted
you can but it in your design and make this sides flexible
then I extruded the parts and import the STL components from grab cad
at last, I can now joint all the parts together and make the 3d part to imagine it and make sure that all is perfectly fit before the fabrication process
Laser cad for review send design to machine
2 Sheets of 3.2mm MDF
1 Sheet of 3mm clear acrylic
Laser cutter machine to cut and engrave MDF and Acrylic
First thing in this process I combine all the DXF files in laser cad in 2 squares (60*40 cm) to fit the sheet, used 2 sheets of MDF and the cut parameters were
70 power and 18 speed
then put the acrylic also and make it engrave with cut to make the clear acrylic frosted with the presented parameters
put the MDF sheet, make sure of focus, download the file to the laser cut machine and start it
same thing to the acrylic
let me told you a life hack with the acrylic, after engraving it use an old brush and soap to clean it will from the powder that make it some parts cloudy than other 🫣
and I can't resist to make some art and stain to it so I decided to glue some wood veneer to the top and give the outer body some brown wood stain to be more artistic 🥰
I used Arduino UNO to be the MASTER MIND and control the whole circuit and its functions
2 meters of warm 5050 LED strip (that model is dimmable)
L298N motor drive, it can power motors in 12v DC, adjust speed and direction
but in my case I will use LED strip instead of motor and control it's brightness through speed control pin
LDR module to sense the light and which used to control the LED
dfplayer mini and SD card to control the music and store it
speaker
HC-05 Bluetooth module to control the music
RTC ds3231 to know the real time and date
16*2 LCD with I2C
2 ON/OFF switches
female USB to connected to the Arduino
female micro USB connected to LDR
USB cable to connect the Arduino with the LDR
I used fritzing to explain the circuit
will go deep in a second 😅
First, let's powered up this circuit, grab a 12v adaptor the GND will go to the breadboard and every GND goes in the same line to be united
the VCC goes into the motor drive and the regulator, then the regulator goes to the breadboard to power every component that uses 5v even the Arduino
then let's connect the LED strip to the motor drive (beware of the VCC and ground you can use a multimeter to know the correct way), take the speed control pin in the motor driver and one of the direction pins, and connect them to Arduino to control the LED state and brightness.
put an on-off switch to control the LED from the code, now let's connect the dfplayer mini and the speaker you can find its diagram here to connect it easily, and as well we can connect the HC-05 following this diagram.
now let's explain the RTC and LCD cause it's the same connection, they take VCC and GND as any component do, then they take the SCL and SDA from the Arduino pins last 2 pins on the left side (A5 is SCL, A4 is SDA) and also the first 2 pins on the right side (the first one is SCL, the second one is SDA) and all is done you have the circuit.
I powered the whole circuit with 12V DC adapter cause the LED require 12V DC
then connected the 12V with L7805 regulator to put down the 12V to 5V so I can powered the Arduino and the components
3x1k resistors to put down the 5v to 3V to use it in Rx Bluetooth module
Basically I used Arduino ide to write code and upload it to the board
at first I included all the libraries needed, DFplayer, RTC, and liquid crystal
then identify pin 2 and 3 to be the Rx and Tx for DFplayer, then the the RTC and days of the week to easily call them down in the code, and but char variable called incoming data to but the serial read in it, and then identify the pins and give them a name to handle them easily in the code
Here i the void setup I identified the serial communicaton and player volume and LCD, then but a condition to begin the RTC and adjust it's time and date to the laptop time
then at last identify the pins mode with witch one is input or output
that's the first code LDR and LED strip dim code, and in briefly, if the switch is high state then read the LDR analog signal and compare it with a given value if it larger it's mean that it's dark so dim the led with a little amount of brightness and as it get's darker make it brighter
and if one of these conditions not happened then turn off the LED
this is the clock and date code and the printed values in the LCD
that's the day of the week and the month
that's the day
and those're the clock
the music code was a little bit tricky you must use only if condition, if you used else it will go out the loop and not come back until you restarted the device (problem with the DFplayer module not the code) so you must be specific and tell it if you write a given number play this.
Of course, before attaching the components to the body I test it and test the code with all functions working together and at some point all works well, let me show one by one and how I attached the components to the body and finish the project.
the ldr and LED circuit
the speaker and DFplayer circuit
Now let's collect all the components and parts together and test all them to finally get it done 🫡
After checking the fabrication and checking that the holes fit from one part to another and that the components fit into the body I began with mounting the components to the body, starting with Arduino and speaker to the motor drive and the power female and switch
(note: every component is can be smoothly taken off from the enclosure)
then I mounted the LCD to the top with 4 screws (the acrylic is combine with the MDF through the LCD so it's not glued and can be easily separated)
I also made this cute little box to attach it to any nearby window and put inside it the LDR to sense the outdoor light and micro USB female to connect it to the circuit
Now after combining everything together and even making a leather hang it's time to test the functions and make sure all is done well
Actually the one who helped me a lot was Menna Asker our instructor, every time I broke or want advise I run to her and ask (and when asking my questions is not understood really it will be like : Hi can I powered the circuit from a potato), so thanks to her she was patient enough to understand and help me
Here is another thing, when you finish your project a little bit earlier than others, you must be around to help your pears, and they were very kind to me so I must be to them too 🥰
in last 2 sessions (24/25 sep) I went to the lab but didn't have to much to do, so any one who want any help from design to code even fabrication, we was like a big family that time and every one help the other
In the design it was so difficult to know the circle side size cause and cannot fold it in the 3d shapes
so I do some mathematics and know the circumference of the circle and divided the trim parts from the middle and it fit well
the second problem was the regulator, it can be a catastrophe cause it was heat a lot and it was in a tiny space, its screw was heated up and even when I touch it heart me up
so I grab some metal scrab sheet and make it some sort of heat sink
I recommended that if you will connect that regulator buy a heat sink with it
the heat had dropped down at least 50% with this scrab heat sink
I want to save some space, so I disassemble the power lines from the breadboard and use it direct
I want to be more accurate so I attatch the LDR to my window and wait tell 7Am to grab the best read to put it in the code 🥲
The alarm and the mobile application will be the most attractive features to have so I think if I had more time I will learn how to make mobile app and alarm