[PythonCE] Accessing serial port with PythonCE 2.5
adam.walley at gmail.com
Tue Dec 15 08:04:07 EST 2015
I thought I would send a short comment, as I have used the ceserial module
(a long time ago) for my HP iPaq running PythonCE 2.5. I recall that the
ceserial module tries to implement what the standard serial module does for
Python, but depending on the actual version of ceserial used there may be
some small differences in the naming of the of the properties and
variables. It is worth verifying in the ceserial module that it is actually
settings the parameters as expected for the serial port object.
That aside, I would also say that a PARITY_EVEN setting would be unusual
these days and that PARITY_NONE is more common. I think I also found that
the stopbits setting did not set the port as expected. Sorry to not have a
definite answer, but an oscilloscope will show you what the device is
trying to do. Finally, perhaps the device you are connecting to is
expecting the DTR line to change?
On 15 December 2015 at 05:30, Rushali Watane <rushaliwatane at gmail.com>
> Stefan Johansson <sjn37 <at> yahoo.com> writes:
> > You can find a link to ceserial in the archives:
> > http://mail.python.org/pipermail/pythonce/2006-September/001589.html
> > I have used it successfully on my Dell Axim.
> > Stefan
> > ----- Original Message ----
> > From: David Goncalves <pythonce-ml <at> lestat.st>
> > To: Luke Dunstan <coder_infidel <at> hotmail.com>
> > Cc: pythonce <at> python.org
> > Sent: Monday, January 8, 2007 4:08:58 PM
> > Subject: Re: [PythonCE] Accessing serial port with PythonCE 2.5
> > Hi,
> > > Well there is no "serial" module included with PythonCE, but Python
> > > my PC doesn't have such a module either. I haven't done it myself on
> > > PythonCE but I think the best way would be to use ctypes to access
> > > Win32 serial communications APIs. I have written some code to do
> this on
> > > the PC, so I have attached it.
> > Thanks for your code ;) I'll try it and give feedback.
> > I've seen about people usin "ceserial" that seems to be a port of
> > PySerial on WinCE. But no way to find it somewhere on the net :(
> > _______________________________________________
> > PythonCE mailing list
> > PythonCE <at> python.org
> > http://mail.python.org/mailman/listinfo/pythonce
> I am trying to read the data from serial port using python 2.5 with
> ceserial module on windows CE 5.0. When i am trying to run, it is get
> connected to port, but it is not reading the data from the port.Below is
> my code -
> from time import sleep
> import ceserial
> ser =
> print("connected to: " + ser.portstr)
> #data = ''
> while True:
> data = ser.read(9999)
> if len(data) > 0:
> print 'Got:', data
> #print 'not blocked'
> PythonCE mailing list
> PythonCE at python.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the PythonCE