• Welcome to Overclockers Forums! Join us to reply in threads, receive reduced ads, and to customize your site experience!

Attn: Wacom Tablet Users

Overclockers is supported by our readers. When you click a link to make a purchase, we may earn a commission. Learn More.
The version below should be compatible with X.Org 7.3 if you're running it.

I've upgraded to linuxwacom 0.7.9-8 and the 2.6.23-gentoo-r9 kernel and jTablet is still compiling and running just fine for me...

JigPu
 

Attachments

  • jtablet-sdk-v0.9.5_linux14.zip
    414.9 KB · Views: 231
I've upgraded to 7.9-8 (including the kernel driver), which is working a little funny for me, and wacomcpl doesn't work. Anyways, still same issue, I've posted my xorg.conf as of the latest test. It has some extra stuff in there, mostly commented, as I've been trying to get another tablet working, thats supported as of this build. I should note that I have two tablets plugged in and the wacom driver seems to do its own autodetecting... However, this is the first time the second device has had the wacomdriver (ie /proc/bus/usb/devices), with identical results from the jtablet driver. Therefore, it shouldn't be the issue.

Additional version info:
Kernel 2.6.24.3
X.Org X Server 1.4.0.90


Code:
# nvidia-xconfig: X configuration file generated by nvidia-xconfig
# nvidia-xconfig:  version 1.0  (buildmeister@builder26)  Thu Feb 14 18:13:41 PST 2008

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0"
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    #InputDevice    "stylus"
    InputDevice    "stylus" "SendCoreEvents"
    InputDevice    "cursor" "SendCoreEvents"
    InputDevice    "eraser" "SendCoreEvents"
    #InputDevice    "pad"
EndSection

Section "Files"
    RgbPath         "/usr/lib/X11/rgb"
EndSection

Section "Module"
    Load           "dbe"
    Load           "extmod"
    Load           "type1"
    Load           "freetype"
    Load           "glx"
    Load           "wacom"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "keyboard"
EndSection

Section "InputDevice"
    Driver        "wacom"
    Identifier    "stylus"
    #Option        "SendCoreEvents" "true"
    Option        "USB "         "on"
    Option        "Device"        "/dev/input/tablet-intuos2-9x12"
    #Option        "Device"        "/dev/ttyS0"          # Change to
                                                      # /dev/input/event
                                                      # for USB
    Option        "Type"          "stylus"
    #Option        "ForceDevice"   "ISDV4"               # Tablet PC ONLY
    Option "DebugLevel" "11" 
EndSection

Section "InputDevice"
    Driver        "wacom"
    Identifier    "eraser"
    Option        "USB "         "on"
    Option        "Device"        "/dev/input/tablet-intuos2-9x12"
    #Option        "Device"        "/dev/ttyS0"          # Change to
                                                        # /dev/input/event
                                                        # for USB
    Option        "Type"          "eraser"
    #Option        "ForceDevice"   "ISDV4"               # Tablet PC ONLY
EndSection

Section "InputDevice"
    Driver        "wacom"
    Identifier    "cursor"
    Option        "USB "         "on"
    Option        "Device"        "/dev/input/tablet-intuos2-9x12"
    #Option        "Device"        "/dev/ttyS0"          # Change to
                                                        # /dev/input/event
                                                        # for USB
    Option        "Type"          "cursor"
    #Option        "ForceDevice"   "ISDV4"               # Tablet PC ONLY
EndSection

#Section "InputDevice"
#    Driver        "wacom"
#    Identifier    "pad"
#    #Option        "Device"        "/dev/ttyS0"          # SERIAL ONLY
#    Option        "Device"        "/dev/input/tablet-cintiq20wsx"
#    Option        "Type"          "pad"
#    Option        "USB"           "on"                  # USB ONLY
#EndSection

Section "Monitor"
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Unknown"
    HorizSync       30.0 - 110.0
    VertRefresh     50.0 - 150.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    Option         "NoLogo" "True"
    Option         "RandRRotation" "1"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    SubSection     "Display"
        Depth       24
        #Virtual     2560 2560
    EndSubSection
EndSection

Section "Extensions"
    Option         "Composite" "Enable"
EndSection

linux14
Code:
 make test_applet2
