EPICS Controls Argonne National Laboratory

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  <20132014  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  <20132014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: decimal value convert to hex problem
From: 张德敏 <[email protected]>
To: tech-talk <[email protected]>
Date: Fri, 29 Mar 2013 00:37:42 +0800 (CST)
Dear all,
  I am trying to communicate a serial device using StreamDevice-2-3 on 32-bit Linux OS.  writting values using the following protocol:
      !Innn<cr>   (program mA demand. FFF=10mA, nnn must be 3 hexadecimal digits)
      Reading values using the following protocol:
     ?I<cr>  , and the response is ?Innn.  nnn represents the hexadecimal.
How can I convert decimal to hex when sending value ,and how can I convert hex to decimal when receiving value? 
Thanks,
Demin zhang


Navigate by Date:
Prev: Re: decimal value convert to hex problem Ralph Lange
Next: Re:Fwd: Re: decimal value convert to hex problem zhangdemin99
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  <20132014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: decimal value convert to hex problem Ralph Lange
Next: Re:Fwd: Re: decimal value convert to hex problem zhangdemin99
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  <20132014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 20 Apr 2015 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·