Our new official repo is on github
LCD Smartie version 5.6 is released!
Download it now: https://github.com/LCD-Smartie/LCDSmartie/releases

BINARY CLOCK

Place your requests for plugins here

Moderators: _X7JAY7X_, caesar, IFR, mattcro, limbo

Post Reply
matus.kostik
Posts: 3
Joined: September 13th, 2011, 6:14 am

BINARY CLOCK

Post by matus.kostik »

Hi everybody!
Could someone make a binary clock plugin?

I have two suggestions:
#1:
Schránka02.jpg
#2:
Schránka03.jpg
And for example simple custom char for true and false value of fields:
Schránka04.jpg
You do not have the required permissions to view the files attached to this post.

dperrow
Plugin Author
Posts: 276
Joined: May 27th, 2011, 2:13 pm
Location: Stirling, Scotland

Re: BINARY CLOCK

Post by dperrow »

Ok, here you go. I've created a plugin called BinClk with 2 functions, just copy the attached dll to the plugins directory. You don't have to use function 2 it will default to using custom characters 1 and 2.

Function 1 - return character for binary clock
param1=H,M or S
param2=1,2,4,8,16 or 32
This will display the character (as per your custom character definitions) appropriate for that bit so for your second example in LCDsmartie you would use:

Hours: $dll(BinClk,1,H,32) $dll(BinClk,1,H,16) $dll(BinClk,1,H,8) $dll(BinClk,1,H,4) $dll(BinClk,1,H,2)$dll(BinClk,1,H,1)
Minutes: $dll(BinClk,1,M,32) $dll(BinClk,1,M,16) $dll(BinClk,1,M,8) $dll(BinClk,1,M,4) $dll(BinClk,1,M,2)$dll(BinClk,1,M,1)
Seconds: $dll(BinClk,1,S,32) $dll(BinClk,1,S,16) $dll(BinClk,1,S,8) $dll(BinClk,1,S,4) $dll(BinClk,1,S,2)$dll(BinClk,1,S,1)

Function 2 allows you to select the custom characters to be used (defaults to 1 and 2) in the range 1-8 just in case you get issues with other plugins.
param1=custom character number for False
param2=custom character for True
BinClk.zip
Let me know of any issues/improvements.

Regards,
Dave
You do not have the required permissions to view the files attached to this post.

matus.kostik
Posts: 3
Joined: September 13th, 2011, 6:14 am

Re: BINARY CLOCK

Post by matus.kostik »

GREAT! :wink: Thanks a lot. It works only like suggestion #2. But I can't do that, for example: 21 hours can be displayed like 2 and 1, or 59 minutes like 5 and 9 (suggestion #1). I know that isn't real binary, but if you could do this.

dperrow
Plugin Author
Posts: 276
Joined: May 27th, 2011, 2:13 pm
Location: Stirling, Scotland

Re: BINARY CLOCK

Post by dperrow »

Okay,
i've added a function 3 which works in a similar way:

Function 3 - return character for binary clock (modulo 10)
param1=H,M or S
param2=1,2,4,8,10,20 or 40
This will display the character (as per your custom character definitions) appropriate for that bit so for your first example in LCDsmartie you would use:

H: $dll(BinClk,3,H,8) M: $dll(BinClk,3,M,8) S: $dll(BinClk,3,S,8)
$dll(BinClk,3,H,4) $dll(BinClk,3,M,40) $dll(BinClk,3,M,4) $dll(BinClk,3,S,40) $dll(BinClk,3,S,4)
$dll(BinClk,3,H,20) $dll(BinClk,3,H,2) $dll(BinClk,3,M,20) $dll(BinClk,3,M,2) $dll(BinClk,3,S,20) $dll(BinClk,3,S,2)
$dll(BinClk,3,H,10) $dll(BinClk,3,H,1) $dll(BinClk,3,M,10) $dll(BinClk,3,M,1) $dll(BinClk,3,S,10) $dll(BinClk,3,S,1)

I've also adde a function 4 which lets you select between 12/24 hours, param1=0=12hrs, 1=24 hours (default.
BinClk2.zip
Let me know how you go.

Dave
You do not have the required permissions to view the files attached to this post.

matus.kostik
Posts: 3
Joined: September 13th, 2011, 6:14 am

Re: BINARY CLOCK

Post by matus.kostik »

It's working very well. :wink:

#1 24 hours format
IMAG0207.jpg
#2 12 hours format
IMAG0206.jpg
Thanks. :wink:
You do not have the required permissions to view the files attached to this post.

dperrow
Plugin Author
Posts: 276
Joined: May 27th, 2011, 2:13 pm
Location: Stirling, Scotland

Re: BINARY CLOCK

Post by dperrow »

Excellent,

Is that the time? better get on..... :D

Regards,
Dave

dperrow
Plugin Author
Posts: 276
Joined: May 27th, 2011, 2:13 pm
Location: Stirling, Scotland

Re: BINARY CLOCK

Post by dperrow »

I thought this was a good idea but my LCD on my media centre is only 2x16 so I've added a couple of functions as follows so that I can use it too:
pic16.jpg
using:
H: $dll(BinClk,7,H,4) M:$dll(BinClk,7,M,40)$dll(BinClk,7,M,4) S:$dll(BinClk,7,S,40)$dll(BinClk,7,S,4)
$dll(BinClk,7,H,10)$dll(BinClk,7,H,1) $dll(BinClk,7,M,10)$dll(BinClk,7,M,1) $dll(BinClk,7,S,10)$dll(BinClk,7,S,1)

// =============================================================================
// Function 7
// Param1=H, M or S
// Note that this function returns the 1,4,10,40 values modulo 10
// Returns custom character definitions for the binary time portion
// vertical 1 char each 2 bits per value for a 2 line display
// =============================================================================


and for a single line display:
pic18.jpg
using:
Hours Mins Secs
$dll(BinClk,6,H,) $dll(BinClk,6,M,) $dll(BinClk,6,S,)

// =============================================================================
// Function 6
// Param1=H, M or S
// Note that this function returns the 1,2,4,8 values modulo 10
// Returns custom character definitions for the binary time portion
// horizontal 4 characters each
// =============================================================================

Here's the dll:
BinClk3.zip
Enjoy,
Dave
You do not have the required permissions to view the files attached to this post.

Post Reply