Digital clock using ATmega1284P, 4x 7-digits + DP, RTC and temperature

Use this section to discuss your embedded Flowcode projects.
Post Reply
andeug
Posts: 91
http://meble-kuchenne.info.pl
Joined: Thu Jan 07, 2021 1:42 pm
Location: Stockholm (SE)
Has thanked: 30 times
Been thanked: 4 times

Flowcode v11 Digital clock using ATmega1284P, 4x 7-digits + DP, RTC and temperature

Post by andeug »

Hi,


I have started today to work on a digital clock project, to which I am posting its schematic in KiCad below:
Screenshot 2026-02-22 190503.png
Screenshot 2026-02-22 190503.png (210.67 KiB) Viewed 1626 times
The clock has a DP for a comma when indicating the temperature; L1L2 indicate the blinking seconds; and L3 indicates the degrees in Celsius.
The display I am using is a TDCR1050M from Vishay, which is widely available, and as a shift register, I am using TPIC6B595, which, in my schematic, makes sense for a future need or possible upgrade to a larger display with more LEDs per segment.

The clock is programmable via the ATMEL-ICE programmer, via the AVR-ISP interface.

Below, I am enclosing the basic FC file with which I have started my project - is it correct, or do you have any suggestions for improvement?
Digital clock 0.1.fcfx
(39.9 KiB) Downloaded 218 times
Is this the way I should represent my display's configuration with a common anode and one shift register?
Screenshot 2026-02-22 191858.png
Screenshot 2026-02-22 191858.png (242.25 KiB) Viewed 1626 times

Regards,
Andreas
FC11 Professional + ARD + AVR + ARM license + Matrix TSL E-blocks2 boards
Mikroe Click boards + Arduino Nano/Uno Click Shield

chipfryer27
Valued Contributor
Posts: 2013
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 442 times
Been thanked: 661 times

Re: Digital clock using ATmega1284P, 4x 7-digits + DP, RTC and temperature

Post by chipfryer27 »

Hi

With no code it's hard to say.

However, you are probably aware that although the display will not simulate correctly it could still be very informative to indicate what is happening. The LEDs you are using to illustrate CA1 etc are active high in your chart, but in reality according to your schematic will be active low.

Your actual display isn't connected to any port at all, instead to a shift-register, so having them connected to two chip pins may lead to confusion. However "clocking" a value to them would be indicative of sending to a shift-register so that point may be moot.

If simulating using the chart I'd imagine that ALL digits would display the digit irrespective of position, but your CA1 LED etc would illustrate what digit was actually illuminated.

Share your code as you go and I'm sure the forum will help where we can.

Regards

andeug
Posts: 91
Joined: Thu Jan 07, 2021 1:42 pm
Location: Stockholm (SE)
Has thanked: 30 times
Been thanked: 4 times

Re: Digital clock using ATmega1284P, 4x 7-digits + DP, RTC and temperature

Post by andeug »

Hi,

I have abandoned this project because I will build it with an Arduino Uno and a TPIC6B595 display component, for which I received help here on the forum:

viewtopic.php?t=3636

I was not able to program my board using the Atmel ICE programmer, so I went back to the Arduino Uno, which has an on-board programmer. :-)

Andreas
FC11 Professional + ARD + AVR + ARM license + Matrix TSL E-blocks2 boards
Mikroe Click boards + Arduino Nano/Uno Click Shield

mnfisher
Valued Contributor
Posts: 2073
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 162 times
Been thanked: 958 times

Re: Digital clock using ATmega1284P, 4x 7-digits + DP, RTC and temperature

Post by mnfisher »

The ATMega328p should be quite capable...

However, it should be possible to use the ICE programmer with Flowcode. I don't have one to try - but I've used other programmers, and it's fairly easy to set up the necessary to get them to work. What (if anything) have you tried thus far?

Martin

andeug
Posts: 91
Joined: Thu Jan 07, 2021 1:42 pm
Location: Stockholm (SE)
Has thanked: 30 times
Been thanked: 4 times

Re: Digital clock using ATmega1284P, 4x 7-digits + DP, RTC and temperature

Post by andeug »

ATmega328P should be enough for my project, while ATmega1284P might be overkill for a digital clock. :)

I tried using the Atmel ICE programmer with Flowcode, but I couldn't program the microcontroller on the breadboard I built. I went back and installed Microchip Studio, then MPLAB... then Visual Studio Code... and got lost in tools.

I encountered strange errors in FC and left it behind. I prefer something less customizable that works... and that's Arduino Nano/Uno.

The good part about the Arduino Nano/Uno is that it works in my Parallels Desktop virtual machine, since I am a Mac user, and my Flowcode 11 installation runs occasionally in a virtualized environment on Apple M5. I wish Flowcode were natively supported on Mac, but I understand that macOS is not on the development roadmap...
FC11 Professional + ARD + AVR + ARM license + Matrix TSL E-blocks2 boards
Mikroe Click boards + Arduino Nano/Uno Click Shield

mnfisher
Valued Contributor
Posts: 2073
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 162 times
Been thanked: 958 times

Re: Digital clock using ATmega1284P, 4x 7-digits + DP, RTC and temperature

Post by mnfisher »

Yes - a 328p should take it in it's stride...

I've posted about using the Diamex programmer (and programming the Digispark Tiny85 boards) - so if you ever feel the urge to use one of the other AVR MCUs... I'm interested in having a play with some that use UDPI too :-)

I don't think the Mac (parallels) environment should cause any issues with the programmer - but I think there might be a web version before Mac (pure speculation on my part). There is an Arduino IDE 'online' environment (also a couple for esp32) - so although the device programming might still be a challenge - it may be possible?

Martin

Post Reply