You Are Here:

Community: Developer Discussion Boards

Reply « Previous Thread | Next Thread »

#1 Old Question using accelrometer in 5800 - 2009-05-04, 05:33

Join Date: Nov 2008
Posts: 74
apacheking
Offline
Regular Contributor
i have a python program which uses sensor module but its not present in python 1.9.4 so how to access accelerometer in python for 5800
Reply With Quote

#2 Old Re: using accelrometer in 5800 - 2009-05-04, 05:59

Join Date: Oct 2007
Posts: 2,845
Location: Deva, Romania
bogdan.galiceanu's Avatar
bogdan.galiceanu
Offline
Forum Nokia Champion
It is present in PyS60 1.9.4. import sensor works just fine. The documentation has a table of devices and available sensors and the 5800 is there. There's also an example. Check section 3.9 of the documentation.
Reply With Quote

#3 Old Re: using accelrometer in 5800 - 2009-05-04, 07:09

Join Date: Dec 2008
Posts: 21
maymaria
Offline
Registered User
Hi,do anyone have a clear idea in handling shake in 5800 with the help of accelerometer sensor?i am developing the application on Symbian.i went through some discussion threads.but what i got is not working properly.if anyone can help me,please do respond.

thanks in advance.
Reply With Quote

#4 Old Re: using accelrometer in 5800 - 2009-05-04, 10:32

Join Date: Oct 2006
Posts: 2,541
Location: Helsinki, Finland
Symbian_Neil's Avatar
Symbian_Neil
Offline
Forum Nokia Champion
Quote:
Originally Posted by maymaria View Post
Hi,do anyone have a clear idea in handling shake in 5800 with the help of accelerometer sensor?i am developing the application on Symbian.i went through some discussion threads.but what i got is not working properly.if anyone can help me,please do respond.

thanks in advance.
You are developing in Symbian and trying to search for answers in Python

Maybe you should narrow your search for Symbian Forums or wait for somebody to answer your queries that you already posted in the Symbian section.

Good Luck!


- Neil R.Bhasme -
Reply With Quote

#5 Old Re: using accelrometer in 5800 - 2009-05-04, 11:01

Join Date: Nov 2008
Posts: 74
apacheking
Offline
Regular Contributor
bogdan bro i donno what u mean as documentation can u link me bro
Reply With Quote

#6 Old Re: using accelrometer in 5800 - 2009-05-04, 11:07

Join Date: Nov 2008
Posts: 74
apacheking
Offline
Regular Contributor
sensors = sensor.sensors()


this dont works
Reply With Quote

#7 Old Smile Re: using accelrometer in 5800 - 2009-05-04, 11:58

Join Date: May 2007
Posts: 2,739
Location: 21.46 N 72.11 E
croozeus's Avatar
croozeus
Offline
Forum Nokia Champion
Quote:
Originally Posted by apacheking View Post
sensors = sensor.sensors()


this dont works
Quote:
Originally Posted by apacheking View Post
bogdan bro i donno what u mean as documentation can u link me bro
Download and install this file, https://garage.maemo.org/frs/downloa....9.4_Setup.exe

Go to Start->Program files->Python for S60->PyS60 Documentation.
Reply With Quote

#8 Old Re: using accelrometer in 5800 - 2009-05-04, 12:00

Join Date: May 2007
Posts: 2,739
Location: 21.46 N 72.11 E
croozeus's Avatar
croozeus
Offline
Forum Nokia Champion
Also I had recommend this literature as reference for using the sensor module.

http://croozeus.googlepages.com/Sensor_Sample_20.pdf
Reply With Quote

#9 Old Re: using accelrometer in 5800 - 2009-05-04, 16:15

Join Date: Nov 2008
Posts: 74
apacheking
Offline
Regular Contributor
pankaj bro still sensors = sensor.sensors()is giving error
Reply With Quote

#10 Old Re: using accelrometer in 5800 - 2009-05-04, 16:30

Join Date: Oct 2007
Posts: 2,845
Location: Deva, Romania
bogdan.galiceanu's Avatar
bogdan.galiceanu
Offline
Forum Nokia Champion
Quote:
Originally Posted by apacheking View Post
pankaj bro still sensors = sensor.sensors()is giving error
What does the error say?
Reply With Quote

#11 Old Re: using accelrometer in 5800 - 2009-05-04, 16:32

Join Date: Nov 2008
Posts: 74
apacheking
Offline
Regular Contributor
there is no module object called sensor
Reply With Quote

#12 Old Re: using accelrometer in 5800 - 2009-05-04, 16:37

Join Date: Oct 2007
Posts: 2,845
Location: Deva, Romania
bogdan.galiceanu's Avatar
bogdan.galiceanu
Offline
Forum Nokia Champion
Quote:
Originally Posted by apacheking View Post
there is no module object called sensor
I tried to import sensor on a 5800 and it worked. So you're saying that
Code:
import sensor
sensors = sensor.sensors()
gives a "No module named sensor" error?
Reply With Quote

#13 Old Re: using accelrometer in 5800 - 2009-05-04, 16:42

Join Date: Nov 2008
Posts: 74
apacheking
Offline
Regular Contributor
bro the error i got after ur example was attribute error:"module object has no attribute sensors
Reply With Quote

#14 Old Re: using accelrometer in 5800 - 2009-05-04, 17:54

Join Date: May 2007
Posts: 2,739
Location: 21.46 N 72.11 E
croozeus's Avatar
croozeus
Offline
Forum Nokia Champion
Quote:
Originally Posted by apacheking View Post
bro the error i got after ur example was attribute error:"module object has no attribute sensors
PyS60 1.9.x sensor module is new and does have the function sensors.

Use the dir(sensor) command to get a list of all available functions/attributes.

FYI, the sensor module compatibility in the 1.9.x releases and 2.0 release is not guaranteed.
Reply With Quote

#15 Old Re: using accelrometer in 5800 - 2009-05-04, 18:17

Join Date: Feb 2008
Posts: 743
Location: Belo Horizonte, Brazil
Send a message via Skype™ to Rafael T.
Rafael T.'s Avatar
Rafael T.
Offline
Forum Nokia Champion
You can download the Sensor Module Specifications documentation provided by the PyS60 team. It explains how to use each sensor available in the 5800 XM.



Hope it helps,

Rafael.
Last edited by Rafael T. : 2009-05-04 at 18:24. Reason: corrected link
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules

You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump
Similar Threads
Thread Thread Starter Forum Replies Last Post
Control Nokia 5800 image display using voice activation jtullis Python 0 2009-03-03 23:51
Capturing and Streaming Video / Audio on 5800 in S60 Application MBFonz Symbian Media (Graphics & Sounds) 6 2009-02-24 17:11
Capturing and Streaming Video / Audio on 5800 for S60 MBFonz Streaming and Video 1 2009-02-13 01:10
Capturing Video / Audio on 5800 in S60 Application MBFonz General Discussion 1 2009-02-13 01:08

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia