maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked) (https://talk.maemo.org/showthread.php?t=71326)

nicholes 2011-10-27 13:24

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
@LightRain

WOW that works perfactly Thanks!

ammyt 2011-10-27 13:39

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
What is it with the
File "/usr/bin/pycam", line 2, in <module>
import gst
ImportError: No module named gst
I'm getting? I have gstreamer-tools and python2.5 installed...help?

ammyt 2011-10-27 13:46

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Does this have to be used with CSSU camera-ui? I'm not running CSSU at the moment...

nicolai 2011-10-27 13:49

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Quote:

Originally Posted by ammyt (Post 1114561)
What is it with the
File "/usr/bin/pycam", line 2, in <module>
import gst
ImportError: No module named gst
I'm getting? I have gstreamer-tools and python2.5 installed...help?

Do not run the script as root.

nicholes 2011-10-27 13:51

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Quote:

Originally Posted by ammyt (Post 1114561)
What is it with the
File "/usr/bin/pycam", line 2, in <module>
import gst
ImportError: No module named gst
I'm getting? I have gstreamer-tools and python2.5 installed...help?

did you rename the files you downloaded?? please remove .txt by renaming both files and Put "pycam" in /usr/bin

and Put "pycam.desktop" in usr/share/applications/hildon

and use from menu( a shortcut should be created

LightRain 2011-10-27 14:02

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Quote:

Originally Posted by ammyt (Post 1114561)
What is it with the
File "/usr/bin/pycam", line 2, in <module>
import gst
ImportError: No module named gst
I'm getting? I have gstreamer-tools and python2.5 installed...help?

Make sure you have "python-gst0.10" installed.

ammyt 2011-10-27 15:00

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Thanks @LightRain, works like a charm!
Thanks @nicolai for the script write-up and nicholes for starting the idea!

disappear 2011-10-27 16:28

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Quote:

Originally Posted by ammyt
File "/usr/bin/pycam", line 2, in <module>
import gst
ImportError: No module named gst
Same here.I rename the both files,also i have python-gst0.10,but when i run the app.after few seconds the screen closed.

nicholes 2011-10-27 16:52

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Quote:

Originally Posted by disappear (Post 1114656)
Same here.I rename the both files,also i have python-gst0.10,but when i run the app.after few seconds the screen closed.

try this code in xterminal

type in xterminal "python" and then paste this code by nicolai


import gst
bin = gst.element_factory_make("camerabin")
bin.set_property("videoenc", gst.element_factory_make("dspmp4venc"))
bin.set_property("videomux", gst.element_factory_make("hantromp4mux"))
bin.set_property("audioenc", gst.element_factory_make("nokiaaacenc"))
bin.set_state(gst.STATE_PLAYING)
bin.set_property("filename", "test.mp4")
bin.set_property("mode",1)
#starts recording
bin.emit("user-start")

# wait some time

# stops recording
bin.emit("user-stop")
bin.set_state(gst.STATE_PAUSED)
bin.set_state(gst.STATE_NULL)

LightRain 2011-10-27 16:58

Re: [Solved] Finally shortcut added. Use N900's camera as a spy cam (video recording while screen is locked)
 
Quote:

Originally Posted by disappear (Post 1114656)
Same here.I rename the both files,also i have python-gst0.10,but when i run the app.after few seconds the screen closed.

Maybe you didn't do "chmod +x /usr/bin/pycam"

It have to be done as root

If the above doesn't fix it, in xterm type "/usr/bin/pycam" and paste the ouput here.


All times are GMT. The time now is 16:19.

vBulletin® Version 3.8.8