cd ../examples && appletviewer JTablet-test2.html
using java 2! (v1.4+!)
Closing all known tablets.
Tablet(s) closed.
Connected to X server.
Enumerating devices...
Found: deviceInfo[0].name = Virtual core keyboard, type = 0, id = 0
Constructing new TabletDevice (id = 0, type = 0)
Constructing new WacomDevice (id = 0, type = 0)
Not an extension device!
Name does not match one of recognized types.!
Found: deviceInfo[1].name = Virtual core pointer, type = 0, id = 1
Constructing new TabletDevice (id = 1, type = 0)
Constructing new WacomDevice (id = 1, type = 0)
Not an extension device!
Name does not match one of recognized types.!
Found: deviceInfo[2].name = stylus, type = 210, id = 2
Constructing new TabletDevice (id = 2, type = 210)
Constructing new WacomDevice (id = 2, type = 210)
Not an extension device!
Found: deviceInfo[3].name = Mouse0, type = 90, id = 3
Constructing new TabletDevice (id = 3, type = 90)
Constructing new WacomDevice (id = 3, type = 90)
Not an extension device!
Mouse not supported.
Name does not match one of recognized types.!
Found: deviceInfo[4].name = Keyboard0, type = 89, id = 4
Constructing new TabletDevice (id = 4, type = 89)
Constructing new WacomDevice (id = 4, type = 89)
Not an extension device!
Name does not match one of recognized types.!
No tablet(s) detected.
cello.tablet.JTabletException: Could not initialize tablet.
	at cello.tablet.JTablet.initializeTablet(Native Method)
	at cello.tablet.JTablet.<init>(JTablet.java:84)
	at cello.tablet.JTablet.<init>(JTablet.java:72)
	at cello.tablettest.JTablettest2.init(Unknown Source)
	at sun.applet.AppletPanel.run(AppletPanel.java:419)
	at java.lang.Thread.run(Thread.java:619)
java.lang.NullPointerException
	at cello.tablettest.JTablettest2.init(Unknown Source)
	at sun.applet.AppletPanel.run(AppletPanel.java:419)
	at java.lang.Thread.run(Thread.java:619)

btw, this could just be a coincidence, but this time around in Sketcher i don't get "JTablet Detected" or the checkbox, however, I still get the tablet searching bits
Code:
Closing all known tablets.
Tablet(s) closed.
Connected to X server.
Enumerating devices...
Found: deviceInfo[0].name = Virtual core keyboard, type = 0, id = 0
Constructing new TabletDevice (id = 0, type = 0)
Constructing new WacomDevice (id = 0, type = 0)
Not an extension device!
Name does not match one of recognized types.!
Found: deviceInfo[1].name = Virtual core pointer, type = 0, id = 1
Constructing new TabletDevice (id = 1, type = 0)
Constructing new WacomDevice (id = 1, type = 0)
Not an extension device!
Name does not match one of recognized types.!
Found: deviceInfo[2].name = eraser, type = 210, id = 2
Constructing new TabletDevice (id = 2, type = 210)
Constructing new WacomDevice (id = 2, type = 210)
Not an extension device!
Found: deviceInfo[3].name = cursor, type = 211, id = 3
Constructing new TabletDevice (id = 3, type = 211)
Constructing new WacomDevice (id = 3, type = 211)
Not an extension device!
Found: deviceInfo[4].name = stylus, type = 212, id = 4
Constructing new TabletDevice (id = 4, type = 212)
Constructing new WacomDevice (id = 4, type = 212)
Not an extension device!
Found: deviceInfo[5].name = Mouse0, type = 90, id = 5
Constructing new TabletDevice (id = 5, type = 90)
Constructing new WacomDevice (id = 5, type = 90)
Not an extension device!
Mouse not supported.
Name does not match one of recognized types.!
Found: deviceInfo[6].name = Keyboard0, type = 89, id = 6
Constructing new TabletDevice (id = 6, type = 89)
Constructing new WacomDevice (id = 6, type = 89)
Not an extension device!
Name does not match one of recognized types.!
No tablet(s) detected.
Closing all known tablets.
Tablet(s) closed.
 
Last edited:
Your xorg.conf appears to be fine, so something else is the problem...

I've attached a new version for you to try. I've modified quite a bit of the structure to make things cleaner (making .h files for each class, seperating the Win32 and X11 files, etc), and have made a few changes to the class itself (more debugging output, temporarily allowing non-extension devices, tweaking the XIsPointerExtension detection, etc).

This version will get past the "Not an extension device!" error that you've seeing. I'm not sure why it's not being detected as one, so I'm temporarily skipping that check to see what other bugs may be lurking.

~~~~~~~~~~~~~

