Active Topics

 


Reply
Thread Tools
Posts: 279 | Thanked: 34 times | Joined on Jan 2010 @ Belgrade, Serbia
#1
I just wrote my first Python program. How do i make it run on N900?
 
Posts: 3,617 | Thanked: 2,412 times | Joined on Nov 2009 @ Cambridge, UK
#2
Copy it over & run it - either using "python script.py" or by making it executable ("chmod a+x script.py") and then running it directly ("./script.py"). You can't make it executable on a FAT32 filesystem though, so the script would have to be copied somewhere outside of MyDocs (and the SD card).
 

The Following 3 Users Say Thank You to Rob1n For This Useful Post:
Posts: 279 | Thanked: 34 times | Joined on Jan 2010 @ Belgrade, Serbia
#3
I'm sorry, but a total noob when it comes to this. i just started to learn to program. Actually, the program i wrote is that number guessing game . So i just wanted to know how can i make it run on n900. I appreciate your help, but i don't understand any of that.
 
Posts: 3,617 | Thanked: 2,412 times | Joined on Nov 2009 @ Cambridge, UK
#4
Originally Posted by white_ranger View Post
I'm sorry, but a total noob when it comes to this. i just started to learn to program. Actually, the program i wrote is that number guessing game . So i just wanted to know how can i make it run on n900. I appreciate your help, but i don't understand any of that.
That's no problem. I'll do step-by-step instructions:
  1. Copy the application over to the N900. If you're using PC Suite mode, copy it to the Data directory, and if you're using Mass Storage mode, copy it to the root of the drive.
  2. On the N900, launch X Terminal
  3. Type in "cd MyDocs" and press return. This changes directory to the MyDocs directory, which is where you've copied the file.
  4. Type in "python scriptname.py" and press return. This tells python to run the program script.
 

The Following User Says Thank You to Rob1n For This Useful Post:
Posts: 279 | Thanked: 34 times | Joined on Jan 2010 @ Belgrade, Serbia
#5
WOW I did it. Thank you so much!!!!
 
Reply


 
Forum Jump


All times are GMT. The time now is 17:36.