[arm-allstar] newsline
Dave Petrie
wa2kjc at gmail.com
Wed Nov 24 18:20:02 EST 2021
I commented out that second INCREMENT=155 statement about line 223 from
within the while...do...done loop.
and the newsline did not play, instead i got the time for ID announcement
and then the end announcement,
uncommenting those lines it is now playing again, but still have the issues
I first described.
On Wed, Nov 24, 2021 at 5:50 PM David McAnally <david.mcanally at gmail.com>
wrote:
> Replace your "sleep 599" line with the lines I provided.
>
> Also, I just noticed that the script sets INCREMENT in two places. I don't
> see the reason for setting it twice, so I removed that second INCREMENT=155
> statement about line 223 from within the while...do...done loop.
>
> David M.
> WD5M
>
> On Wed, Nov 24, 2021 at 4:45 PM Dave Petrie <wa2kjc at gmail.com> wrote:
>
>> ok, I don't want to mess this up so here is where you are pointing,
>> control G with WinSCP 305
>> takes me to the #sleep 175 line. So where do i insert:
>> LENGTH=`soxi -D $TMPDIR/news.ul 2>/dev/null`
>> let DELAY=${LENGTH/.*}+20
>> sleep $DELAY
>>
>> # Start news
>> PART="1"
>> while [ "$PART" -le "$MAXPART" ]; do
>> echo "Playing file $TMPDIR/news.part$PART.ul"
>> if [ "$PART" -lt "$MAXPART" ]; then
>> # Add Station break message with 1 second delay
>> cat $TMPDIR/news.part$PART.ul $VOICEDIR/silence1.ul
>> "$VOICEDIR/${NEWSTYPE}continue.ul" > $TMPDIR/news.ul
>> /usr/bin/asterisk -rx "rpt $MODE $NODE $TMPDIR/news"
>> # Break every 2.5 minutes for 20 seconds ;changed to 585 for
>> 9.75 minutes - wa2kjc
>> # Note this break has to be long enough for network ID's
>> #sleep 175
>> sleep 599
>>
>> else
>> # Append end message with 2 second delay
>> cat $TMPDIR/news.part$PART.ul $VOICEDIR/silence2.ul
>> "$VOICEDIR/${NEWSTYPE}stop.ul" > $TMPDIR/news.ul
>> /usr/bin/asterisk -rx "rpt $MODE $NODE $TMPDIR/news"
>> # Terminate script at end of audio
>> LENGTH=`soxi -D $TMPDIR/news.ul 2>/dev/null`
>> DELAY=${LENGTH/.*}
>> sleep $DELAY
>> fi
>> let "PART += 1"
>> done
>>
>> On Wed, Nov 24, 2021 at 5:24 PM David McAnally <david.mcanally at gmail.com>
>> wrote:
>>
>>> Perhaps replacing the sleep 175 line with these lines would be better.
>>> Similar to the "else..." section below, this recalculates the delay based
>>> on the actual length of each part of the audio playback plus 20 seconds.
>>>
>>> LENGTH=`soxi -D $TMPDIR/news.ul 2>/dev/null`
>>> let DELAY=${LENGTH/.*}+20
>>> sleep $DELAY
>>>
>>> David M.
>>> WD5M
>>>
>>> On Wed, Nov 24, 2021 at 3:55 PM Dave Petrie <wa2kjc at gmail.com> wrote:
>>>
>>>> ok, I am not a linux guru, sorry but I do want to solve this and I do
>>>> appreciate everyone who responds,
>>>> where do i put the :
>>>> IDWAIT=${INCREMENT}+20
>>>> sleep $IDWAIT
>>>>
>>>> and how does 6 more seconds unkey the play so all nodes reset timers.
>>>> my sleep time is 599
>>>>
>>>>
>>>>
>>>> On Wed, Nov 24, 2021 at 4:41 PM David McAnally <
>>>> david.mcanally at gmail.com> wrote:
>>>>
>>>>> I suggest changing the "sleep 175" statement at about line 303 in
>>>>> playnews-0.11 to a value 20 seconds longer than your INCREMENT value. In
>>>>> your case, 585 + 20 = 605.
>>>>> sleep 605
>>>>>
>>>>> A more flexible solution would be to update the script to calculate
>>>>> the sleep value. e.g.
>>>>> let IDWAIT=${INCREMENT}+20
>>>>> sleep $IDWAIT
>>>>>
>>>>> Regards,
>>>>> David M.
>>>>> WD5M
>>>>>
>>>>>
>>>>> On Wed, Nov 24, 2021 at 2:48 PM "Dave Petrie via ARM-allstar" <
>>>>> arm-allstar at hamvoip.org> wrote:
>>>>>
>>>>>> Hi Darrell, that's fine for your choice, we have 6 repeaters on a
>>>>>> microwave
>>>>>> linked system and I have set all the timers the way I need and want
>>>>>> them.
>>>>>> rpt.conf
>>>>>> tx_timeout=1800000
>>>>>> idtime=600000
>>>>>> politeid=10000
>>>>>> rx_timeout=600000
>>>>>>
>>>>>> playnews-0.11
>>>>>> #echo $LENGTH
>>>>>> START=0
>>>>>> INCREMENT=585
>>>>>>
>>>>>> # Divide into 2.5 minute segments
>>>>>> INCREMENT=585
>>>>>>
>>>>>> # send start announcment
>>>>>> sleep 22
>>>>>>
>>>>>> # Start news
>>>>>> sleep 599
>>>>>>
>>>>>>
>>>>>> I just need to be able to stop the play at the end of the increment,
>>>>>> for
>>>>>> 20-30 seconds and start the second play increment.
>>>>>> Almost there.
>>>>>> Hey I am retired and I will figure it out someday, maybe not this
>>>>>> winter
>>>>>> but I will get it.
>>>>>> I was hoping one of you linux guys would have an easy solution.
>>>>>> IT's the technical challenge, not the need to play newsline.
>>>>>> I have accomplished so much in the last year or so and having so much
>>>>>> fun
>>>>>> with this hamvoip software, and I know there is so much more to
>>>>>> learn. I
>>>>>> don't want to fell like I am back at work, it's so nice to close the
>>>>>> laptop
>>>>>> and take a nap anytime I feel like it.
>>>>>> Thanks for the reply, any others ?
>>>>>> Dave
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Nov 24, 2021 at 3:28 PM Darrell Black <gigahacker at gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>> > Hi Dave, I played with this when I set up our news server.
>>>>>> >
>>>>>> > in file /etc/asterisk/local/playnews/playnews-0.11
>>>>>> > Around line ~210 >INCREMENT=150 <==== 150 seconds is 2.5 minutes.
>>>>>> >
>>>>>> > Warning if you increase the time, it like I did. The repeater
>>>>>> timeout
>>>>>> > timer and all the allstar hotspot linked timers need to be greater
>>>>>> than
>>>>>> > your slice time, or they will timeout. In the end I went back to 2.5
>>>>>> > minutes.
>>>>>> >
>>>>>> >
>>>>>> > On Wed, Nov 24, 2021 at 2:41 PM "Dave Petrie via ARM-allstar" <
>>>>>> > arm-allstar at hamvoip.org> wrote:
>>>>>> >
>>>>>> >> I am trying to control the playtime for newsline, everything is
>>>>>> working as
>>>>>> >> I want it to except for when the first segment finishes, i can't
>>>>>> get the
>>>>>> >> broadcast to shutdown or unkey or be quiet long enough for the
>>>>>> forced
>>>>>> >> repeater ID time to play.
>>>>>> >> I have edited the mp3 file so that the audio play timing fits.
>>>>>> >> I want 9 minutes 30 seconds for the play times and the first
>>>>>> section is
>>>>>> >> perfect, INCREMENT=585.
>>>>>> >> I can't get things to shut down for 20-30 seconds to allow for the
>>>>>> ID
>>>>>> >> timers to complete and can't seem to control the start of the
>>>>>> second mp3
>>>>>> >> play file. I am not a linux guru, but I don't give up easily.
>>>>>> >> So to recap, I want to be able to choose my play windows timing
>>>>>> and I want
>>>>>> >> things to unkey at the end of the playtimes and restart up again,
>>>>>> all that
>>>>>> >> timing should be under my control.
>>>>>> >> Thanks
>>>>>> >> Dave
>>>>>> >> _______________________________________________
>>>>>> >>
>>>>>> >> ARM-allstar mailing list
>>>>>> >> ARM-allstar at hamvoip.org
>>>>>> >> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>>>>>> >>
>>>>>> >> Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
>>>>>> >>
>>>>>> >
>>>>>> >
>>>>>> > --
>>>>>> >
>>>>>> > Darrell Black
>>>>>> >
>>>>>> > (517) 917-2226
>>>>>> > GigaHacker at gmail.com
>>>>>> > http://www.linkedin.com/in/darrellblack
>>>>>> >
>>>>>> >
>>>>>> > 73 de W8DSB
>>>>>> > "In God we trust, all others we monitor"
>>>>>> >
>>>>>> > GMRS WRDE739
>>>>>> > ALLSTAR 50964
>>>>>> > DMR 310195
>>>>>> >
>>>>>> >
>>>>>> _______________________________________________
>>>>>>
>>>>>> ARM-allstar mailing list
>>>>>> ARM-allstar at hamvoip.org
>>>>>> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>>>>>>
>>>>>> Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
>>>>>>
>>>>>
More information about the ARM-allstar
mailing list