![]() |
![]() ![]()
Experimental Physics and
| ||||||||||||||||
|
The waveform record support 'exports' references to the memory pointed to by BPTR as well as it's size (NELM) via the record's 'cvt_dbaddr()' member. This means that other parts of EPICS potentially hold a copy of this information which would become inconsistent if you change either. Hence, device-support *must not* change BPTR or NELM. However, it is legal to set NORD to the number of elements that are currently stored in the waveform and NORD may be any number smaller than NELM. NORD is also what is returned by the record's get_array_info() member and it is correctly handled by dbGetField() but unfortunately the CA server (and client) ignores this feature of the database and always returns the number of elements the client asks for. Normally, clients use ca_element_count() to find out how many elements are in an array but that boils down to 'NELM'. You could let your client read NORD first and then read the corresponding number of array elements but unfortunately, there is no way to do this in an atomic operation :-( It would IMHO be a desirable feature to be able to tell the CA client/server that you want to read the current number of elements and the data in a single operation. BTW: Another feature that is implemented in the database (reading from an offset into an array) is IIRC not available through CA. -- Till On 06/07/2010 04:06 AM, [email protected] wrote: Hi All,
| ||||||||||||||||
ANJ, 02 Sep 2010 |
![]() · Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing · |