Hi Oggi,
the integral part of a PID control integrates the error term over time, so you need to calc the error and add it to the value in a shift register.
Why don't you use the PID functions coming with LabVIEW?
Best regards,
GerdW
using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019