Hello,
I want to no if I can use my pc as a media player, from home assistant point of view.
I would like to be able to play mp3 file from home assistant.
My home assistant is on docker ubuntu and my pc is on Window.
Many thanks for your help !!
best regards
Thierry
Maybe something like this?
I have not tried but am interested.
Many thanks for your reply,
but in finality I would like to be able to play with text to speech.
What kind of windows software I can install on the pc to play with tts (text to speech)
Many thanks !
Best regards
Thierry
TTS is separate home assistant integration that will play through any configured media player.
thanks for your reply,
I have one Windows Pc and one linux machine (hass.io on docker)
What kind of software I can install in the pc to be a media player from point of view of home assistant ?
Best regards
As long as you have home assistant open in a web browser on the device you could use this:
Do we need to say it louder? music player daemon. https://www.musicpd.org/doc/html/user.html#compiling-for-windows
TTS typically returns an mp3 ( in my experience) therefor any media player daemon will work, such as…MPD.
Other than Music Player Daemon, are there any other that will run on a PC? MPD is not really that straight forward on Windows. E.g. Getting errors about ‘wildmidi’ is unavailable. Trying to get TTS working on a regular PC speaker as I’m not liking the fact I cannot disable the Playback Sounds on my Google Home/Mini like I can on my Chromecast Audio. Super annoying!
Have you considered this?
I did see this in earlier in the thread, but was looking for something that ran more like a service and didn’t rely on the browser running on that PC all the time.
Are you looking for full media player services or just for tts? Thinking of building a small python program to play a url via mqtt.
In my case, just for TTS notifications.
I am working on a python program that uses vlc for audio, It runs on a windows system and perform this function (along with others).
I currently have it supporting the following MQTT messages (currently). Would you be willing to test it?
Examples
{"command": "pause"}
{"command": "stop"}
{"command": "play"}
("volume": 100}
{"play":"http://192.168.0.250:8123/local/mp3/horn.mp3"}
{"tts": "The quick Brown Fox Jumped Over the Lazy Dog"}
Sure thing, I’m willing to test. I’m assuming I’ll be able to just run VLC as a service as in the link below?
@Sireone (and any other brave souls).
I have created a build for my windows pc based notification app (HApyAudio).
Program is capable of running in the system tray (not really a service so use the windows startup apps)
This is built in Python and all the code is available for review here [be kind ;-)]
- Make sure you have VLC installed (I am using 3.0.11).
- Make sure you have an MQTT broker available.
- Extract the Release Zip file to a suitable location.
- Edit the settings.json file and update with your Broker.
- Run the program and your MQTT control topic to be shown in the gui window.
- Send some sample MQTT messages and see how it goes.
Feedback and Ideas are welcome.
Good Luck!
jumps, not jumped (otherwise there is no “s”)
LOL, I will open an issue.
So I got the program running and pointed it to my Home Assistant MQTT broker, with VLC installed (v. 3.0.16) It does show Published!, Connected! & Subscribed! with my topic MERCURY/HApyAudio/control.
I tried to publish a packet in HA with the topic name above and {“tts”: “The quick Brown Fox Jumped Over the Lazy Dog”}, but I hear nothing. I also tried playing the mp3 file, nothing. Jumped over to Node-Red, setup an mqtt out node with an Inject node which included the msg.payload (json/string) {“tts”: “The quick Brown Fox Jumped Over the Lazy Dog”} and msg.topic (string) MERCURY/HApyAudio/control. Added a debug node which showed the results, but no sound.
Is there any VLC configuration needed? What am I missing?
Try issuing a volume command. {“volume”: 80} then try the tts again.