24 Hour Time - 2024

So I came across Ham Radio Crusader’s (Freddie Mac KD5FMU) video https://www.youtube.com/watch?v=29GMVajremU about setting an hourly time announcement for AllStar Link v3. His method is creating a *.sh file with:

#! /usr/bin/bash

/usr/bin/sudo asterisk -rx "rpt cmd 62445 status 12 xxx"

His method announces the time in 12-hour format with AM/PM and the “o’clocks”. Is there a way to use that same method to announce the time in 24-hour format?

I did find this https://community.allstarlink.org/t/time-question/11402 back from 2014, so I was wondering was there something newer, 10 years later?

Thanks & 73,

Jeff K3JRZ

If you are using ASL3, you can do this with asl-say, in theory.
/usr/bin/asl-say -n <your_node_number> -w time24

However, when I do this, I get the following error:
asl-say -n 508428 -w time24
/usr/bin/asl-say: line 79: 20 <= ${NOW_HR } && ${NOW_HR} < 24 : bad substitution
sox FAIL sox: Not enough input filenames specified
followed by usage from sox.

Just the switch -w time gives no error.
This was done on a node with no radio attached, so I don’t know what the actual resulting output is.

I ran the command from the command line and got no error. FYI - It did announce the time as “The time is 7 hours and 57 minutes E D T”. (yes, spacing/longer pauses between the letters of “EDT”). Also FYI - It also does not say “Good morning/afternoon/evening” as did the original version from KD5FMU, if anyone is curious.

I wonder if there are other variations that might work too? Anyone?

Thanks & 73

Jeff K3JRZ

After running the strong a few times I got the error:

Blockquote
root@node62445:/etc/asterisk/local# /usr/bin/asl-say -n 62445 -w time24
/usr/bin/asl-say: line 87: ((: == 0 : syntax error: operand expected (error token is "== 0 ")
/usr/bin/asl-say: line 89: ((: 0 < && < 20 : syntax error: operand expected (error token is "&& < 20 ")
/usr/bin/asl-say: line 92: / 10 : syntax error: operand expected (error token is "/ 10 ")
sox: SoX v14.4.2
sox FAIL sox: Not enough input filenames specified

Interesting…
but then after a few more times I got th normal output of the time on my node.

WEIRD!

73,

Jeff K3JRZ