TON and TOF Timer Blocks in Simulink Ignore Preset Time (PRE)
Hello,
I tried to simulate a very similar PLC model like presented in here https://nl.mathworks.com/help/plccoder/ug/ladder-logic-using-timers.html . The differences are Im using step signal which is converted into boolean for the input, you can see my model in the attached file.
However, it seems like the preset time just doesn’t work. Everytime the switch is on, then the lamp is automatically "on", while it is supposed to be delayed for around 6 seconds (the preset time). I have tried everything, even mirroring every setting and values set in the file from here https://nl.mathworks.com/help/plccoder/ug/ladder-logic-using-timers.html. I have also ensured the initfcn, etc. But still doesnt work as it should be. Im using matlab R2024b. I also put the sceenshots of the windows below.
Thanks for the help.Hello,
I tried to simulate a very similar PLC model like presented in here https://nl.mathworks.com/help/plccoder/ug/ladder-logic-using-timers.html . The differences are Im using step signal which is converted into boolean for the input, you can see my model in the attached file.
However, it seems like the preset time just doesn’t work. Everytime the switch is on, then the lamp is automatically "on", while it is supposed to be delayed for around 6 seconds (the preset time). I have tried everything, even mirroring every setting and values set in the file from here https://nl.mathworks.com/help/plccoder/ug/ladder-logic-using-timers.html. I have also ensured the initfcn, etc. But still doesnt work as it should be. Im using matlab R2024b. I also put the sceenshots of the windows below.
Thanks for the help. Hello,
I tried to simulate a very similar PLC model like presented in here https://nl.mathworks.com/help/plccoder/ug/ladder-logic-using-timers.html . The differences are Im using step signal which is converted into boolean for the input, you can see my model in the attached file.
However, it seems like the preset time just doesn’t work. Everytime the switch is on, then the lamp is automatically "on", while it is supposed to be delayed for around 6 seconds (the preset time). I have tried everything, even mirroring every setting and values set in the file from here https://nl.mathworks.com/help/plccoder/ug/ladder-logic-using-timers.html. I have also ensured the initfcn, etc. But still doesnt work as it should be. Im using matlab R2024b. I also put the sceenshots of the windows below.
Thanks for the help. plc, ton, tof, simulink, studio5000, timer MATLAB Answers — New Questions