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

RIKENFE: Provide calibrated Magnet temperature PVs #7975

Closed
1 task
davidkeymer opened this issue Aug 24, 2023 · 5 comments
Closed
1 task

RIKENFE: Provide calibrated Magnet temperature PVs #7975

davidkeymer opened this issue Aug 24, 2023 · 5 comments
Assignees

Comments

@davidkeymer
Copy link
Contributor

davidkeymer commented Aug 24, 2023

As a support technician, I would like the RIKEN magnet temperature PVs to be calibrated values, so that they can be interpreted more easily. Currently, the values are raw voltages and have to be converted after extracting them from log files and/or the instrument database.

The provided calibration calculation steps are as follows (edited for clarity):

  • The tap value is a signed 12-bit integer measured by the PLC ADC which has a 10V reference. This needs to be converted back to a voltage: Vadc = (PV* / ((212)-1))*10
  • The PLC measures the signal conditioned voltage and so needs to be divided by a gain to get the actual voltage at the magnet terminals (gains are: RQ1 = 2, RB1 = 1.25, RQ2 = 5): Vtap = Vadc / gain
  • From the magnet voltage, the equivalent resistance can be computed by dividing the tap voltage by magnet current: Rtap = RT2 = Vtap / Imagnet
  • Then from this resistance, the temperature can be derived: RT2 = R23(1+0.004041(T2-23)) where RT2 is the resistance calculated and R23 is the initial resistance value, seen in linked excel sheet.

* - PV currently provided by SCHNEIDER IOC (raw tap voltage from PLC)

Acceptance Criterion

  • PVs provide actual temperature values.

Notes

  • Suggest retaining the existing PVs for the raw voltages, and creating corresponding PVs for the calibrated values
  • Raw voltage values are currently read by the main RIKEN PLC and in turn by the SCHNEIDER IOC running on the RIKEN control machine.
  • The calculations could be added to the record loaded by the SCHNEIDER IOC, but it may be preferable to create another IOC, or use INSTETC for load-balancing and to prevent coupling.
  • Historic data needs to be kept for at least a cycle so that potential trends in magnet temperatures can be identified. (may need to be covered by another ticket)
@davidkeymer davidkeymer added this to Proposals in Planning via automation Aug 24, 2023
@KathrynBaker KathrynBaker moved this from Proposals to Low in Planning Sep 7, 2023
@KathrynBaker KathrynBaker added the 8 label Sep 7, 2023
@KathrynBaker KathrynBaker added this to Ready in IBEX Project Board via automation Sep 7, 2023
@github-actions github-actions bot added ready and removed proposal labels Sep 7, 2023
@KathrynBaker KathrynBaker removed this from Low in Planning Sep 7, 2023
@KathrynBaker KathrynBaker added this to the SPRINT_2023_09_07 milestone Sep 7, 2023
@zsoltkebel zsoltkebel self-assigned this Sep 27, 2023
@zsoltkebel zsoltkebel moved this from Ready to In Progress in IBEX Project Board Sep 27, 2023
zsoltkebel added a commit that referenced this issue Oct 2, 2023
@zsoltkebel zsoltkebel mentioned this issue Oct 2, 2023
@zsoltkebel zsoltkebel moved this from In Progress to Review in IBEX Project Board Oct 2, 2023
@esmith1729
Copy link
Contributor

Was seeing some strange behaviour when magnets are turned off, NaNs and +/- Infinity for MOhms:

image

@esmith1729
Copy link
Contributor

It would also be good to write some system tests for this, even if a bit trivial.

@esmith1729 esmith1729 moved this from Review to In Progress in IBEX Project Board Oct 3, 2023
@zsoltkebel
Copy link
Contributor

I now added some simple tests because it is not possible (I think) to simulate calc records. I also added edge case handling in the calculations to guard against division by 0.

@zsoltkebel zsoltkebel moved this from In Progress to Review in IBEX Project Board Oct 3, 2023
@zsoltkebel zsoltkebel moved this from Review to In Progress in IBEX Project Board Oct 9, 2023
@zsoltkebel
Copy link
Contributor

New system tests have been added. Changes are made in support, ioc, and testframework. Those are important to pull before testing.

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

No branches or pull requests

5 participants