As i wrote some days ago, I planned on doing some hack so control KStars with a Wiimote.
It turned out KStars isn’t the right target, as it seems to have no plug-in support (and I don’t want to modify core yet, as i’m still in an experimental phase).
But reading data from wiimote and correctly interpreting was already done some days ago, thought it was a little bit hard, so I switched to Stellarium instead.
This is the result:
Of course it’s just experimental code, it’s barely usable.. but it’s a start.
Source is here: https://github.com/rockman81/StellariumWiimotePlugin
Now some technical stuff:
The Wiimote gyro sensors aren’t easy to read, as they don’t send you current angle, but only
It doesn’t report current angle, instead it does report angular speed.
But afterall you can deduce current angle just dividing speed by elapsed time between each message report.
I had to do some tries before finding the proper way of “moving view window” on Stellarium.
It’s not so well documented, and i’m not exactly happy about current solution, but it works, and i’ll ask some help in their mailing list soon.
This solution anyway is easier than i thought, as it only receives as input angles delta, meaning it’s also easy to “align” your telescope to stellarium (just point an object with telescope, then manually point stellarium to that object).
What’s missing: