This is a follow-up to my previous skill which uses TuneIn to find internet radio streams. I Heart Radio has a slightly different set of stations and is skewed towards the US market and commercial radio stations. The combination of TuneIn and IHeartRadio should get 95% of worldwide radio stations.
Important notes:
Most of the IHeartRadio streams are AAC or MP4 streams so the skill uses vlc for streaming instead of mpg123. This currently is problematic as VLC doesn’t seem to install nicely using the combination of MSM and the manifest.yml file. I’ve got a thread going in chat to try and clean that up but in the meantime the easiest thing to do so you can test this skill is to just apt-get install vlc yourself prior to installing the skill.
I also ran into problems getting a proper python wrapper of libvlc working on mark-1 hardware. For that reason I launch vlc directly and then control it using the remote control commands over a pipe.
mycroft-skill-iheartradio connects to I Heart Radio Internet radio directory
This skill uses the public I Heart Radio web API that doesn’t require an account or any authentication.
There are no settings required for this skill
How to test mycroft-skill-iheartradio
After install there are no further steps to configure as there are no settings.
“Play KEXP (on|with|using) I Heart Radio”
“Play Jack FM radio”
“Play Jazz 24 internet radio”
“Play 80s Metal radio (on|with|using) I Heart Radio”
“Play 70s Country internet radio (on|with|using) I Heart Radio”
Or
Speak `Intent phrase “Stream” followed by a station name, number, genre, etc. to search for.
Valid intent forms:
“Stream KEXP”
“Stream Jack FM Radio”
“Stream Jazz 24 internet radio”
“Stream 80s Metal (on|with|using) tune in”
“Stream 70s Country radio (on|with|using) tune in”
“Stream 99.9 internet radio (on|with|using) tune in”
“Stream 107.7 radio station”
“Stream NPR News internet radio station”
“Stream KEXP radio station (on|with|using) tune in”
“Stream KEXP internet radio station (on|with|using) tune in”
Mycroft should say it’s starting to stream a station name and then the radio audio stream should start. If it can’t find any station that matches your search criteria then it will tell you that if couldn’t find any stations matching.
Where feedback on mycroft-skill-iheartradio should be directed:
The pip- package for the Python-wrapper is „python-vlc“. You may want to have a look at my Amazonmusic skill which uses VLC as well and runs fine on my Mark-1.
This indicates that VLC could not be initialized from the Mycroft-audio service. Does this error persist after a full restart of Mycroft (or reboot of the machine running Mycroft)?
I only have the python-vlc installed. To my knowledge the vlc 2018.11.20 package is a set of scripts for MacOS only. Try removing it by mycroft-pip uninstall vlc…
I have changes up to move back to the older requirements.* format and switching to use the VLCService. I’ve done basic testing on my Linux box and Mark-1 and it seems to be working decently.
Just letting you know I was having some frustration finding local Australian stations even though they come up as the top hit if I search on iheart.com from an Australian IP.
I found that for some countries, at least Australia and New Zealand, they have a unique API endpoint: au.api.iheart.com/api/v3/search/all. Switching both both the search and station url’s to use the au subdomain returns the results I expect.
Not sure how widespread this is, there doesn’t seem to be any us, uk or se subdomains. I couldn’t see any API documentation either so assuming you just reverse engineered that?
Hey John, this is one of my most used Skills and I’d love to recommend it to more users. Wondering what you think about submitting it to the Marketplace?
You can do this by first ensuring the Skill is installed on the computer you’re on, then run: mycroft-msk submit /opt/mycroft/skills/mycroft-skill-iheartradio.johnbartkiw
I would love to submit it to the marketplace. Before doing that I’d like to integrate your pull request and potentially improve how well it handles the CommonPlayFramework. I’m on the road for the next week and a half but I am motivated to get it cleaned up when I get back. I use the skill on a daily basis myself.
Hi, I’m new to Mycroft. I’ve installed PiCroft and it’s working well. I’ve installed the I Heart Radio Skill, and Mycroft tells me “Playing streaming station xxxxx” where xxxxx is the name of the station,
but I don’t hear anything. (I also have the Spotify skill, which works, so I know I can stream audio.).
There is an error in the log:
00:43:56.249 | INFO | 657 | Playback Control Skill | Playing with: mycroft-skill-iheartradio.johnbartkiw
00:43:56.602 | INFO | 657 | Playback Control Skill | Audio service status: {}
[4972f740] adaptive demux error: Failed to create demuxer (nil) Unknown
I’d love to get this working if anyone can help. Thank you!
Thanks so much for your reply. I haven’t installed any software other than a few skills, so VLC must have been installed by the base installation or one of the skills. vlc --help shows me that I have VLC media player 3.0.8 Vetinari (revision 3.0.8-0-gf350b6b5a7). (I’m still learning my way around Linux, so I’m not sure if there’s a better way to get the information.)
I’m having a weird issue getting this skill to play one of my local stations.
It will only play if I say “Play/Stream WWDC 101.1 on/from Iheartradio”. It cannot find the station if I only use “DC101”, “101.1”, or “WWDC”, I have to use the both the call letters and the frequency. However the response from mycroft is “Now playing DC101 from i heart radio”.