epics-base / pva2pva

PV Access gateway/proxy and EPICS Process Database integration
https://epics-base.github.io/pva2pva/
Other
4 stars 13 forks source link

Add display.precision and .format #19

Closed mdavidsaver closed 5 years ago

mdavidsaver commented 6 years ago

Add new fields for DBR style numeric precision and enumeration with format style.

mdavidsaver commented 5 years ago

My in-progress https://github.com/mdavidsaver/pva2pva/tree/format changes the display sub-structure to be as follows. The re-use of 'display.format' with a different type (enum vs. string) seems likely to cause problems. An alternative name will be needed.

    structure display
        double limitLow 0
        double limitHigh 0
        string description 
        string units 
        int precision 0
        enum_t format (0) Default
            int index 0
            string[] choices ["Default", "String", "Decimal", "Exponential", "Hex", "Engineering"]

@kasemir @shroffk @ttkorhonen @anjohnson @ralphlange

mdavidsaver commented 5 years ago

Closed with #24 .

Updated display sub-structure

    structure display
        double limitLow -10.123
        double limitHigh 10.123
        string description testing
        string units x
        int precision 2
        enum_t form (3) Decimal
            int index 3
            string[] choices ["Default", "String", "Binary", "Decimal", "Hex", "Exponential", "Engineering"]

Configured by including eg. info(Q:form, "Hex") in record definition.