Because of the restructuring I've done, you'll want to delete your existing jTablet directory before extracting. The makefiles are different as well, so you might not be able to run the following any more:
Code:
$ make
# make install
$ make test_applet2
The reason is that "make install" and "make uninstall" now call both the JDK- and JRE-specific targets in X11/Makefile (to hopefully fix the problem some people have had with their browser using the JRE instead of the JDK). If you've only got one of the two in your chroot, a generic "make install" will fail. Instead, you could run the following:
Code:
$ make
$ cd X11
# make JDKinstall
$ cd ..
$ make test_applet2
This will still compile all the code, but only copy the .so and .jar to the JDK specified in $JDK_HOME. JDKinstall (along with JDKuninstall, JREinstall, and JREuninstall) are now only valid targets in the X11 directory's makefile.

JigPu
 

Attachments

  • jtablet-sdk-v0.9.5_linux15.zip
    469.5 KB · Views: 248
Woohoo :) This version seems to work in Sketcher! It may be worth it to note that I've also upgraded to linuxwacom 7.9-9, X and kernel driver.

I have attached two error.txts for your viewing though. One is slightly incomplete, grabbed from terminal history but it seems to have encountered an error that my other runthroughs have not.

Thanks for all your effort, both you and opensource rock :D

I also had a JVM crash due to libjtablet.so which brought down FF, but I have a funky wireless driver and was unable to capture it for you.
 

Attachments

  • jtabletapplet2.png
    jtabletapplet2.png
    15.4 KB · Views: 566
  • error.txt
    42 KB · Views: 78
  • error2.txt
    24.7 KB · Views: 70
Last edited:
Awesome! It looks like pen tilt is even working based on the screenshot! :) With the Graphire4 not having tilt abilities I wasn't at all sure of what kind of output to expect.

Could you describe how the values change as you tilt the pen in various ways? The jTablet library wants me to convert all values into altitude/azimuth with tilt, and the LinuxWacom documentation says nothing about what I'm actually being passed... If you don't mind, report the alt/azi/tilt values for each of the following configurations:

* Pen held vertical, rotated 0 degrees (e.g., stylus buttons facing the top of the tablet)
* Pen held vertical, rotated +90 degrees (e.g., stylus buttons facing the right of the tablet)
* Pen tilted ~22.5 degrees toward the top of the tablet (halfway between vertical and 45 degrees), rotated 0 degrees
* Pen tilted ~22.5 degrees toward the top of the tablet, rotated +90 degrees
* Pen tilted ~45 degrees toward the top of the tablet, rotated 0 degrees
* Pen tilted ~45 degrees toward the top of the tablet, rotated +90 degrees
* Pen tilted ~45 degrees toward the top of the tablet, rotated -90 degrees
* Pen tilted ~45 degrees toward the right of the tablet, rotated 0 degrees
* Pen tilted ~45 degrees toward the bottom of the tablet, rotated 0 degrees
* Pen tilted ~45 degrees toward the left of the tablet, rotated 0 degrees
* Pen eraser side down in each of the above configurations

That should be enough data to figure out what I'm being handed, and what conversions (if any) are needed to put it into alt/az/tilt form.

~~~~~~~~~
Looking through the logs, it appears that your tablet's "use" value is "IsXExtensionKeyboard" instead of "IsXExtensionPointer" or "IsXExtensionDevice"... Why the driver sets it up as a keyboard is beyond me, but now that I know what's going on, I can expect it :D

The NullPointerException you got in error2.txt I've seen before, but haven't bothered to track down. I'm not sure if its a bug in the Java examples, or something which manifests itself due to a bug in my native code. With the stack trace not provdiding the line number of the problem it's a little difficult to figure out what's going wrong, but hopefully not overly so.

As for the JVM crash, I started noticing the same thing with this latest version as well. The intermittant behavior makes it hard to track down, but based on the kind of crash I get (sometimes just the JVM dies, sometimes glibc stops execution with its own warning) it appears to be a memory corruption issue, meaning that I'm probably doing bad things with pointers...

JigPu
 
Last edited:
Rotation doesn't seem to matter, I have the 6d art pen but my rotation capable tablet isn't working under linux yet. I can get you those sorts of values when it does.

The values flicker, so I've made them as 'perfect' as possible.

Vertical: 0, 0 ,0
22.5 to Top, 0, -25, 0 (hmm, actually, you could probably correlate -22, to 22degrees, etc from this data, my OCPD is probably why i want to make it -25)
45 Top: 0, -45, 0
45 Right: 45, 0 , 45
45 Bottom: 0, 45, 0
45 Left: -45, 0 -45

