Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix several mtca evm db errors #141

Merged
merged 2 commits into from
Mar 26, 2024

Conversation

Insomnia1437
Copy link
Contributor

  • upgrade version of GitHub actions to remove warning
  • fix & add more 1pps source
  • fix FracSyn db limit
  • fix evrcml.db typo
  • fix DC status PDVLD bits meaning
  • change record name TimeSrc-Sel (in evrSoftEvt.template) to SoftTimeSrc-Sel to avoid duplicate of record name (also in evrbase.db)
  • add prescaler to embedded EVR definition
  • other small fix

* fix & add more 1pps source
* fix FracSyn db limit
* fix evrcml.db typo
* fix DC status PDVLD bits meaning
* change record TimeSrc-Sel (evrSoftEvt.template) to SoftTimeSrc-Sel to avoid duplication of record name
* add prescaler to embedded EVR
* other small fix
@jerzyjamroz
Copy link
Contributor

New related PR will be added soon following some comments.

@jerzyjamroz jerzyjamroz merged commit d757be7 into epics-modules:master Mar 26, 2024
11 checks passed
@Insomnia1437
Copy link
Contributor Author

@jerzyjamroz
For the DESC of embedded EVR's output PV, how about using conditional operator?
$(T)FP0->(EVGIN[$(T)==D?0:8] &!$(T)FPIN0),
in this way the length is 32 which is within the maximum string length of DESC (40).

file "mrmevrout.db"
{pattern
{ON, OBJ, DESC}
{"\$(P)OutFP0", "$(EVG):EVR$(T):FrontOut0", "$(T)FP0->(EVGIN[$(T)==D?0:8] &!$(T)FPIN0)"}
{"\$(P)OutFP1", "$(EVG):EVR$(T):FrontOut1", "$(T)FP1->(EVGIN[$(T)==D?1:9] &!$(T)FPIN1)"}
{"\$(P)OutFP2", "$(EVG):EVR$(T):FrontOut2", "$(T)FP2->(EVGIN[$(T)==D?2:10]&!$(T)FPIN2)"}
{"\$(P)OutFP3", "$(EVG):EVR$(T):FrontOut3", "$(T)FP3->(EVGIN[$(T)==D?3:11]&!$(T)FPIN3)"}
{"\$(P)OutFP4", "$(EVG):EVR$(T):FrontOut4", "$(T)FP4->(EVGIN[$(T)==D?4:12]&!$(T)FPIN4)"}
{"\$(P)OutFP5", "$(EVG):EVR$(T):FrontOut5", "$(T)FP5->(EVGIN[$(T)==D?5:13]&!$(T)FPIN5)"}
{"\$(P)OutFP6", "$(EVG):EVR$(T):FrontOut6", "$(T)FP6->(EVGIN[$(T)==D?6:14]&!$(T)FPIN6)"}
{"\$(P)OutFP7", "$(EVG):EVR$(T):FrontOut7", "$(T)FP7->(EVGIN[$(T)==D?7:15]&!$(T)FPIN7)"}
}

@prjemian
Copy link

Consider the maximum number of characters allowed for a DESC field. With the $(T) macro, this might exceed the maximum.

@Insomnia1437
Copy link
Contributor Author

@prjemian
Thanks for your comment.
I thought user should follow this rule,

# P - Prefix
# T - Embedded EVR type: e.g. {U,D} ~ {upstream,downstream}, assumptions !U=D !D=U

then T is either U or D, there is no problem. But if T = EVRU/EVRD, then it will exceed the maximum.
Perhaps $(T)FP7->EVGIN[$(T)==D?7:15]&!$(T)FPIN7 is better. Even EVRU/D is used, the length is 39.

@jerzyjamroz
Copy link
Contributor

@Insomnia1437 ,

  • FPIN -> I realized the input definition is: InFP, so let's follow that in DESC.
  • :EVRU/D strings are hardcoded so if one does not use T==(U or D) in the .subs file, the object will fail, so no other option.
  • I think it is better to keep "Out/In".
  • I would propose something like that: InEVG[$(T)==D?0:8]&!$(T)InFP0 because the PV name itself is OutFP0 and it does not need to be repeated in DESC.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants