Hi.
Can I use formula to check “-” value when the communication has lost.
I use modbusRTU and I have a sensor which is discrete input register.
When the communication has lost, I have noticed that my sensor value became “-” so, i need to check if my sensor has lost communication my output should be equal 150.
public double check(double sensor)
{
double output = sensor;
if( sensor == null ){
return output = 150;
}
return output;
}
Thank you so much.