Eraser Side reflects the same values.

It seems as if Azi, Twi is the "x axis" and alt is the "y", in such a way that the values correspond to the degrees at an origin of completely vertical orientation.
 
Getting the values translated to alt/az is proving to be far more difficult than I had initally suspected. I know of a way to do it with linear algebra, but I'd either need to write several hundred lines just to do the conversion (bleh) or find a library that will solve under-determined systems of equations (no luck yet).

Curiously, the Windows version of the code doesn't appear to be doing any conversion at all... I'm not sure if this is because the tablet natively returns alt/az information (and X11 translates it into x-tilt/y-tilt for no good reason), or if he miswrote the library spec. I'm going to write to him to see what's up... I'd love to not convert if I don't have to, with how difficult its being :D

EDIT:Nevermind. I just thought to google the function he was using, and it appears that the Windows Wacom drivers return alt/az information. This is not going to be fun to implement... :(

JigPu
 
Last edited:
I've attached a new version to the first post which should correctly provide alt/az tilt information. The altitude should be 90 when the stylus is straight up, and report decreasing values as it becomes closer to horizontal. The azimuth information should be 0 when the stylus is tilted toward the top of the tablet, and increase through 359 as you move it in a clockwise circle.

I realized that I could do 95% of the work offline and just transfer the resulting formulas into the program. I initially feared the formulas would be really complex, but they're actually pretty simple...

Thanks so much for helping me debug this nothlit... I've added a mention in the XWacomTablet comments for all your work :)

JigPu
 
The Azi starts a 0 at the bottom, and increases the 359 COUNTER-clockwise. The Alt is just weird... but it actually goes over 110 and down to about 60, i suppose you could roughly say that the vertical position gives the highest value, but it doesn't seem reliable and really fluctuates.
 
OK, I'm back again with another puzzler. Ubuntu 8.04, wizardpen driver works perfectly. I'm getting pressure in GIMP. newest jtablet compiles fine, and installs fine (after the JDK/JAVA_HOME variable settings), but pressure in the test applet, and in sketcher do not work. The test applet gives the following:
using java 2! (v1.4+!)
Closing all known tablets.
Tablet(s) closed.
Connected to X server.
Enumerating devices...
Found: deviceInfo[0].name = Virtual core keyboard, type = 0, id = 0
Constructing new TabletDevice (id = 0, type = 0)
Constructing new WacomDevice (id = 0, type = 0)
Not an extension device!
Name does not match one of recognized types.!
Found: deviceInfo[1].name = Virtual core pointer, type = 0, id = 1
Constructing new TabletDevice (id = 1, type = 0)
Constructing new WacomDevice (id = 1, type = 0)
Not an extension device!
Name does not match one of recognized types.!
Found: deviceInfo[2].name = Generic Keyboard, type = 89, id = 2
Constructing new TabletDevice (id = 2, type = 89)
Constructing new WacomDevice (id = 2, type = 89)
Not an extension device!
Name does not match one of recognized types.!
Found: deviceInfo[3].name = Configured Mouse, type = 90, id = 3
Constructing new TabletDevice (id = 3, type = 90)
Constructing new WacomDevice (id = 3, type = 90)
Not an extension device!
Mouse not supported.
Name does not match one of recognized types.!
Found: deviceInfo[4].name = stylus, type = 216, id = 4
Constructing new TabletDevice (id = 4, type = 216)
Constructing new WacomDevice (id = 4, type = 216)
Not an extension device!
No tablet(s) detected.
cello.tablet.JTabletException: Could not initialize tablet.
at cello.tablet.JTablet.initializeTablet(Native Method)
at cello.tablet.JTablet.<init>(JTablet.java:84)
at cello.tablet.JTablet.<init>(JTablet.java:72)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at java.lang.Class.newInstance0(Class.java:355)
at java.lang.Class.newInstance(Class.java:308)
at cello.tablettest.JTabletSurface.initialize_tablet(Unknown Source)
at cello.tablettest.JTabletSurface.<init>(Unknown Source)
at cello.tablettest.JTablettest.initialize(Unknown Source)
at cello.tablettest.JTablettest.run(Unknown Source)
at java.lang.Thread.run(Thread.java:619)
Closing all known tablets.
Tablet(s) closed.



I've tried setting the InputDevice identifier as 'stylus' and as the default, to no avail. It just won't initialize. It worked fine under 7.10 before. Something's weird here. Maybe wizardpen support got compiled out?
 
After re-reading the posts above, I got it to work, however pressure only works partially. Randomly, it gains pressure mid-stroke, or loses it mid-stroke, and with the test applet 2, it just shut down any time I pen-down (like in 7.10). Help?
 
On even closer inspection, pen pressure seems to be 'lagging' in sketcher. Pressure eventually corrects to the correct pressure, but always around 15 seconds later. IE, if I press hard, and draw, after 15 seconds of drawing, then finally the pressure will be there. If I let up after 5, it'll draw hard for 10 seconds, and then light for 5, etc. Very, very weird, since it doesn't do it in test_applet (test_applet2 crashes), nor in GIMP.
 
Sorry 'bout the delay in replying -- I've been pretty busy with school lately, and haven't had time to keep up...

~~~~~
nothlit: Thanks for the description of the alt/az behavior. I think I just got my coordinate systems slightly screwed up, leading to the weird values. As for the jumpyness, it *might* be a limitation of the Wacom hardware (or, yet another artifact of my wonky coordinate system :D). You could check to see if the values jump around in a similar way with the Windows version of JTablet.

When I get some time, I'll post a version with the corrected coordinate system.

~~~~~

Marupa: I'm not sure what's going on, but the descriptions sound vaguely reminiscant of a problem I was having with tablet buttons a few versions back. Essentially button events were being discarded because test_applet had JTablet discarding all but the latest event. Unless you got lucky, the latest event wasn't a button event, so buttons would appear to be stuck in one state.

With you stating that pressure is actually lagging, its not the same problem. And its even weirder considering that Sketcher is probably (since its the default behavior) set to discard all but the latest event! :confused: I'll need to do quite a bit of thinking on this one...

In the meantime, could you post up a log of test_applet2 crashing, and of test_applet running? I'd like to see if I could find the reason for your crash on pen-down in one applet but not the other...

JigPu
 
I've uploaded a new version. This one will hopefully display the correct alt/az values... I was never too good at trig, and that small chunk of code is pretty much nothing but trig :D

~~~~~

I tried to verify that Sketcher is discarding old events (which could explain the odd pressure problems), but it appears that ArtGrounds is down for maintenence. In its stead, I looked at Oekaki Shi-Painter and Lascaux Sketch (both can be used at 2draw.net). Both applets discard all but the latest event, so they'd be the least likely to exhibit lag.

It *might* be a problem with the debug messages making everything go slower. Older versions of my code were really bad about this, and even the newest isn't all that great (since I'm still doing a lot of debugging :D). If you're using an older computer, it could be the source of a lot of slowness and jitter. You can disable debugging by editing a single line in c++src/X11/Makefile:

