> On Apr 2, 2018, at 12:28 PM, renato sanhueza <[email protected]> wrote:
>
> Maybe I didn’t express myself correctly, but I was asking for the scenario in which the client doesn´t know a priori the details about the server that it wants to monitor (e.g. it might be a thermometer, a power supply, a fan, an antenna, etc).
Hi Renato—
Knowing only the name of the variable, the client can request the structure. For example, using the command-line pvget utility . . .
$ pvget BL6:Det:Metadata
BL6:Det:Metadata
structure
time_t timeStamp 2018-04-02T13:32:08.794 19815342
epics:nt/NTScalar:1.0 proton_charge
double value 0
epics:nt/NTScalarArray:1.0 time_of_flight
uint[] value []
epics:nt/NTScalarArray:1.0 pixel
uint[] value []
. . . tells me that the variable BL6:Det:Metadata has a structure consisting of a timeStamp, a NTScalar value for proton_charge, and NTScalarArrays for time_of_flight and pixel.
The client can then decide it wants to monitor only the timeStamp . . .
$ pvget -m BL6:Det:Metadata -r timeStamp
BL6:Det:Metadata
structure
time_t timeStamp 2018-04-02T13:38:55.189 19839726
BL6:Det:Metadata
structure
time_t timeStamp 2018-04-02T13:38:55.206 19839727
BL6:Det:Metadata
structure
time_t timeStamp 2018-04-02T13:38:55.223 19839728
> So the question is:
>
> Can a client use metadata to understand a message from an unknown server? (known as dynamic communication)
> Or the software developer has to known the structure of the server to make the client (static communication)
If you are using Normative Types, the client will understand the structure of the data. (In the example above, the structure is application specific, but the structure is built from standard normative types.)
However, using your example, for the client to understand that a structure is intended to represent a fan and that the speed is the variable to control, would likely require additional information on the client side.
--
Steven Hartman
[email protected]
- Replies:
- Re: question about pvAccess monitor Kasemir, Kay
- References:
- question about pvAccess monitor renato sanhueza
- Re: question about pvAccess monitor Johnson, Andrew N.
- Re: question about pvAccess monitor Mark Rivers
- Re: question about pvAccess monitor Johnson, Andrew N.
- Re: question about pvAccess monitor renato sanhueza
- Re: question about pvAccess monitor Marty Kraimer
- Re: question about pvAccess monitor renato sanhueza
- Navigate by Date:
- Prev:
Re: question about pvAccess monitor Marty Kraimer
- Next:
Re: question about pvAccess monitor Kasemir, Kay
- 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
- Navigate by Thread:
- Prev:
Re: question about pvAccess monitor Marty Kraimer
- Next:
Re: question about pvAccess monitor Kasemir, Kay
- 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
|