Re: Record TV over USB
Posted: Thu Jan 21, 2010 12:22 pm
Hi!
I make GDB with "bitbake gdb" command from SamyGO OpenEmbedded SVN (thanks aquadran) and run exeDSP with it.
exeDSP will generate segmentation fault in a minute (is could problem about gdb 7.0.1? needed to try with gdb 6.x.x which I believe more stable than v7), but until then I can debug exeDSP for a while.
Now can debug exeDSP for small time (which is enough for this), and about to start write application.
KeyCommon::RecordKey(int) function is looks good location to handle.
r1 value return 0x49 if I press record button and 0x46 for stop button.
This is enough for primitive recording.
Need to look some ARM Thumb instructions pdf and try to generate program hooks in ASM. mprotects applications are beautiful source also. But here we needed to keep everything in place and inject our code without harming original one. Is it possible to change original function address and use my injection function location? Might be I needed to try this. If it possible I can inject my function between 2 original function.
I think I also needed to handle gtask_manager thing and needed to create a thread for recording. If I try record stream with event thread, than exeDSP will freeze.
I didn't decide where to write file. First version will be primal PVR and require constant file name/patch for recording. Might be file names are Recording001.ts, and if exist Recording002.ts....
I am planning to use /mtd_ram/recording directory, which could be linked to USB flash drive and or NFS/CIFS mount from the Application with symbolic link. Later, some one will code GUIed PVR Application too which you can make select recording directory etc...
I make GDB with "bitbake gdb" command from SamyGO OpenEmbedded SVN (thanks aquadran) and run exeDSP with it.
exeDSP will generate segmentation fault in a minute (is could problem about gdb 7.0.1? needed to try with gdb 6.x.x which I believe more stable than v7), but until then I can debug exeDSP for a while.
Now can debug exeDSP for small time (which is enough for this), and about to start write application.
KeyCommon::RecordKey(int) function is looks good location to handle.
r1 value return 0x49 if I press record button and 0x46 for stop button.
This is enough for primitive recording.
Need to look some ARM Thumb instructions pdf and try to generate program hooks in ASM. mprotects applications are beautiful source also. But here we needed to keep everything in place and inject our code without harming original one. Is it possible to change original function address and use my injection function location? Might be I needed to try this. If it possible I can inject my function between 2 original function.
I think I also needed to handle gtask_manager thing and needed to create a thread for recording. If I try record stream with event thread, than exeDSP will freeze.
I didn't decide where to write file. First version will be primal PVR and require constant file name/patch for recording. Might be file names are Recording001.ts, and if exist Recording002.ts....
I am planning to use /mtd_ram/recording directory, which could be linked to USB flash drive and or NFS/CIFS mount from the Application with symbolic link. Later, some one will code GUIed PVR Application too which you can make select recording directory etc...