Re: [PD] xinput external
Le 19/12/2013 07:53, pured...@11h11.com a écrit : hi, i am using a modified version of xinput (adding ;, leading 0 and unbuffered) with pdsend (udp). i can now get my tablet x,y,pressure,tilt in pd. a demo patch is included (showing a way to parse xinput test data). https://github.com/patricksebastien/xinputpdsend the only problem is that i am using [shell] to execute the xinput | pdsend and when quitting pd it hangs until killall xinput. not very elegant, but working for me. ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list Hello, It should be possible to make a bash script where you would start xinput and pd in background and get their PID. Then use a loop to check if pd is still alive (with its PID), if not, you kill xinput. ++ Jack ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] xinput external
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 2013-12-19 07:53, pured...@11h11.com wrote: hi, i am using a modified version of xinput (adding ;, leading 0 and unbuffered) with pdsend (udp). i can now get my tablet x,y,pressure,tilt in pd. a demo patch is included (showing a way to parse xinput test data). https://github.com/patricksebastien/xinputpdsend the only problem is that i am using [shell] to execute the xinput | pdsend and when quitting pd it hangs until killall xinput. you might consider using UDP instead of TCP for sending data back to Pd. UDP seems to be much more stable (esp. when it comes to broken connections), and if you are only using localhost, the network reliability should be a non-issue. as for adding ; and leading 0; you might want to use `sed`. fgamsdr IOhannes -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.15 (GNU/Linux) Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iQIcBAEBCAAGBQJSsstDAAoJELZQGcR/ejb4zSUP/3T/56q+twjnGzXzjn3gaza4 D5uVmZ70iGEgG9JyFXx3vplTun7cE/MbEl1NUcU8Ig96s/aEEtVxLcHUmg4QI/S9 TZvsx2YMv7ElvQpz0yHAree2lv50rr0B/rst8EAzBvJ4NZWdCP48b85Y7YPmEaAF Drs/DLeqF/O0cI5kJWPK1YG46HvdjAmygxxIpPFbpSmE9BPaxF23BCnCCu1CLaIo wSAyrLyCgaMv8IJkKgkbZuaZ9PTLTQVzs33qkfgcw250FpZgfn5QcI5yL+7Z20Sf Uh7H91/zFVO2dkFHqSvXuN6x5Q21sFQjChsFh8vzB/JRHNRNFC4Sz35aFBT3H+7P 9X9osJqKhHudQf5BOpOXMHJONhFagnPnU3CUtvWCoAhqGTxPm0772LhSm/OAsyRn N9AzQW2Zb7ip8bbJs0MhZoe6GnBKwkYbMuM3ssH529CDnPhFZpJNVgjI43ldlknu ast8sHSbKFIT8Bc5DJ2CyuhYDijanbHCJ8lTC54Il69t3hHeu0UYbeeSiXaFgQdW uCGeSb+OvYbkq6zSiESM5Ri/7/HZacCdzQTM2c/VrzOjU5h+l3/7/P1M/dd/7SC1 S4FancfTm7/QpiKuaIS2r9GuNDjrU1im6NHTaClNrZrVwK7XGAuCL6qRrfRdwr8Z o+O2CaRUE0uw+dRLwgMP =ILUI -END PGP SIGNATURE- ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] xinput external
On 2013-12-19 11:32, IOhannes m zmoelnig wrote: as for adding ; and leading 0; you might want to use `sed`. or use a script like the attached one (on Debian, 'unbuffer' can be found in the 'expect-dev' package) usage: ./xinput.sh id udp-port as for the problem of terminating a process in [shell], i usually start external senders outside of Pd: script #!/bin/sh ./xinput.sh 12 9998 XINPUT_PID=$1 pd -open mypatch.pd kill -QUIT ${XINPUT_PID} script gfmadsr IOhannes xinput.sh Description: application/shellscript signature.asc Description: OpenPGP digital signature ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] xinput external
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Le 19/12/2013 12:04, IOhannes m zmölnig a écrit : On 2013-12-19 11:32, IOhannes m zmoelnig wrote: as for adding ; and leading 0; you might want to use `sed`. or use a script like the attached one (on Debian, 'unbuffer' can be found in the 'expect-dev' package) usage: ./xinput.sh id udp-port as for the problem of terminating a process in [shell], i usually start external senders outside of Pd: script #!/bin/sh ./xinput.sh 12 9998 XINPUT_PID=$1 pd -open mypatch.pd kill -QUIT ${XINPUT_PID} script gfmadsr IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list Ya, better and simpler than to check if pd is still alive : keep pd in foregroud ;) ++ Jack -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.14 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBAgAGBQJSstR+AAoJEOuluecjw8GU2nwH/0DX6wmQXYVbU+OCERFJAclQ wJ3Dv8/OaR5PRcLaklhS7gdZ7K7t+QXM8ddmHkPbFCtp1TFnxqrHPkcsEq9usN8y SxpDW61l0UyVZrWLvlB2lk1Xdrb35BgL8BaHfeOq7UO1zOR1JllShThaGyCa2Hd2 Mwr8OmoxxMwHhn/ZmLfAUa735X596Z7AMLrTGX5J58TUBA2lD9hbuqykhudKxYXH CP1+BOTP8dB30uriTdLfUXO7h5LW+Z+xxtvgDe0BeOE0Ad98qwxgZ7QLU4/JEW+V 9mcfUASfZC1CNhS1a+zQ0y6Vg3f4ajcIsAL9ofza2NPifGlLI8bZq5Xnql+K8tE= =FVhO -END PGP SIGNATURE- ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] xinput external
le savoir faire at his best, i removed my repo, thanks IOhannes! ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] xinput external
hi, i am using a modified version of xinput (adding ;, leading 0 and unbuffered) with pdsend (udp). i can now get my tablet x,y,pressure,tilt in pd. a demo patch is included (showing a way to parse xinput test data). https://github.com/patricksebastien/xinputpdsend the only problem is that i am using [shell] to execute the xinput | pdsend and when quitting pd it hangs until killall xinput. not very elegant, but working for me. ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] xinput external
hi all, anyone coded an external for fetching xinput device? xinput --list xinput test 12 (tablet) motion a[0]=12619 a[1]=12856 a[2]=0 a[3]=-4 a[4]=-7 a[5]=-900 motion a[0]=12568 a[1]=12756 a[2]=0 a[3]=-4 a[4]=-7 a[5]=-900 motion a[0]=12531 a[1]=12618 a[2]=0 a[3]=-4 a[4]=-7 a[5]=-900 button release 2 http://cgit.freedesktop.org/xorg/app/xinput/tree/src ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list