[PD] howto convert touchscreen input data

noskule noskule at gmx.net
Thu Feb 5 18:01:57 CET 2004


Hi list . . .
i did connect a elotouch to pd via comport. So far it works . .and i get
data . .. . they looks like this:
print: 85
print: 84
print: 96
print: 54
print: 244
print: 83
print: 122
print: 1
print: 57
print: 85
print: 84
. . .. ..

i did pack them to a list . .looks like:

***************************: bang
print: 194 206 67 70 33 32 144 250
print: 96 102 40 72 132 4 42 255
print: 193 102 67 33 33 208 255
print: 193 102 67 72 200 2 122
print: 193 102 67 72 136 5 100
print: 193 102 67 72 72 5 228
print: 193 102 67 34 33 10 232 255
print: 193 102 67 34 33 2 154
***************************: bang

first number (194 193 96) tells the mode (stream untouch . .. .). The other
6 params are cordinates i guess . . .dos anyone now how to glue them together
. .. ? below the description of the ascii mode . . ..
 . ..seams that 2 following numbers stay for one cordinate . . ..
dos anyone have a idea . .. ?
thanx
nos


----------------------------------------------------------------------------------------------
SmartSet ASCII Mode
In this mode, coordinate data is formatted as three ASCII decimal numbers
for X,
Y, and Z. The range of the coordinates is determined by the calibration and
scaling
options of the controller. Coordinate values of less than 1000 are padded
with
leading zeroes so each number will have at least four digits. Scaling may
require
the addition of an additional digit for values greater than 9999. Scaling
may also
add a leading minus sign ("-"). Plus signs are suppressed.
The Z coordinate is followed by an optional status indicator. A "T"
indicates initial
or stream touch, a "U" indicates untouch. In the example below, optional
characters are underlined.

<->XXXXX<space><->YYYYY<space><->ZZZZZ<space><T|U><CR><LF>
J2-Y, J10-N, J11-N; 0/1,5

84 T (initial or stream touch)
85 U (indicates untouch)
45 -

193  stream
194 
end
96
----------------------------------------------------------------------------------------------


-- 
GMX ProMail (250 MB Mailbox, 50 FreeSMS, Virenschutz, 2,99 EUR/Monat...)
jetzt 3 Monate GRATIS + 3x DER SPIEGEL +++ http://www.gmx.net/derspiegel +++





More information about the Pd-list mailing list