Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm building a prototype of a device that will function much alike a digital photoframe. It will display images retrieved from the internet. The device must start up and run the photoframe. It will have no user interface.

The device has a minimal ubuntu installation, but I could install Xorg or whatever needed.

Question: I have trouble figuring out which programming language will be suitable. I've just started using Python to try out several things and I am able to download and display images. I guess that means Python can do what I'd like, but is it suitable as a language that will be run on boot without any user interference?

Related questions: - How do I set up Linux to start that script automatically? - How to setup a second Python script as a server that runs in the background to retrieve images before they are displayed (Because I think I'll need threading of some sort?)

share|improve this question
    
I'd suggest asking just one thing per question, so that you get more focused answers. As such, I'd recommend opening new askubuntu questions for your related questions paragraph –  David Planella Nov 24 '11 at 7:48

2 Answers 2

up vote 2 down vote accepted

Any programming language is suitable to run without user input.

Python for sure is. There are quite a lot of servers running out there writen in python, and I wrote some scripts like this for work in python and they are working quite nice.

In my experience the most important issue is to catch all exceptions, so that the thing keeps running even when something unexpected happens. I even sometime run some code inside a try catching every exception and forwarding the error to a log file, to keep the thing running (this could be sane or crazy, depending on what is the program supposed to do).

share|improve this answer

Python will work for your use case. If the runtime is installed (in the case of Python it is by default, same as in C), you'll be able to run programs for each programming language where you've got a runtime on the system.

In terms of starting the program automatically, you might want to consider running a daemon. In that case, the python-daemon package (install link) is your friend. Here is some more info on the additional scripts you'll need to automatically start and stop it.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.