EPICS Home

Experimental Physics and Industrial Control System


 
1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  <20152016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  <20152016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: RE: Serial port COM10: not work?
From: Mark Rivers <[email protected]>
To: "Heesterman, Peter J" <[email protected]>, "'Eric Norum'" <[email protected]>
Cc: "EPICS Tech-Talk \([email protected]\)" <[email protected]>
Date: Sun, 4 Oct 2015 17:27:04 +0000
I don't think we should do this.  What is the serial port is on a USB to serial converter?  On Linux this might be /dev/ttyUSB0, so do we also translate that?  I think it's better to use the native OS device names.

Mark

________________________________
From: Heesterman, Peter J [[email protected]]
Sent: Thursday, October 01, 2015 6:15 AM
To: Mark Rivers; 'Eric Norum'
Cc: EPICS Tech-Talk ([email protected])
Subject: RE: Serial port COM10: not work?

Hi Mark,

Just a separate suggestion, while we’re on the subject of Windows serial port naming.

I wondered if it might be appropriate to provide ‘translation’ from /dev/ttyS<n> to \\.\COM<n+1>,  in order to hide the operating system dependency?

Thanks,

Peter.

From: [email protected] [mailto:[email protected]] On Behalf Of Mark Rivers
Sent: 30 September 2015 18:31
To: 'Eric Norum'
Cc: EPICS Tech-Talk ([email protected])
Subject: RE: Serial port COM10: not work?

The code in question is in the Windows-specific driver file (drvAsynSerialPortWin32.c), so it is already Windows-specific.  We are not adding OS-specific code to a generic driver.

I don’t like users having to put 6 backslash characters into the device name, where everywhere else in Windows they just say COM10.

I agree with Peter’s suggestion that we don’t need a special case for COM1-COM9.

I propose the following:


-          If the device name passed to drvAsynSerialPortConfigure starts with  ‘\’  then assume the user has used a device name, and use it directly.

-          If the device name does not begin with ‘\’ then prepend “\\.\<UrlBlockedError.aspx>”.

Mark


From: Eric Norum [mailto:[email protected]]
Sent: Wednesday, September 30, 2015 11:14 AM
To: Mark Rivers
Cc: EPICS Tech-Talk ([email protected]<mailto:[email protected]>)
Subject: Re: Serial port COM10: not work?

I’m not convinced that burying windows-specific code like that into the configure command is a good idea.

What’s so hard about just noting in the documentation that COM ports above 9 require special naming — and since the IOC shell treats backslashes separately:
            drvAsynSerialPortConfigure(“L10”, “\\\\.\\COM10<file:///\\COM10>”, ……..)

On Sep 30, 2015, at 5:24 AM, Mark Rivers <[email protected]<mailto:[email protected]>> wrote:

That may depend on which version of asyn you are using.  The upcoming R4-27 release contains the following in the release notes:

*******************************************
Fix to automatically prefix COM port names larger than COM9 (e.g. COM10, COM11, etc.) with "\.\". This is needed for all ports except COM1-COM9. Thanks to Freddie      Akeroyd for this fix.
*******************************************

If you are running the master branch from github you already have this fix.  If not then I think you can work around the problem by using the full path name to the port when you open it, i.e. \\.\COM10<UrlBlockedError.aspx>.

--
Eric Norum
[email protected]<mailto:[email protected]>






References:
Serial port COM10: not work? Heesterman, Peter J
Re: Serial port COM10: not work? Jack
RE: Serial port COM10: not work? Mark Rivers
Re: Serial port COM10: not work? Eric Norum
RE: Serial port COM10: not work? Mark Rivers
RE: Serial port COM10: not work? Heesterman, Peter J

Navigate by Date:
Prev: RE: Building SEQ 2.2.3, Windows, EPICS Base 3-15-2 freddie.akeroyd
Next: RE: Serial port COM10: not work? Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  <20152016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: RE: Serial port COM10: not work? Heesterman, Peter J
Next: RE: Serial port COM10: not work? Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  <20152016  2017  2018  2019  2020  2021  2022  2023  2024