Mailing List Archive

***Spam*** digital radio alarm clock
Hoi All,

Until last week, when analog radio disappeared, I used a machine with
an analog tuner card as my alarm clock. A simple remote boot script
that then tuned and started radio playback.
I now am looking for thoughts on how to do this with digital playback.

My situation:
- The machine in my bedroom has no digital tuner card;
- It does have mythfrontend;
- I have both a hdhomerun and a digital tuner card in the backend and
the backend is on 24/7;
- However the hdhomerun is connected through a dedicated nic on the
backend;
- I?m still running 0.27 under Gentoo Linux.

I see 3 possible scenario?s, which all include remote booting the
frontend machine:
1. Remote start liveTV on the right radio channel;
2. Move the frontend machine to the dedicated hdhomerun network and
remote tune and connect it to the hdhomerun;
3. Do this on the backend machine and stream the audio.

Any idea?s on scripts or program?s?

--
Tot Mails,
Hika mailto:hikavdh@gmail.com
Mijn Mailadres is gewijzigd. Zie hierboven!

"Zonder hoop kun je niet leven
Zonder leven is er geen hoop
Het eeuwige dilemma
Zeker als je hoop moet vernietigen om te kunnen overleven!"

De lerende Mens

_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: ***Spam*** digital radio alarm clock [ In reply to ]
On Mon, 26 Jul 2021 18:38:13 +0200, you wrote:

>Hoi All,
>
>Until last week, when analog radio disappeared, I used a machine with
>an analog tuner card as my alarm clock. A simple remote boot script
>that then tuned and started radio playback.
>I now am looking for thoughts on how to do this with digital playback.
>
>My situation:
>- The machine in my bedroom has no digital tuner card;
>- It does have mythfrontend;
>- I have both a hdhomerun and a digital tuner card in the backend and
> the backend is on 24/7;
>- However the hdhomerun is connected through a dedicated nic on the
> backend;
>- I?m still running 0.27 under Gentoo Linux.
>
>I see 3 possible scenario?s, which all include remote booting the
>frontend machine:
>1. Remote start liveTV on the right radio channel;
>2. Move the frontend machine to the dedicated hdhomerun network and
> remote tune and connect it to the hdhomerun;
>3. Do this on the backend machine and stream the audio.
>
>Any idea?s on scripts or program?s?

You can also allow access to the dedicated nic on the backend by
setting up routing to it via the backend box. That would allow access
to the hdhomerun from anywhere on your network. That would require
that the backend box and its hdhomerun network use static IP addresses
or manual DHCP addresses, but you are probably doing that already. The
backend box would need its firewall to allow access, if it has one.
Then you can just run a routing daemon on both the backend and
frontend boxes - I use quagga. You would set up quagga's OSPF
protocols (ospfd for IPv4 and ospf6d for IPv6). You could also use
the older RIPv2 and RIPng protocols, but OSPF works better. If you
want Windows boxes or other devices to see the dedicated nic, then you
would need to set up your router to do RIP or OSPF (if it has that
ability) and those devices would have to send their traffic to the
dedicated nic via the router.

It is also possible to just manually set up routing rules, rather than
using routing protocols to set up the rules.
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: ***Spam*** digital radio alarm clock [ In reply to ]
Hoi Stephen,

Tuesday, July 27, 2021, 4:21:29 AM, you wrote:

> On Mon, 26 Jul 2021 18:38:13 +0200, you wrote:

>>Hoi All,
>>
>>Until last week, when analog radio disappeared, I used a machine with
>>an analog tuner card as my alarm clock. A simple remote boot script
>>that then tuned and started radio playback.
>>I now am looking for thoughts on how to do this with digital playback.
>>
>>My situation:
>>- The machine in my bedroom has no digital tuner card;
>>- It does have mythfrontend;
>>- I have both a hdhomerun and a digital tuner card in the backend and
>> the backend is on 24/7;
>>- However the hdhomerun is connected through a dedicated nic on the
>> backend;
>>- I?m still running 0.27 under Gentoo Linux.
>>
>>I see 3 possible scenario?s, which all include remote booting the
>>frontend machine:
>>1. Remote start liveTV on the right radio channel;
>>2. Move the frontend machine to the dedicated hdhomerun network and
>> remote tune and connect it to the hdhomerun;
>>3. Do this on the backend machine and stream the audio.
>>
>>Any idea?s on scripts or program?s?

> You can also allow access to the dedicated nic on the backend by
> setting up routing to it via the backend box. That would allow access
> to the hdhomerun from anywhere on your network. That would require
> that the backend box and its hdhomerun network use static IP addresses
> or manual DHCP addresses, but you are probably doing that already. The
> backend box would need its firewall to allow access, if it has one.
> Then you can just run a routing daemon on both the backend and
> frontend boxes - I use quagga. You would set up quagga's OSPF
> protocols (ospfd for IPv4 and ospf6d for IPv6). You could also use
> the older RIPv2 and RIPng protocols, but OSPF works better. If you
> want Windows boxes or other devices to see the dedicated nic, then you
> would need to set up your router to do RIP or OSPF (if it has that
> ability) and those devices would have to send their traffic to the
> dedicated nic via the router.

> It is also possible to just manually set up routing rules, rather than
> using routing protocols to set up the rules.
> _______________________________________________

Good thought, I have ipv4 routing setup and can on Linux access it
through a browser. For some weird reason not on Windows, neither on a
browser nor with the hdhomerun native windows tools. The latter looks
logical as I can not give an ip address there, so it either only
checks the subnet or uses some other discovery method that does not go
beyond the physical subnet.

