views:

605

answers:

3

Hi, as it seems there is no scripting language for windows mobile devices that gives access to phone (sms, mms, make a call, take photo) I wonder how complex would it be to make a python library that would enable that (write something in C, compile, and import in pythonce).

Question: where shall start to understand how to compile a pythonce module that will give additional functionality to python on windows mobile. Also, what is the required toolkit. Is it at all possible on mac (Leopard)?

+1  A: 

As the first step, you should try to create executable programs that invoke the functions you want. For example, to send SMS, it appears you need to call MailSwitchToAccount, passing "SMS", and so on - familiarize yourself with the C API on the platform.

To create executables, you need Visual Studio, and the Windows Mobile SDK. Those run on Windows. For cross-compilation, there is CeGCC (http://cegcc.sourceforge.net/docs/using.html), but using it probably makes things more complicated than using the Microsoft tools.

When you have executables that perform the functions you desire, creating Python extension modules out of them should be easy. Just follow the extending-and-embedding tutorials.

Martin v. Löwis
A: 

just tried establishing an environment to get pythonce modules compiled (http://pythonce.sourceforge.net/Wikka/SConsBuild) but seems that I can only use 2003 PPC SDK and it has no recent functions available. Even when I followed all the steps in tutorial, sample spammodule.c does not compile :(

  • Is there any good tutorial I can utilize to startup C (C++) programming for Windows Mobile?
  • Also is it possible using free version of VisualStudio (Express version)?
belunch
+1  A: 

MSDN has plenty of samples for C++ development on Windows Mobile, and the SDK comes with several sample application. Unfortunately VS Express editions (the free ones) do not come with compilers for Smart Devices. The only free option is the older eMbedded Visual C++ (eVC), which is now something like 8 years old and not supported (though it can still create apps for devices at least up through CE 5.0).

ctacke