Joystick calibration under linux



I don’t know off the top of my head of a graphical joystick calibrator for linux, but there is a command line utility that’s dead easy to use…. jscal I found the tip in a flightgear mailing list after having a hard time with one of the first flights. The stick was very far off center, I had to pull almost all the way to the right to keep level. Anyway… here’s the tip.


Joysticks are calibrated at the kernel level. So, for instance, a program like flightgear looks at the device and doesn’t have a means for adjusting the data to correct for centering. It just assumes what it sees is accurate. So, here’s how to calibrate.

jscal -c /dev/js0

This will have you move the 0-axis to it’s minimum, center, maximum, then axis-1, etc. etc. etc. The only trick can be guessing which axis you need to use if you have more than 2. The other point to mention here is that if there are more axis’ detected than you have it’s ok. Just follow the instructions and if there’s no change on an axis, keep pressing a button to move through. It’s really fairly easy to use.

But what happens after a reboot? You lose the calibration… UNLESS…. you do this.

jscal -p /dev/js0 > calibrate-stick.sh

Which prints out your calibration information to a file, then after the next boot. (Maybe in a login script?)

sh calibrate-stick.sh

the above will “recalibrate” based on the settings that you’ve just assigned.

Some distros may deal with this, I suspect there may be GUI frontends for this, but it was the quickest route I had to getting to fly straight and level.

Related Posts

Blog Traffic Exchange Related Posts
  • chkconfig for ubuntu or other debian based linux systems As I've mentioned I've got an ubuntu based test system. Most of my linux experience has been from a red-hat derivitive-based background and for that, at the command line, you have chkconfig which is a good tool for checking the configuration of services to run at startup. It is a......
  • Remote Tech Support with x11vnc and wrapper script So, the idea is that I wanted something "like" the Ultranvnc Single Click download, only for linux. The main idea being is that if someone is looking for a bit of desktop tech support on linux, we don't need to be giving instructions for 5 different package managers, or source......
  • Remote Tech Support using VNC (Ultravnc SC and x11vnc+wrapper script) Ok, some time back I'd done a writeup on UltraVNC SC, which is a nice customizable (windows version) VNC server that essentially let's someone doing remote support build their own downloadable .exe that runs and automatically tries to make a direct connection to a "listening" vnc viewer. It's good for......
Blog Traffic Exchange Related Websites
  • Tool Box Essentials pt 1 It does not matter where you are living, or whether you are renting or owning your home. If you have four walls as well as a roof, then you are eventually going to have something that requires repairing, installing or updating. Having the right tools makes all the difference in......
  • Tech Support - Funny Video Series While surfing through Youtube, I stumbled across this fun-filled tech support video series. All of the videos are sure to give you good amount of chuckle. I liked all of them, but first one is my favorite. Surely a stress buster after a bad day in office :) Enjoy! Tech......
  • Joining Running Groups for Fun and More For many people, there is nothing more they need from running than the shear thrill of running. Others run for the exercise but take no special joy in it. Others still seek to run on a more competitive level. No matter what you are looking to get out of running,......
www.pdf24.org    Send article as PDF   

Similar Posts


See what happened this day in history from either BBC Wikipedia
Search:
Keywords:
Amazon Logo

Comments are closed.


Switch to our mobile site