473,769 Members | 2,085 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

pyserial win32 port numbering

http://pyserial.sourceforge.net/

"port numbering starts at zero, no need to
know the port name in the user program"
But the implementation in SerialWin32 is
just
(Portnum +1)
So there is no 'start' to the port numbering at all:
there is no assurance that you will have a pySerial
serial port Zero, even if you have 57 Windows Serial
ports.
Renumbering the serial ports to start at zero would sort of make sense
if it was done in a semi-portable way - so you could move from one
machine with two serial ports to another machine with two serial ports.

In Windows, that requires enumerating the serial ports, and assigning a
logical pySerial port number to each.

This is going to become more of a problem, because Windows logo
compliant PC's by definition do not have a serial port 1 or 2 so the
pySerial logical port numbers are likely to start at 2 or 4.

It's already a problem on PC's that have PCI serial port cards (not ISA
serial port cards). The pySerial logical port numbering typically goes
something like 0, 4,5, mapping the Windows serial ports 1,5,6

(david)
Aug 14 '07 #1
0 2078

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

13
11038
by: Bob Greschke | last post by:
We have some equipment that communicates at 57600 baud RS232. The path from the PC is USB to a Phillips USB hub, then off of that a TUSB3410 USB/Serial converter. The driver for the 3410 chip creates a "normal" comm port (like COM3). There is a C++ program that has no problem talking to the equipment, but two Python programs have trouble. One is a big, scary, controller program, and the other, since that is the one I'm having trouble...
17
7936
by: luca72 | last post by:
Hello at all sorry for my english but i'm Italian. I use pyserial to communicate via rs232 with an extarnal device called smartmouse. I write the exact line that i want , but when i read i read only the echo ond not the other bytes. When i meke the same project with delphi i solve this problem with the call of the sleep. But in python it don't work. Have you got some ideas for solve my problem?
2
3741
by: Jon | last post by:
Hi, I wrote some code to read in info from a port using pyserial. the code reads info sent by a box that is connected to my computer by an rs232-to usb adapter. When I was writing the code and testing it on my computer it worked fine. I ran py2exe on the program (which uses wxpython for its gui) and sent the output from the py2exe to another computer. now when I try to run it on this other computer it fails to open the port. it gives...
3
8159
by: Ron Jackson | last post by:
I am using Python 2.5 on Windows XP. I have installed Pyserial and win32all extensions. When I try to run the example program scan.py (included below), or any other program using pyserial, as soon as it hits the statement: s = serial.Serial(i) I get the error:
12
6801
by: TonyAm | last post by:
Hi, I am new to Python. Very interested in controlling things (microcontrollers) via the serial port (or usb, parallel). I thought I would start by learning about pyserial. I have seen some examples here and there on the web and the sourceforge examples. I'm using windows xp. Wondering if anyone has any very simple examples of using pyserial. And if anyone can help explain each line of code in a very simple way? Would pyserial be...
0
596
by: pauland80 | last post by:
<snip> <snip> Late thanks for your both answers! (Please excuse me for that) The problem was a bug in the device firmware. But before finding this, I dugg lightly in the pyserial source and found (to take with care!) :
3
11632
by: naveen.sabapathy | last post by:
Hi, I am trying to use virtual serial ports to develop/test my serial communication program. Running in to trouble... I am using com0com to create the virtual ports. The virtual ports seem to be working fine when I test it with Hyperterminal . I am using the example program that comes with pyserial, as below. --------------- import serial
1
1711
by: JAMoore84 | last post by:
Hi Guys, I have a project where I'd like to save GPS data that is streamed to a Sony Vaio over bluetooth. I can monitor the data stream over Hyper Terminal, but I'd like to use python to capture it as well. I've installed Python 2.5, pyserial 2.2 and the appropriate pywin program (pywin32-210.win32-py2.5.exe). My problem comes when I try to open a serial port. After importing "serial", I issue the following statement:
6
10649
by: Joe G \(Home\) | last post by:
Hi All, Background =================== I have installed Python for windows today from the python web site .I also installed pySerial using the Windows installer from the sourceforge web site..... Both installs use the default directories. Phyton version : Python 2.5.2 (r252:60911, Feb 21 2008, 13:11:45) on win32
0
9423
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
9997
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9865
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7413
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6675
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5448
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3965
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3565
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2815
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.