I'll have to check and compile the latest linux tools as they are old
and also only present on the backend. However checking it, it looks
like I there can supply an ip address.

I'm gonna try things.

Tot mails,
Hika mailto:hikavdh@gmail.com

"Zonder hoop kun je niet leven
Zonder leven is er geen hoop
Het eeuwige dilemma
Zeker als je hoop moet vernietigen om te kunnen overleven!"

De lerende Mens

_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: ***Spam*** digital radio alarm clock [ In reply to ]
Hoi Hika,

Tuesday, July 27, 2021, 12:56:32 PM, you wrote:

> Hoi Stephen,

> Tuesday, July 27, 2021, 4:21:29 AM, you wrote:

>> On Mon, 26 Jul 2021 18:38:13 +0200, you wrote:

>>>Hoi All,
>>>
>>>Until last week, when analog radio disappeared, I used a machine with
>>>an analog tuner card as my alarm clock. A simple remote boot script
>>>that then tuned and started radio playback.
>>>I now am looking for thoughts on how to do this with digital playback.
>>>
>>>My situation:
>>>- The machine in my bedroom has no digital tuner card;
>>>- It does have mythfrontend;
>>>- I have both a hdhomerun and a digital tuner card in the backend and
>>> the backend is on 24/7;
>>>- However the hdhomerun is connected through a dedicated nic on the
>>> backend;
>>>- I?m still running 0.27 under Gentoo Linux.
>>>
>>>I see 3 possible scenario?s, which all include remote booting the
>>>frontend machine:
>>>1. Remote start liveTV on the right radio channel;
>>>2. Move the frontend machine to the dedicated hdhomerun network and
>>> remote tune and connect it to the hdhomerun;
>>>3. Do this on the backend machine and stream the audio.
>>>
>>>Any idea?s on scripts or program?s?

>> You can also allow access to the dedicated nic on the backend by
>> setting up routing to it via the backend box. That would allow access
>> to the hdhomerun from anywhere on your network. That would require
>> that the backend box and its hdhomerun network use static IP addresses
>> or manual DHCP addresses, but you are probably doing that already. The
>> backend box would need its firewall to allow access, if it has one.
>> Then you can just run a routing daemon on both the backend and
>> frontend boxes - I use quagga. You would set up quagga's OSPF
>> protocols (ospfd for IPv4 and ospf6d for IPv6). You could also use
>> the older RIPv2 and RIPng protocols, but OSPF works better. If you
>> want Windows boxes or other devices to see the dedicated nic, then you
>> would need to set up your router to do RIP or OSPF (if it has that
>> ability) and those devices would have to send their traffic to the
>> dedicated nic via the router.

>> It is also possible to just manually set up routing rules, rather than
>> using routing protocols to set up the rules.
>> _______________________________________________

> Good thought, I have ipv4 routing setup and can on Linux access it
> through a browser. For some weird reason not on Windows, neither on a
> browser nor with the hdhomerun native windows tools. The latter looks
> logical as I can not give an ip address there, so it either only
> checks the subnet or uses some other discovery method that does not go
> beyond the physical subnet.

> I'll have to check and compile the latest linux tools as they are old
> and also only present on the backend. However checking it, it looks
> like I there can supply an ip address.

> I'm gonna try things.

I previously never really looked at the hdhomerun_config tool. It says
it wants an <id> and that didn't work in my network configuration,
except on the backend. However <id> means either the id or the ip
address! So I now can in my scripts substitute the old ivtv and v4l2
tools. Will take some time to figure it all out as those script are
old.

Thanks Stephen for kicking my thinking on the right track!

Tot mails,
Hika mailto:hikavdh@gmail.com

"Zonder hoop kun je niet leven
Zonder leven is er geen hoop
Het eeuwige dilemma
Zeker als je hoop moet vernietigen om te kunnen overleven!"

De lerende Mens

_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: ***Spam*** digital radio alarm clock [ In reply to ]
>> Hoi Stephen,

> I previously never really looked at the hdhomerun_config tool. It says
> it wants an <id> and that didn't work in my network configuration,
> except on the backend. However <id> means either the id or the ip
> address! So I now can in my scripts substitute the old ivtv and v4l2
> tools. Will take some time to figure it all out as those script are
> old.

> Thanks Stephen for kicking my thinking on the right track!

I found the following script (I guess I at some time got it from
silicon dust) and it works perfect!
I put the ip address in hard and the tuning parameters you can get
through:

hdhomerun_config <ip-address> scan <tuner>

I have been looking at it on and of for years, but never really
serious. There was no urgency. I never thought it would be so simple.
Just substituting id with ip! :-)

hdhr4.sh
#!/bin/bash

id=${id:-"192.168.223.20"}
tuner=${tuner:-3}
channel=$1
program=$2
output=${3:-"-"}

usage () {
echo "$0 <channel> <program> [output]"
echo "ENV variables: id, tuner"
exit 1
}


if test -z "$channel"; then usage; fi
if test -z "$program"; then usage; fi


echo command: $0 $*

hdhomerun_config $id set /tuner${tuner}/channel $channel
hdhomerun_config $id set /tuner${tuner}/program $program

if test "$output" = "-"; then
hdhomerun_config $id save /tuner${tuner} - | mplayer -fs -
else
echo Saving $channel-$program to $output
hdhomerun_config $id save /tuner${tuner} ${output}
fi

exit 0


Tot mails,
Hika mailto:hikavdh@gmail.com

"Zonder hoop kun je niet leven
Zonder leven is er geen hoop
Het eeuwige dilemma
Zeker als je hoop moet vernietigen om te kunnen overleven!"

De lerende Mens

_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org