Webcast Wednesday Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Webcast Wednesday Contest # 4

Question) Design a clock (with hours, minutes & seconds hand) in LabVIEW. Similar to the one below .Attach VIs and other files in your answer by clicking on the Advanced/Full Editor mode in your comment window while you are typing the comment.

Clock.jpg

Rules & Guidelines

  • Post your answers as comments on this thread.
  • The participant answering all the questions correctly and in the shortest time will be the winner. In case of VI or code as answers, the participant will also be judged on the basis of the efficiency of the VI/code.
  • In case of a participant submitting multiple comments (answers), the first entry will be considered.
  • The deadline for answer submission is next Monday. Entries made after Monday will not be accepted.
  • Entries made after the deadline will not be accepted.
  • The winner will be announced in the next session of Webcast Wednesday and on this thread, with further information & next steps.
0 Kudos
Message 1 of 25
(13,213 Views)

Working clock Attached.

Check context help for documentation as well as VI comments.

Press the to stop the VI.

AA_Clock_3.png

Message was edited by: Ammouri (minor scale:range modification)

Message 2 of 25
(7,223 Views)

Brief Description on how the clock was designed and tested:

----------------------------------------------------------------------------------------

1. Gauge were used to implement the Clock

__# Gauge Seconds: has the main background of the clock + the "Seconds" arrow (Scale is hidden). ---> "Clock Ctrl_white.ctl" or "Clock Ctrl_bkc.ctl"

__# Gauge Minutes : has middle node + the "Minutes" arrow (Everything else is hidden).----------------------> "Clock min.ctl"

__# Gauge Hours : has the "Hours" arrow Only (Everything else is hidden).------------------------------------------> "Clock hrs.ctl"

** All the previously mentioned gauges has the same scale (0-12)

2. All the gauges are overlapped (over each other) with a String indicator below, where all are put into a Cluster.
---> "Clock Cluster.ctl" or "Clock Cluster Bkc.ctl"

3. Three VIs are implemented to test the Clocks using the current "Hours, minutes and Seconds", the difference is in the VI layout design.

__# "Clock Example" : Using the LabVIEW Decorations.

__# "Clock Example BG_Grey" : Using a Grey Layout with texture on the Background.

__# "Clock Example BG_Texture" : Using a Brown  textured Layout on the Background.

** The Code of the Clock (Dividing to Hours, minutes and Seconds) is quoted from the following link:

Clock-indicator for LV:  http://www.asl.ethz.ch/people/kneipl/personal/clock.llb

%% Kindly find attached the "Contest #4 Solutions" Zip File comprising all the previously mentioned files & VIs.

Message 3 of 25
(7,223 Views)

What happened to the blind submissions?

Message 4 of 25
(7,223 Views)

clock LV2011

Regards,
Balaji DP
Message 5 of 25
(7,223 Views)

Ahmed Zahran : There is a bug in the code , if you see the hour needle after 1200 Hours , there is no visible change and it again works normally from 0100 Hours , this bug has been handled in Balaji_DP's code.

Message 6 of 25
(7,223 Views)

There is no need for calculation or conditions to implement the clock.

All can be achieved by manipulating the scale ranges.

0 Kudos
Message 7 of 25
(7,223 Views)

Hi Ammouri,

I just went through your code. Do you think using event structure with 1000 ms will imitate the original clock?

Just check when time is 3.59 PM. Your clock shows 2:59 PM at that time. Your hour needle is getting updated after every 60 minutes and minute needle is getting updated after every 60 seconds.

Balaji code is a perfect imitation of analogus clock. He has taken care in updating both minute and hour needle after every 1 second which is the actual requirement of Analog clock. Moreover he has also taken care the probelm of 12-1 PM bug found in Ahmed Zaharan code

0 Kudos
Message 8 of 25
(7,223 Views)

More realistic implementation (Better than the task bar clock).

Message was edited by: Ammouri

Message 9 of 25
(7,223 Views)

Hi friends,

             I`ve attached my work here. I hope this would meet the task given. Please check the attachment.

Download All
Message 10 of 25
(7,223 Views)