Code:
DEBUGMODE = 1
Should be changed to:
Code:
#DEBUGMODE = 1

This will disable debug statements which will significantly improve performance (and possibly get rid of the lag). After changing that line, clean all the old build files with make clean and uninstall JTablet with make uninstall. Double check that ALL copies of libjtablet.so are gone by running locate libjtablet.so and delete any found copies manually. Once that's done, you can rebuild JTablet according to the instructions in the first post and try again.


EDIT: You might also try running Sketcher/Shi-Painter/Lascaux in a different browser like Epiphany or Konquerer. While doing testing in the last two I got fed up with not being able to use Opera (for quite some time now it'd crash on *ANY* page with Java... I've been doing all my testing in another browser) and found a fix for it. After fixing Opera, I discovered that JTablet didn't play too well with it... It could be that your browser is hiccoughing with JTablet for some reason like Opera is for me.


EDIT 2: ArtGrounds is finally back so I tested Sketcher. Like the other two its set to discard all old events. Any lag you're experiencing is more than likely related to my code not keeping up with the event list. This could be caused by the debug messages slowing everything down (as I mentioned above), some slow event code in old versions (which is another reason you want to be sure no old copies of libjtablet.so are hanging around!), or something I haven't thought of.

JigPu
 
Last edited:
Test applet 2's crash:

