On 10月11日, 下午11时00分, Grant Edwards <[EMAIL PROTECTED]> wrote: > On2008-10-11,zxo102<[EMAIL PROTECTED]> wrote: > > > I have a system. An instrument attched to 'com1' is wireless connected > > to many sensors at different locations. The instrument can forward > > the "commands" (from pyserial's write()) to those sensors. Based on > > the "commands", the sensors keep sending corresponding data back to > > the instrument which wraps up those data and put into "com1" . The > > readlines() of pyserial pick up those data for processing. > > The data ?string' does not have "\n". > > If the data you're reading doesn't contain "\n", then you can't > use readline() or readlines(). > > -- > Grant Edwards grante Yow! I smell a RANCID > at CORN DOG! > visi.com
But readlines() can read data out of 'com1' for many hours. Maybe I should try read(). Ouyang -- http://mail.python.org/mailman/listinfo/python-list