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: | Re: Stream Raw converter and un/signed integrer |
From: | Dirk Zimoch <[email protected]> |
To: | Emmanuel Mayssat <[email protected]> |
Cc: | [email protected] |
Date: | Wed, 31 Oct 2007 11:26:06 +0100 |
Hello all,
I am using stream and a 16 bit word to convert to an unsigned integer (0 to 64xxx). The unsigned integer is coded on 2 characters. So I use the raw converter and particularly %2.2r But with that converter then the integer is signed (as mentioned in the doc). So I can read values between 0 to 32767 and -32768 to -1.
Is there a way to use unsigned integer with the raw converter or do I have to write my own converter?
Looking at the RawConverter.cc code, I am afraid that I will have to
write my own...
-- Emmanuel
-- Dr. Dirk Zimoch Paul Scherrer Institut, WBGB/006 5232 Villigen PSI, Switzerland Phone +41 56 310 5182