The invention relates to a runtime forcing method,
industrial equipment, a
system and a storage medium. In the application, when a
compiler compiles an original code input by a user to generate a
syntax tree, if the original code contains an assignment statement of a variable, the assignment statement is constructed into a target code supporting any bit forcing; the
compiler generates an
executable program according to the
syntax tree and transmits the
executable program to a programmable controller of the
industrial equipment; when the programmable controller runs the
executable program, performing bit operation according to the original value, the forced value and the forced flag bit of the variable to generate an actual value, and assigning the actual value to the variable; it can be seen that when the programmable controller runs the executable program to achieve variable
enforcement, accurate assignment of the variable can be achieved through the bit
operation mode, the mode eliminates a jump instruction, the program execution overhead of the programmable controller is greatly reduced, meanwhile, the scheme can further achieve a bit-level variable
enforcement function, and the program
enforcement efficiency is improved. And the forced
fineness is improved.