3 Simple Ways to
Share What You Make

With Instructables you can share what you make with the world — and tap into an ever-growing community of creative experts.

PhotosPhotos

Share one or more photos of a project, recipe, or whatever you've made, quickly and easily.

Step by StepStep-By-Step

Share your step-by-step photos with text instructions of what you made so others can do it too!

VideoVideo

Share your how-to video. You'll need your embed code from a video site such as YouTube.

Minidot 2 - The holoclock

Step 6Software and User Interface

The operation of the device is very simple, no special pattern modes or flashy stuff. The only thing it does is display the time.

To set the time first press SW1.
The device will flash all LEDs a few times and then the 10s hours group of LEDs
SW3 will increment the selected group
SW2 will move to the next group of LEDs, each time flashing all LEDs in the group briefly.

The code is written for Sourceboost 'C' compiler version 6.70.

The RTC code is in the t1rtc.c/h files, and has an interrupt function on the T1 timer of the PIC. The T1 timer is set to interrupt every 1 second. On each second, the variable for the time are incremented.
Also a tick timer is counted down every second along with the time. This is used to determine when to transition the display.
The interrupt function also uses the T0 timer interrupt to refresh the display, calling a function in display.c


The files display.h/display.c contain the functions to update the display and show the time

The files control.c/h contain the functions to set the time and read the switches

The files holoclock.c/h are the main loops and initialisation.
« Previous StepDownload PDFView All StepsNext Step »

Pro

Get More Out of Instructables

Already have an Account?

close

All Steps Viewing
View all steps of an Instructable on the same page when you're a Pro Member.

Upgrade to Pro today!
26
Followers
7
Author:rgbphil
update later