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

Subject: Re: Problem when formating a field as HEX32
From: "Kasemir, Kay" <[email protected]>
To: Pilar Gil Jaldo <[email protected]>, "[email protected]" <[email protected]>
Date: Tue, 14 Nov 2017 14:01:43 +0000
Hi:

When I try your example with a plain record, bo device support, it works OK:

record(ao, "MaskSet")
{
     field(DOL, 255)
     field(LOPR, 0x00000000)
     field(HOPR, 0x7FFFFFFF)
     field(PINI, "YES")
}

Enter 0xFFFFFF7 -> I get 0xFFFFFF7
Enter 0xFFFFFF0 -> I get 0xFFFFFF0
Enter 0x800007F ->  I get 0x800007F
Enter 0x8000080 -> I get 0x8000080
Enter FFFFFFFF (no leading '0x') -> I get 0xFFFFFFFF
0 -> 0x0
-1 -> 0xFFFFFFFF
-7 -> 0xFFFFFFF9

==> Could your number clamping be caused by the asyn device support that you're using?

-Kay

________________________________________
From: [email protected] <[email protected]> on behalf of Pilar Gil Jaldo <[email protected]>
Sent: Tuesday, November 14, 2017 5:17 AM
To: [email protected]
Subject: Problem when formating a field as HEX32

Dear all,

I am having following problem.

MaskSet is a 32 double variable:

record(ao, "$(user):MaskSet")
{
     field(DTYP ,"asynInt32")
     field(OUT  ,"@asyn($(PORT),$(ADDR),$(TIMEOUT))mask")
     field(LOPR, 0x00000000)
     field(HOPR, 0x7FFFFFFF)
     field(PINI, "YES")
}

For the CSS/BOY,  I have defined a text input field which makes possible
to change the value of this field.
When I set "Default" as format type of the field, everything works fine.
The problem comes when changing the format type to "HEX32". In this
case,  it is not possible to control the introduced value to the set field.

For example,

if we introduce 0xFFFFFF7, after pressing Enter, the value changes
automatically to 0xFFFFFF0.
Or when 0x800007F ->  the input value changes to 0x8000080.

If now,  I change the format type to "Default" again and introduce the
value 134217855 ( 0x800007F as decimal) every works as it should.

Have somebody an idea of what is happening?

Kind regards,
Pilar Gil



Replies:
Re: Problem when formating a field as HEX32 Pilar Gil Jaldo
References:
Problem when formating a field as HEX32 Pilar Gil Jaldo

Navigate by Date:
Prev: Re: areaDetector and HDF5 file saving segafaults Mark Rivers
Next: Re: Problem when formating a field as HEX32 Pilar Gil Jaldo
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <20172018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Problem when formating a field as HEX32 Pilar Gil Jaldo
Next: Re: Problem when formating a field as HEX32 Pilar Gil Jaldo
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <20172018  2019  2020  2021  2022  2023  2024