I am not using -rt at the moment (may later depending on how the patch eats up CPU)
And yes the problem is the freeze, not attaching to the driver, I never do see a frame of video though, from black to frozen. The specific cause of the freeze is sending the "mode ntsc 1" message. the pix_video in a patch does NOT freeze pd when loading the patch, but it does not show any video either. Once I try and change the video port that is when the freeze happens. I can change the video mode before creating the gemwin, no freeze, but then when I try and change it while rendering, it freezes. Freezes on "mode ntsc $1" where $1 is 0-2. Seems I never see any video get textured. Console seems to be happy printing stuff like:
pix_videoNEW: starting transfer GEM: pix_video: Opened video connection 12
When pix_video loads and there is both v4l and ieee1394 on the machine, which is "driver 0"? v4l is reported in the console first.
Here is the bt after killing pd
Program received signal SIGTERM, Terminated. [Switching to Thread 1076267520 (LWP 21548)] 0xffffe410 in __kernel_vsyscall () (gdb) bt #0 0xffffe410 in __kernel_vsyscall () #1 0x40128e48 in pthread_join () from /lib/tls/i686/cmov/libpthread.so.0 #2 0x44bec81d in videoV4L::stopTransfer () from /usr/lib/pd/extra/Gem.pd_linux #3 0x44bec9d6 in videoV4L::setNorm () from /usr/lib/pd/extra/Gem.pd_linux #4 0x44be81c5 in pix_videoNEW::normMess () from /usr/lib/pd/extra/Gem.pd_linux #5 0x44be898a in pix_videoNEW::modeMessCallback () from /usr/lib/pd/extra/Gem.pd_linux #6 0x0809ba47 in pd_typedmess () #7 0x00000000 in ?? () #8 0x080ecce6 in _IO_stdin_used () #9 0x00000022 in ?? () #10 0xffffffff in ?? () #11 0x00000000 in ?? () #12 0x00000000 in ?? () #13 0x00000000 in ?? () #14 0x00000000 in ?? () #15 0x080eccff in _IO_stdin_used () #16 0x08383bf0 in ?? () #17 0x40193251 in funlockfile () from /lib/tls/i686/cmov/libc.so.6 Previous frame inner to this frame (corrupt stack?)
Any tests/suggestions would be amazing.
I played around with it more and got a similar trace but w/ an actual crash caused by sending "0, destroy" to gemwin while I'm seeing just the black texture (and I tried it again and this time it did not segfault, but gave the same trace as above):
Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 1076267520 (LWP 22042)] ---Type <return> to continue, or q <return> to quit--- 0x40127af8 in __free_tcb () from /lib/tls/i686/cmov/libpthread.so.0 (gdb) bt #0 0x40127af8 in __free_tcb () from /lib/tls/i686/cmov/libpthread.so.0 #1 0x40128e8d in pthread_join () from /lib/tls/i686/cmov/libpthread.so.0 #2 0x44bec81d in videoV4L::stopTransfer () from /usr/lib/pd/extra/Gem.pd_linux #3 0x44be80ac in pix_videoNEW::stopRendering () from /usr/lib/pd/extra/Gem.pd_linux #4 0x44b1417e in GemBase::gem_startstopMess () from /usr/lib/pd/extra/Gem.pd_linux #5 0x44b143e2 in GemBase::gem_MessCallback () from /usr/lib/pd/extra/Gem.pd_linux #6 0x0809ba47 in pd_typedmess ()
Oh! I got a single frame of what looks like 96x96 pixel cable noise, but only one frame. First time I saw anything at all getting textured. Doing the same thing a second time I'm not getting anywhere.
Thats enough for now, back to serial programming the camera.
I'll do any tests needed to get this working, just tell me what to do.
Let me know if it would help to meet on IRC.
Thanks Johannes.
b.
IOhannes m zmoelnig wrote:
Oh and Johannes, I do have the v4l_compat module loaded, so I don't know why xawtv reads my v4l2 video stream but Gem does not. Any ideas?
so the current problem is freezing (not just being unable to connect to the driver) ? are you using pd's realtime flag ?
you could try running everything in gdb and then kill the process when it freezes and then get a backtrace to see where it was when it froze.
mfg.juz.ssd IOhannes