tsukitsume / android-quill

Automatically exported from code.google.com/p/android-quill
GNU General Public License v3.0
0 stars 0 forks source link

Add pen support for Morgan-Touch digitizer as implemented in iNote-A8 series tablets. #90

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Have an iNote-A8 tablet.
2. Enable Pen-only writing mode.
3. Attempt to write on the screen using your pen.

What is the expected output? What do you see instead?
Expect to be able to write.
Cannot write.

What version of the product are you using? On what operating system?
Quill version 10.6
Android version 4.0.4

Please provide any additional information below.
The iNote-A8 uses a touchscreen driver that handles events for both the 
capacitive touchscreen and the under-screen digitizer layer. It uses a Chinese 
made active digitizer that I have never seen before, the driver source doesn't 
appear to be available, and the driver doesn't conform properly to the ICS pen 
specifications.

The capacitive screen is located at "/dev/input/event2", while the digitizer is 
at "/dev/input/event3".

The "getevent" command shows that the capacitive screen provides "ABS_MT_*" 
style, multitouch responses, while the digitizer reports only the following 
single-touch events:
BTN_TOUCH (Pen up / down)
ABS_PRESSURE (pressure value)
ABS_X (x coordinate)
ABS_Y (y coordinate)
KEY_MENU (pen button 1 up/down)
KEY_BACK (pen button 2 up/down)

I have attached a log of getevent and "cat 
/sys/class/input/input3/device/uevent" to give you an idea.

I think that it could be implemented relatively easily if it is possible to 
determine through the Android API if the input device is single or multi-touch 
capable.

Original issue reported on code.google.com by peter.r....@gmail.com on 13 Apr 2013 at 10:47

Attachments:

GoogleCodeExporter commented 9 years ago
Ok..

Scratch that. It appears to work correctly if I force it as a ThinkPad Tablet.

Original comment by peter.r....@gmail.com on 14 Apr 2013 at 10:17

GoogleCodeExporter commented 9 years ago
I see, they must be using an N-trig digitizer. Interesting!

Do you happen to know the android.os.Build.MODEL string? Then I'll make it 
default to the ThinkPad Tablet pen method.

Original comment by vbraun.n...@gmail.com on 15 Apr 2013 at 4:25

GoogleCodeExporter commented 9 years ago
Hi vBraun,

It's not an N-trig. The pen requires a AAAA battery, but it is Chinese made 
hardware, ostensibly from a company called Morgan Touch Technologies:
http://www.morgan-touch.com/

The tablet manufacturer's page is here:
http://www.ibnote.com/

I've attached the entire build.prop file. I believe the MODEL is 
"crane-iNote_v4".
I've also attached a picture of the pen/touchscreen controller board.

I have root on the device and a rudimentary knowledge of java, so if you need 
me to run or do anything on the device, just let me know.

Thanks,
pb

Original comment by peter.r....@gmail.com on 16 Apr 2013 at 2:47

Attachments:

GoogleCodeExporter commented 9 years ago
The N-trig pen on the thinkpad tablet also needs a battery (AAA I think). 
Though I agree that there is no sign that the manufacturer is affiliated with 
N-trig. 

Original comment by vbraun.n...@gmail.com on 16 Apr 2013 at 3:54

GoogleCodeExporter commented 9 years ago
Ah.. I think I get it now.

In [PenEventThinkPadTablet], my pen driver must be returning "0" for 
getTouchMajor(), so isPenEvent() is returning true.

isPenButtonPressed() then calls on ViewHackThinkpad.onTouchEvent(), where my 
pen driver is responding with "MotionEvent.ACTION_DOWN" (ie. linux "BTN_TOUCH") 
to the getActionMasked() function.

So it's not an N-trig specific thing at all. It's:
1] Does the pen driver return a single coordinate, or a touch area.
2] Does the pen driver provide a "BTN_TOUCH" event in linux.
3] Optionally, does the pen provide a "ABS_PRESSURE" report in linux.

It appears that if those conditions are met, then the [ThinkPadTablet] 
methodology will work correctly.

Original comment by peter.r....@gmail.com on 16 Apr 2013 at 11:04