Code:
cd ../examples && appletviewer JTablet-test2.html
Warning: Can't read AppletViewer properties file: /root/.hotjava/properties Using defaults.
using java 2! (v1.4+!)
INFO : Closing all known tablets.
INFO : Tablet(s) closed.
INFO : Connected to X server.
INFO : Enumerating devices...
INFO : Constructing new XTabletDevice (id = 0, type = 0)
INFO : Constructing new XWacomDevice (id = 0, type = 0)
INFO :          + Device failed test, but allowing anyway...
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 1, type = 0)
INFO : Constructing new XWacomDevice (id = 1, type = 0)
INFO :          + Device failed test, but allowing anyway...
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 2, type = 89)
INFO : Constructing new XWacomDevice (id = 2, type = 89)
INFO :          + Device failed test, but allowing anyway...
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 3, type = 90)
INFO : Constructing new XWacomDevice (id = 3, type = 90)
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 4, type = 216)
INFO : Constructing new XWacomDevice (id = 4, type = 216)
INFO : Tablet(s) initialized.
INFO : Cursors differ! Was cursorPhysicalId = 65535, cursorId = 65535; Now cursorPhysicalId = 4, cursorId = 4
INFO : Initializing Cursor cursorPhysicalId = 4, cursorId = 4.
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
INFO : Getting cursor data
#
# An unexpected error has been detected by Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x7f9f0fad, pid=15263, tid=2142903184
#
# Java VM: Java HotSpot(TM) Server VM (10.0-b22 mixed mode linux-x86)
# Problematic frame:
# C  [libjtablet.so+0x4fad]  _ZN12XWacomDevice11GetAxisInfoEli+0x3d
#
# An error report file with more information is saved as:
# /home/marupa/Desktop/jtablet-sdk-v0.9.5_linux/examples/hs_err_pid15263.log
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
Aborted
make: *** [test_applet2] Error 134


Test applet's output:
Code:
cd ../examples && appletviewer JTablet-test.html
using java 2! (v1.4+!)
INFO : Closing all known tablets.
INFO : Tablet(s) closed.
INFO : Connected to X server.
INFO : Enumerating devices...
INFO : Constructing new XTabletDevice (id = 0, type = 0)
INFO : Constructing new XWacomDevice (id = 0, type = 0)
INFO :          + Device failed test, but allowing anyway...
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 1, type = 0)
INFO : Constructing new XWacomDevice (id = 1, type = 0)
INFO :          + Device failed test, but allowing anyway...
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 2, type = 89)
INFO : Constructing new XWacomDevice (id = 2, type = 89)
INFO :          + Device failed test, but allowing anyway...
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 3, type = 90)
INFO : Constructing new XWacomDevice (id = 3, type = 90)
WARN :       ! This device failed one or more compatibility checks
INFO : Constructing new XTabletDevice (id = 4, type = 216)
INFO : Constructing new XWacomDevice (id = 4, type = 216)
INFO : Tablet(s) initialized.
INFO : Cursors differ! Was cursorPhysicalId = 65535, cursorId = 65535; Now cursorPhysicalId = 4, cursorId = 4
INFO : Initializing Cursor cursorPhysicalId = 4, cursorId = 4.
INFO : Getting cursor data

However, disabling the debug code only seemed to cause lag on the test applet, and it did lessen the lag in sketcher, but it's nowhere near gone. I've tried FF2, FF3. Konqueror wouldn't load sketcher, and Epiphany, although it said it installed, didn't. My machine is a AMD 6400+ (3.2Ghz dualcore) with 4GB of RAM, GeForce 8600 GT. I doubt it's a computer issue.
 
I checked out the code which is mentioned in Java's crash output and came up with a few things which could have caused it. The most likely reason is that the code said an axis was available when it really wasn't. I had hard coded the axes to accept, and if your WizardPen didn't provide data for the more exotic axes then it'd wind up walking off a cliff and crashing.

I've fixed the code to do a check on the number of returned axes, which should allow any driver which uses the same axis numbering as the Wacom drivers (like your WizardPen drivers appear to) to work correctly. When it encounters an exotic axis, it'll see if the axis number is higher than the number of axes supported by the driver, and then fail gracefully like it should.

~~~~~~~~~~~~

As for the lag, the only other thing I've been able to come up with is that there are events on the queue that are not being removed. This would quickly lead to a lag like you're seeing, and as time goes on it should get worse and worse. I've included a debug statement in the code which will alert when an event was skipped.

To be able to see these debug statements though, you'll need to open up Firefox through the commandline. First, close all Firefox windows. Then open up a terminal and type in firefox. This will open Firefox, but will give it some place to put all the output. Open up Sketcher and see what happens when you start using it.

If events are being left on the queue, the terminal should quickly fill with messages saying "Leaving event on queue; no tablet claims to be the initiator". You will need to have DEBUGMODE enabled to see these lines, so do not change the Makefile like I had you do above!

If you don't see anything like that, then there's some other problem going on. I'm quickly running out of ideas, so I really hope this is it...

