The Octave joystick package provides basic joystick read/write functions
-
Octave >= 4.0.0+
-
SDL >= 1.2 (SDL1, 2 and 3 should work, but requires the dev headers to be installed)
*NOTE: in fedora, the joysick drivers must be enabled so that it will load them:
dnf install joystick-support*
sudo usermod -a -G input username
To install, run the octave package manager:
-
If running Windows, the package may already be installed:
pkg list joystick -
To install with an internet connection available:
pkg install -forge joystick -
To install from a local tarball.
pkg install joystick-XXXXXXX.tar.gzWhere XXXXXXX is the version of the the downloaded tarball.
-
Load the package.
pkg load joystick(Required each time Octave is started)
-
List available joystickes
vrjoysticklist -
Get a joystick to manipulate using the id
joy = vrjoystick(1)