Hi,
I am working to learn FC11, and I am stuck on a project that involves a 7-segment Click display from Mikroe connected to an Arduino Nano 328 at 115200 baud. The schematic involves the following:
- An LED (that might blink or send a visual alarm)
- A buzzer (which sends a buzz signal when the time has elapsed)
- Two microswitches (one for setting the time from various options, and the other for resetting the time and starting over)
The challenges I experienced with the display from Mikroe were related to the pre-wiring. Therefore, I had to manually try all 256 addresses and observe the results for each, which is reflected in the enclosed address mapping.
Now I'm stuck in the flowcharts, trying to figure out how to make the timer count from 60 minutes to 0, in the following pre-defined timer scenarios, which can be configured via the SET microswitch:
1 minute
2 minutes
3 minutes
4 minutes
5 minutes
6 minutes
7 minutes
8 minutes
9 minutes
10 minutes
15 minutes
20 minutes
25 minutes (Pomodoro cycle)
30 minutes
45 minutes
60 minutes
Note that there are 16x options for timing, and on the main PCB, I can also use 16x WS2812 RGB LEDs as a future alternative/playground.
I want to make the flowcharts as simple as possible, but I'm unsure how to avoid repetition in terms of how constants/variables/parameters are defined.
Can someone with a bit more experience please help me make this device count, respond to the push buttons, and display the remaining time? I also do not know where or how to set those 16 predefined minutes, and how to show the elapsing time on the display. For your reference, I have enclosed the code for my current project at a very early stage. (ignore the simulation of the LED display, as the addresses are different due to the wiring of the 7-segment Click from Mikroe)
Regards,
Andreas
Kitchen Timer project using MikroElektronika 7seg Click with 74HC595
-
andeug
- Posts: 45
- http://meble-kuchenne.info.pl
- Joined: Thu Jan 07, 2021 1:42 pm
- Location: Stockholm (SE)
- Has thanked: 16 times
- Been thanked: 2 times
-
chipfryer27
- Valued Contributor
- Posts: 1761
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 390 times
- Been thanked: 598 times
Re: Kitchen Timer project using MikroElektronika 7seg Click with 74HC595
Hi
Still travelling so I cannot be of specific help but most of all you are asking is most likely covered in the wiki. Most components have an explanation plus examples and I think there is an example of a counter somewhere.
Sorry I can't provide a specific link.
Do take a look at the 7-segment LED examples though.
Regards
Still travelling so I cannot be of specific help but most of all you are asking is most likely covered in the wiki. Most components have an explanation plus examples and I think there is an example of a counter somewhere.
Sorry I can't provide a specific link.
Do take a look at the 7-segment LED examples though.
Regards