uweschmidt.org

nothing too important

Wiimote Logger

This application can log acceleration data and button presses of multiple Wiimotes at the same time. It was designed to do experiments where motion is recorded by one or more Wiimotes. The A & B buttons can be used to mark certain events such as the start or end of an experiment.

The software has been developed and only briefly tested on Mac OS X. It should, however, work on Windows and Linux too. Linux users need to put in a little more effort to make it work. Otherwise, the requirements are almost identical to my Wiimote Whiteboard application. Let me know if you have problems or find any bugs.

Download (0.2)

10 Responses

  1. J Almer says:
    WiimoteLogger and Ubuntu

    Hello,

    the Whiteboard ist great work.
    Unfortunately i cannot use the WiimoteLogger under Ubuntu 9.04.
    I copied with zip the bluecove already into the WiimoteLogger.jar, described for WiiWhiteboard but the start fail.

    SCHWERWIEGEND: Application class org.uweschmidt.wiimote.logger.WiimoteLogger failed to launch
    java.lang.IllegalStateException: Bluetooth failed to initialize. There is probably a problem with your local Bluetooth stack or API.

    Can you help me

  2. Uwe says: in reply to J Almer
    Re: WiimoteLogger and Ubuntu

    Hi,

    I just checked WiimoteLogger.jar and realized that I created it in a different way (in comparison to Wiimote Whiteboard). Try starting Wiimote Logger like that:

    java -cp bluecove-gpl-2.0.3.jar -jar WiimoteLogger.jar

    Uwe

  3. J Almer says: in reply to Uwe
    Re: WiimoteLogger and Ubuntu

    Thanks for your help,

    but still the programm doesn’t start. I can connect the wiimote via bluetooth described in http://wiki.ubuntuusers.de/Wiimote but

    sudo java -cp bluecove-gpl-2.1.0.jar -jar WiimoteLogger.jar

    (i tried with and without sudo and also the bluecove-gpl-2.0.3.jar as you suggested)

    always ends with a lot of failures.
    Caused by: javax.bluetooth.BluetoothStateException: BlueCove com.intel.bluetooth.BluetoothStackBlueZ not available
    SCHWERWIEGEND: Application class org.uweschmidt.wiimote.logger.WiimoteLogger failed to launch
    java.lang.IllegalStateException: Bluetooth failed to initialize. There is probably a problem with your local Bluetooth stack or API.

  4. Uwe says: in reply to J Almer
    Re: WiimoteLogger and Ubuntu

    Hi,

    Thanks for your help, but still the programm doesn’t start.

    I was just guessing that it might work. After starting my dusty linux box and actually trying it myself, I found this to be working:

    java -cp bluecove-gpl-2.0.3.jar:WiimoteLogger.jar org.uweschmidt.wiimote.logger.WiimoteLogger

    Uwe

  5. J Almer says: in reply to Uwe
    Re: WiimoteLogger and Ubuntu

    On my Ubuntu system it still hangs.

    I tried sun-java (java-6-sun-1.6.0.13) and open java but the error remains.
    My system is Ubuntu 9.04 with the above mentioned java versions.

    Native Library bluecove not available
    19.05.2009 17:43:24 org.jdesktop.application.Application$1 run
    SCHWERWIEGEND: Application class org.uweschmidt.wiimote.logger.WiimoteLogger failed to launch
    java.lang.IllegalStateException: Bluetooth failed to initialize. There is probably a problem with your local Bluetooth stack or API.

    Currently i’am using gtkwhiteboard and wminput and there is no connection problem.

    For me the WiimoteLogger would enhance my physics lessons tremendously.

    Thanks for your work and help.

  6. Uwe says: in reply to J Almer
    Re: WiimoteLogger and Ubuntu

    Hi,

    I tried sun-java (java-6-sun-1.6.0.13) and open java but the error remains.
    My system is Ubuntu 9.04 with the above mentioned java versions.

    I’m running Ubuntu 8.04 with Java (Sun) version 1.6.0_07 on a 32-bit machine.
    I found this post which may the explanation for your problem.

    I made a new release that uses BlueCove 2.1 (and the newer WiiRemoteJ 1.6a). It should be started like this:
    java -cp bluecove-gpl-2.1.0.jar:WiimoteLogger.jar org.uweschmidt.wiimote.logger.WiimoteLogger

    Uwe

  7. J Almer says:
    It is working now! Great Work ;-)

    Thanks for your help.

    as normal user it is still not working correctly
    java -cp bluecove-gpl-2.1.0.jar:WiimoteLogger.jar org.uweschmidt.wiimote.logger.WiimoteLogger
    24.05.2009 19:45:21 com.sun.corba.se.impl.ior.IORImpl getProfile
    WARNUNG: "IOP00511201: (INV_OBJREF) IOR must have at least one IIOP profile"

    but as sudo it works fine. (normal user can’t save data to a file)

    Now i have the next problem, because i am a german user, the comma is used as decimal separator and you use it as a field seperator.
    data looks like that:

    0,019, 1, -0,222222, 0,189474, 0,932039, 0, 0
    0,081, 1, -0,244444, 0,168421, 0,970874, 0, 0

    it is no real problem to import it to openoffice using fixed width, but it is a bit harder to use tools like gnuplot.
    Is there a possibility to use tabs or semicolon as field seperator?

    Thanks J. Almer

  8. Uwe says: in reply to J Almer
    Re: It is working now! Great Work ;-)

    Hi,

    as normal user it is still not working correctly [..] but as sudo it works fine. (normal user can’t save data to a file)

    that’s odd, maybe you don’t have the permissions for the folder you want to save the file to.

    Is there a possibility to use tabs or semicolon as field seperator?

    Yes, it’s defined in WiimoteDataHandler.java in line 66: private static final String SEP = ", ";

    So you could just download the source code, change SEP to whatever you like and compile & start the app with the included Ant build script. I don’t really want to make a new release just because of that.

    An easier solution would be to just change the locale to English to get a point instead of a comma as decimal separator:

    java -Duser.language=en -cp bluecove-gpl-2.1.0.jar:WiimoteLogger.jar
    org.uweschmidt.wiimote.logger.WiimoteLogger

    Uwe

  9. J Almer says: in reply to Uwe
    Re: It is working now! Great Work ;-)

    The trick with the locale is working fine.

    There was a mistake in my failure description.
    WiimoteLogger is also working for a normal user, but sometimes it doesn’t connect correctly to the Wiimote and then you can’t see the battery status.
    But a new start normally fix the problem (no user problems)

    Thanks for all your help and for the fantastic programm.

  10. Uwe says: in reply to J Almer
    Re: It is working now! Great Work ;-)

    Hi,

    WiimoteLogger is also working for a normal user, but sometimes it doesn’t connect correctly to the Wiimote and then you can’t see the battery status.
    But a new start normally fix the problem (no user problems)

    I’ve been experiencing the same thing. Maybe it is due to the bluecove-gpl-2.1.0.jar.

    Uwe

Leave a Reply