Closed TSM-EVO closed 6 years ago
Hi @TSM-EVO,
It looks like you're running LIRC 0.9.4 - I think lirc-web
isn't fully compatible with this version of LIRC (I haven't verified though, but see these notes on Home Assistant LIRC component). If you need to use lirc-web
, you might want to downgrade LIRC to 0.9.0.
Since your end goal is to send IR commands using HA, do you actually need lirc-web
, or can you get away with only configuring the LIRC component within HA?
@flochtililoch Thanks for the prompt response!
My understanding is that the lirc component in HA can't send irsend
commands, which is what I'm trying to do. Because I've now setup my HA with docker, I can't send commands directly to my "host" which is running lirc.
I've tried using key pairs to have the HA docker container send ssh to the host machine but failed to get that working, too.
It would be nice to have lirc_web working so that I could eventually separate my HA device from my lirc device.
I'll try downgrading lirc to 0.9.0. Thanks!
Downgrading to 0.9.0 worked.
$ lircd -v
lircd 0.9.0-pre1
my remote shows up in lirc_web and the buttons function.
Thanks!
Great! I wrote a little while back another JavaScript module (lirc-state-api
, works on the top of lirc_node
like lirc_web
) that exposes a REST API to manipulate remotes, while keeping states of the remote controlled devices in memory. This might be useful for your use case, particularly if you want your HA switch to retain/show the last state set. I’m still using it today to control all my IR devices and it work mostly well except for a few edge cases. In case you’re interested give it a shot/let me know if you need help to set it up (there are RPi docker images in my docker hub)
I'll certainly check it out, I can see why it'd be helpful. For my use case, though, knowing the state of my IR device is not critical, but if I were to extend functionality it'd be on the list of things I'd want.
Hi @alexbain , thanks to your work over the years I've been able to use lircd to control my Daikin A/C unit with my RPi2.
I've recently re-setup my HomeAssistant in a docker container, which means that sending a simple command from HASS is not so simple.
I have raspbian stretch installed, and lirc is working. The command
irsend SEND_ONCE DAIKIN KEY_POWER
turns my A/C on.npm -v 6.1.0
andnode -v v10.6.0
I installed lirc_web with npm, didn't need sudo, and I can load the web interface at myip:3000. On that page there are three 'buttons's that say
could not connect to socket
No such file or directory
open socket /run/lirc/lircd1: No such file or directory
I have the config file at ~/.lirc_web_config.json and it looks like this now:
Changing the socket: changes what shows on the page. With the default "socket" the errors showed, with this string, nothing shows. I tried lots of strings here, I tried this one because
systemctl status lircd.socket
returnssystemctl status lircd.service
returnsBut one thing I noticed is
I noticed there's no rc_core. That may be because I don't have the IR receiver hooked up or configured at this stage, one I read the codes from my remote I no longer needed it.
I also have this
But since I can control my device with irsend I'm not sure if this is related.
Request:
Can you suggest what I can do to troubleshoot next? Should I try installing lirc_web differently? Or is my config wrong somehow?
I also want to ping @flochtililoch because I can see he also seems to be utilizing lirc_web in a similar way and seems to have a good understanding of the program.
My end goal is to use a Home Assistant switch to send KEY_POWER and KEY_POWER2 to my 'host' using the API and their restful switch component. Once I can figure out why my control won't show up in lirc_web, I think I should be pretty close to getting it functional.
Thank you again for your help