pcdshub / lcls-twincat-general

A PLC code toolkit for LCLS TwinCAT PLC projects

Home Page:https://pcdshub.github.io/lcls-twincat-general/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fields with invalid pragmas

ZLLentz opened this issue · comments

ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SER_RBV.NIST" to "COMERROR_INVALIDPROCESSDATASIZE" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SER_RBV.ELST" to "COMERROR_INVALIDCHANNELNUMBER" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SER_RBV.TTST" to "COMERROR_INVALIDNUMDATABITS" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SER_RBV.FTST" to "COMERROR_INVALIDNUMSTOPBITS" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SEND_RBV.NIST" to "COMERROR_INVALIDPROCESSDATASIZE" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SEND_RBV.ELST" to "COMERROR_INVALIDCHANNELNUMBER" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SEND_RBV.TTST" to "COMERROR_INVALIDNUMDATABITS" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:SEND_RBV.FTST" to "COMERROR_INVALIDNUMSTOPBITS" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:RECV_RBV.NIST" to "COMERROR_INVALIDPROCESSDATASIZE" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:RECV_RBV.ELST" to "COMERROR_INVALIDCHANNELNUMBER" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:RECV_RBV.TTST" to "COMERROR_INVALIDNUMDATABITS" Error (512,512)
ErrorCan't set "IM1L0:XTES:MFW:RAW:ERR:RECV_RBV.FTST" to "COMERROR_INVALIDNUMSTOPBITS" Error (512,512)

We should improve the linting check in ads-ioc to use the dbd file - it can catch these invalid fields.

I'm going to move this issue over to the general lib because that's where the function block lives now. There's nothing weird in the pragma itself, I think it's just on an incompatible type? ComError_t seems to be unhappy to be included in an IOC.

I think it's the length is too long for an enum string (16 chars IIRC?)

Got it. Sounds Like I need to either remove these pragmas or create a custom ENUM with shorter names to mirror the values to.