Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details
If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.
Ah.. I found what was my problem with testing the send feature with WinLirc. It uses a "transmit password" that changes the SEND_ONCE command to something else, I had to go and input it myself in the windows registry(HKLM\software\LIRC\password) to make it respond. Also winlirc doesnt support the other two commands.. but hey, everything seems to work fine now!
Also WinLirc seems to require the repeat count in the string, which is a bit non-standard behaviour since the specs say:
SEND_ONCE <remote control name> <button name> [<repeat count>]
SEND_START <remote control name> <button name>
SEND_STOP <remote control name> <button name>
[<repeat count>] = should be an optional argument.
*EDIT*
I updated the file attached in the first thread.. cleaned the code up a bit.
*EDIT*
Ok.. let's call this the final update.. I added even more things to the v0.7.0
I incorporated some fixes:
* created plugin.__init__ for AddAction (should not be added in in the __start__)
* added event.Skip() to the event handlers (to enable apply button)
* assigned Text to plugin.text, so the strings are translatable.
* changed wx.SpinCtrl to eg.SpinIntCtrl (wx.SpinCtrl has some limits)
* changed action class to eg.ActionClass (was already no eg.ActionWithStringParameter anymore)
* raise self.Exception in __call__ instead of "print". Looks nicer in the log.
There remains a small bug if you have no remotes if you have no connect to LIRC. It raises an IndexError if you change a control.
I might have used the version before (I saw the second EDIT to late), so the last changes might not be in it. Do you want to have SVN access, to avoid this in the future?
Please post software-related questions in the forum - PMs will only be answered, if really private, thanks!
Ok.. I just committed a new version to the svn, I assume this version will be present in the next beta. (above build 1258)
I attended all the issues you brought up in the previous message.
Except:
* event.Skip() - which isn't neccessary, the apply button is updated correctly as is. (just tested using the -debug cmdline switch)
* wx.SpinCtrl to eg.SpinIntCtrl - I chose to use wx.SpinCtrl instead as it gets the job done just fine. For some reason I couldn't work out how to bind EVT_SPINCTRL (or equivalent) for the eg.SpinIntCtrl when I tried it.
jinxdone wrote:
* wx.SpinCtrl to eg.SpinIntCtrl - I chose to use wx.SpinCtrl instead as it gets the job done just fine. For some reason I couldn't work out how to bind EVT_SPINCTRL (or equivalent) for the eg.SpinIntCtrl when I tried it.
wx.SpinCtrl doesn't validate. But you are right, the event binding is missing in eg.SpinIntCtrl. I will fix this later...
Please post software-related questions in the forum - PMs will only be answered, if really private, thanks!
Ok, eg.SpinNumCtrl and eg.SpinIntCtrl now generate an eg.EVT_VALUE_CHANGED event if their value changes. So this is the event to bind to:
repeatCtrl.Bind(eg.EVT_VALUE_CHANGED, OnRepeatSpin)
Please post software-related questions in the forum - PMs will only be answered, if really private, thanks!
I see you made all the neccessary changes already. (svn sure is handy )
As soon as it ships out along with the next beta i'd love to hear from anybody who can test sending some events with Lirc running on a *nix incase there are any problems with it.
A user in the german forum has reported a problem with the LIRC plugin some time ago. If the computer goes into suspend state, the connection to the LIRC server is lost or at least doesn't work anymore. I had implemented a fix by overriding OnComputerSuspend and OnComputerResume to re-establish the connection, but this fix got lost somewhere.
jinxdone wrote:Ok. I just committed a new version which adds handling for suspend/resume. Basically just shut down the reader on suspend and restart it on resume
I'm using the LIRC plugin with a IRTrans.
After resuming from Standby the plugin tells me that no remote are found and stops working. It worked fine before.
It worked fine when I tested it, allthough I had it set to connect to another machine on my lan, not something running on localhost.
Probably the cause is that lirc -plugin tries to reconnect before the server is up. If you want to try a little debugging you could add a time.sleep() in there to test if it helps.
I can try this, but I'm currently not near the computer. I was confused about the error messages about no configured remotes.
I would have expected a message about the inability to connect but I'm not familiar with the lirc protocol.
Have you thought about an option which lets the plugin try to connect every x seconds?
I had this message even on a remote machine which had a fresh reboot. I also got the same message connecting to the LIRC server (which came out of standby a few minutes before).
The events showed up fine when connecting with a telnet application.
What is reason for the "no remotes found" message? Do you issue an command to the LIRC Server and expect some kind of answer?
It also might be a flaw in the IR-Trans LIRC Server.
The reason is that it tries to fetch all remote and button/event data from the server so that you can easily use it for sending events. I attached an example of it at work.
I will add a checkbox to disable/enable this feature as disabling it should speed up the plugin startup by a few seconds if it's not supported.