New (Minor) MythPyWii Release (r15)
Thanks to a heads up from Sam, I have updated the MythPyWii script with better error handling and more informative feedback messages. Hopefully now when you run the script you will know what to do! I’ve also fixed a few minor bugs in the documentation.
As always, you can download the latest version of MythPyWii here.
I should probably make a GUI for MythPyWii at some point… though it seems a little pointless at the moment. I could allow you to change the controls to your liking, I spose…
UPDATE: If you’re getting errors like:
$ myth_py_wii.py
Please open Mythfrontend and then press 1&2 on the wiimote…
Connected to a wiimote
Logged in to MythFrontend
TypeError: wmcb() takes exactly 2 arguments (3 given)
TypeError: wmcb() takes exactly 2 arguments (3 given)
TypeError: wmcb() takes exactly 2 arguments (3 given)
TypeError: wmcb() takes exactly 2 arguments (3 given)
Then you have a more up to date version of cwiid than me. The fix is simple – change line 141:
def wmcb(self, messages):
to:
def wmcb(self, messages, timeIgnore):
Thanks to Mike H for pointing out this issue.
Related articles by Zemanta
Tags: documentation, error handling, feedback, MythPyWii

![Reblog this post [with Zemanta]](http://img.zemanta.com/reblog_c.png?x-id=cee41f52-af92-4108-aa88-c7472551c21d)
January 19th, 2009 at 11:55 pm
Hi Benji,
Do I need to always manually run the script then the mythtv frontend in order to activate the Wii remote? If yes, it is possible to add to do when mythtv is booting up?
Clarence
January 20th, 2009 at 2:02 pm
Hi Clarence,
Yes it is possible to run the script at the same time as you run mythfrontend – I do so by modifying my mythfrontend shell script script and running MythPyWii using screen. In Ubuntu, open a terminal and run the following commands:
sudo apt-get install screen; sudo gedit /usr/bin/mythfrontend
Then I add to the first blank line (line 4 for me):
/usr/bin/screen -d -m /usr/bin/python /home/crayzee/Desktop/myth_py_wii.py
You’ll have to do this whenever you update mythfrontend. Another way to do it is to create a new script (e.g. “~/launchmyth.sh”) which contains something like this:
#!/bin/bash
/usr/bin/screen -d -m /usr/bin/python /home/crayzee/Desktop/myth_py_wii.py
/usr/bin/mythfrontend
And then run that instead of “mythfrontend” (e.g. “bash ~/launchmyth.sh”).
I hope this helps,
Kind regards,
Benjie.
April 27th, 2009 at 6:32 pm
It worked!! Thank you.
April 27th, 2009 at 9:19 pm
Awesome
July 2nd, 2009 at 11:10 pm
I’ve updated the post with the fix for more recent versions of cwiid. I have not updated the source because I still use the old cwiid code… Thanks to Mike H for pointing this out.
September 15th, 2009 at 10:58 pm
[...] http://www.benjiegillam.com/2008/09/new-minor-mythpywii-release-r15/#comments [...]
November 27th, 2009 at 6:36 pm
Hi,
Works great thank you. However, I liss one important functionality ! I would like to be able to use the mouse pointing function with a sensor bar when playing with mythbrowser. I tested this with wminput and it works ok, but wminput is not as attractive as mythpywii. If you could add this fuinctionality to your program it would be great, we could then use the wiimote to surf using mythweb, provided of course, there is an external sensor bar !
Regards