1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 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 2015 2016 2017 2018 2019 2020 2021 2022 <2023> 2024 |
<== Date ==> | <== Thread ==> |
---|
Subject: | 回覆: A Modbus problem relating to byte order and endian |
From: | Chiang, Liang-Chih [江良志] via Tech-talk <tech-talk at aps.anl.gov> |
To: | Maren Purves <m.purves at eaobservatory.org> |
Cc: | "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov> |
Date: | Tue, 7 Nov 2023 08:20:43 +0000 |
Thanks for replying.
According to your experience, I think I have two options:
1.modify the controller parameters to change the byte orders of Modbus registers
2.read each Modbus register separately, then combine them
Some information are provided as follows, though maybe not helpful.
My computer:
OS: CentOS 6.9
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPUModel: Intel Core i7-6700
EPICS/IOC server:
OS: CentOS Stream release 8
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPUModel: Intel Xeon Silver 4210R
Best regards.
LiangChih Chiang NSRRC beamline group email: chiang.lc at nsrrc.org.tw 寄件者: Maren Purves <m.purves at eaobservatory.org>
寄件日期: 2023年11月7日 下午 04:10 收件者: Chiang, Liang-Chih [江良志] <chiang.lc at nsrrc.org.tw> 副本: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov> 主旨: Re: A Modbus problem relating to byte order and endian Aloha,
this may not so much have to do with the version of asyn and modbus but with the architectures and/or operating systems of the computers involved. I remember running into problems like
this when we switched from Solaris (on Sun machines) to Linux (on x86 machines) (about 20 years ago, with the IOCs staying the same) - when for array readouts displayed as images we got 'striped data'.
In your case recompiling on the system you're running it on may help, I think at the time I may have implemented byte-switching in transfer, but this being 20 years ago I don't remember
the details.
Maren Purves
Head of Instrument and Telescope Software East Asian Observatory / JCMT On Mon, Nov 6, 2023 at 9:09 PM Chiang, Liang-Chih [江良志] via Tech-talk <tech-talk at aps.anl.gov> wrote:
|