pcdshub / solid-attenuator

LCLS Solid Attenuator System IOC
https://pcdshub.github.io/solid-attenuator
Other
1 stars 4 forks source link

Provide attenuator status to PMPS #60

Closed klauer closed 3 years ago

klauer commented 3 years ago

Expected Behavior

The attenuator is expected to provide the following information to PMPS:

Current Behavior

No information is currently shared beyond EPICS.

Possible Solution

  1. IOC -> PLC communication is typically done by way of ads-ioc (m-epics-twincat-ads). A pytmc link could bring values into the PLC, reflected as a function block instance (https://pcdshub.github.io/lcls-twincat-general/v2.4.2/LCLSGeneral_LCLSGeneral_source.html#fb-lrealfromepics).

  2. An alternative possibility would be using Zach's UDP-based communication protocol (currently intended for encoder positions, and currently only generated from PLC code) could be leveraged allowing more direct communication. This would have to be sent at regular intervals in place of a heartbeat.

klauer commented 3 years ago

Chose a 3rd solution: the PLC calculates attenuation on its own now. The status is easy to report back to PMPS by way of EtherCAT IO.

This solution makes providing the status out-of-scope to the calculator - a good thing. Closing.