~~~~~~~~~~~~

You'll need to install the latest version to get the fix & debug messages. Go ahead and get it and let me know how it works :)

JigPu
 
So, grabbed the new source, make clean, make uninstall, make, then make install, ran the test applet (which doesn't crash!) and that looks all fine and dandy. Loaded Firefox, loaded Sketcher, and the lag is a LOOOT less, but still there. Nearly tolerable now. Not seeing any 'leaving event on queue'. I figured, maybe it'd be even better if I got rid of the debugs, so after cleaning, uninstalling, editing the makefile, make, reinstall, the lag's worse, and there's lag in the test applet. If I move my tabletpen too fast, the x/y coordinates have to catch up (about half a second to two seconds). Also, I see that buttons are enabled, but it's set to 0,0 as the range. When I move the pen around in range, is when I get the lag, but the lag increases when I put the pentip down, which gives, in buttons, a value of 256. If I have barrel button 1, the value's either 512 or 768 (pentip up or pentip down, respectively) If I push barrel button 2, it's 1024 no matter if I have pentip up or down. Don't know if this is a bug, a feature, or just some oddity of my tablet. If you need any logs, I can supply you with them, just tell me which ones.
 
Awesome -- I hoped that was the reason for the crash :)

The buttons having a range of [0,0] is normal (not sure why the applet lists a min/max for the buttons, but it does...), and the 256/512/1024 values you get in the button value are a result of the button mask returned by the driver. They should be 1/2/4, but apparently your WizardPen drivers store the button mask 8 bits further into the event data than the Wacom drivers. I'm not sure if there is a good way to have my code work properly with both tablets, but I'll do some thinking. The problem you see with barrel-button 2 is likely a problem with the hardware or driver, since I've had a similar problem with my Wacom in both Linux and Windows.

Still looks like I'm striking out on the lag issue. I'm glad that the lag appears to be lessened, but mystified since I didn't change anything that should have had an impact... It slowing down more with debug messages disabled is even crazier, and throwing me for a serious loop :D If you have some debug-enabled logs, it'd be glad to take a look at them.

JigPu
 
Hey guys, I'm new here and pretty new to Linux. I have not read this entire thread yet. I have a Genius Mousepen 8x6 tablet. It is working with the newest release of the wizard pen driver, currently 0.6.1RC2 and has pressure in The Gimp and Inkscape. I'm using Zenwalk 5.2RC1. I will be trying this thing out tomorrow if I can manage to both find and install
g++
libx11-dev
x11proto-core-dev
x11proto-input-dev
libXi-dev

They are not listed in the package repositories. If anybody can post direct links where to download them from that would be greatly appreciated.

When I do manage to get them installed I will be testing Jtablet linux with my paintchat. I am happy to host one for some artist friends of mine. It works with Jtablet for windows pretty well. Getting pressure to work with Paintchat on linux is actually a requirement of mine for moving from windows to Linux so this project is quite valueble to me. Lets hope it works!
 
No luck when I tried it.

OUTPUT OF MAKE
make -C X11
make[1]: Entering directory `/Downloads/jtablet-sdk-v0.9.5_linux20-1/jtablet-sdk-v0.9.5_linux/c++src/X11'
g++ -g3 -dDEBUG -D PRINT_DEBUG -Wall -D REENTRANT -D GNU_SOURCE -D PRINT_INFO -I/usr/lib/java/include -I/usr/lib/java/include/linux -fPIC -c ../cello_tablet_JTablet.cpp -o ../cello_tablet_JTablet.o
cc1plus: warning: unrecognized gcc debugging option: U
g++ -g3 -dDEBUG -D PRINT_DEBUG -Wall -D REENTRANT -D GNU_SOURCE -D PRINT_INFO -I/usr/lib/java/include -I/usr/lib/java/include/linux -fPIC -c ../JTablet.cpp -o ../JTablet.o
cc1plus: warning: unrecognized gcc debugging option: U
g++ -g3 -dDEBUG -D PRINT_DEBUG -Wall -D REENTRANT -D GNU_SOURCE -D PRINT_INFO -I/usr/lib/java/include -I/usr/lib/java/include/linux -fPIC -c xtabletaccess.cpp -o xtabletaccess.o
cc1plus: warning: unrecognized gcc debugging option: U
xtabletaccess.cpp: In function 'bool InitializeTablet(bool)':
xtabletaccess.cpp:117: warning: format '%d' expects type 'int', but argument 5 has type 'Atom'
xtabletaccess.cpp:117: warning: format '%d' expects type 'int', but argument 6 has type 'XID'
g++ -g3 -dDEBUG -D PRINT_DEBUG -Wall -D REENTRANT -D GNU_SOURCE -D PRINT_INFO -I/usr/lib/java/include -I/usr/lib/java/include/linux -fPIC -c XTabletManager.cpp -o XTabletManager.o
cc1plus: warning: unrecognized gcc debugging option: U
g++ -g3 -dDEBUG -D PRINT_DEBUG -Wall -D REENTRANT -D GNU_SOURCE -D PRINT_INFO -I/usr/lib/java/include -I/usr/lib/java/include/linux -fPIC -c XTabletDevice.cpp -o XTabletDevice.o
cc1plus: warning: unrecognized gcc debugging option: U
XTabletDevice.cpp: In constructor 'XTabletDevice::XTabletDevice(XDeviceInfo*, Display*)':
XTabletDevice.cpp:21: warning: format '%d' expects type 'int', but argument 3 has type 'XID'
XTabletDevice.cpp:21: warning: format '%d' expects type 'int', but argument 4 has type 'Atom'
g++ -g3 -dDEBUG -D PRINT_DEBUG -Wall -D REENTRANT -D GNU_SOURCE -D PRINT_INFO -I/usr/lib/java/include -I/usr/lib/java/include/linux -fPIC -c XWacomDevice.cpp -o XWacomDevice.o
cc1plus: warning: unrecognized gcc debugging option: U
XWacomDevice.cpp: In constructor 'XWacomDevice::XWacomDevice(XDeviceInfo*, Display*)':
XWacomDevice.cpp:20: warning: format '%d' expects type 'int', but argument 3 has type 'XID'
XWacomDevice.cpp:20: warning: format '%d' expects type 'int', but argument 4 has type 'Atom'
XWacomDevice.cpp:79: warning: format '%d' expects type 'int', but argument 4 has type 'XID'
XWacomDevice.cpp:146: warning: comparison between signed and unsigned integer expressions
XWacomDevice.cpp:219: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'
XWacomDevice.cpp:219: warning: format '%d' expects type 'int', but argument 4 has type 'long unsigned int'
XWacomDevice.cpp: In member function 'virtual int XWacomDevice::GetEventType(const XEvent*)':
XWacomDevice.cpp:365: warning: format '%d' expects type 'int', but argument 4 has type 'XID'
XWacomDevice.cpp: In static member function 'static bool XWacomDevice::VerifyCompatible(XDeviceInfo*, Display*)':
XWacomDevice.cpp:475: warning: too many arguments for format
XWacomDevice.cpp:489: warning: format '%d' expects type 'int', but argument 3 has type 'Atom'
gcc ../cello_tablet_JTablet.o ../JTablet.o xtabletaccess.o XTabletManager.o XTabletDevice.o XWacomDevice.o -shared -o libjtablet.so -lX11 -lXi -lstdc++
make[1]: Leaving directory `/Downloads/jtablet-sdk-v0.9.5_linux20-1/jtablet-sdk-v0.9.5_linux/c++src/X11'



OUTPUT OF MAKE INSTALL
make -C X11 install
make[1]: Entering directory `/Downloads/jtablet-sdk-v0.9.5_linux20-1/jtablet-sdk-v0.9.5_linux/c++src/X11'
cp libjtablet.so /usr/lib/java/jre/lib/i386/
cp ../../jtablet.jar /usr/lib/java/jre/lib/ext/
cp libjtablet.so /usr/lib/java/jre/lib/i386/
cp ../../jtablet.jar /usr/lib/java/jre/lib/ext/
make[1]: Leaving directory `/Downloads/jtablet-sdk-v0.9.5_linux20-1/jtablet-sdk-v0.9.5_linux/c++src/X11'



OUTPUT OF MAKE TEST_APPLET2
JTablet could not be loaded (java.security.AccessControlException: access denied (java.lang.RuntimePermission loadLibrary.jtablet)).
cello.tablet.JTabletException: Could not load JTablet native library.
at cello.tablet.JTablet.<init>(JTablet.java:82)
at cello.tablet.JTablet.<init>(JTablet.java:72)
at cello.tablettest.JTablettest2.init(Unknown Source)
at sun.applet.AppletPanel.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
java.lang.NullPointerException
at cello.tablettest.JTablettest2.init(Unknown Source)
at sun.applet.AppletPanel.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
 
Back