Formal Specification and Code Generation of Programable Logic Controllers

Authors:
  • RWRui Wang
    Rui Wang
  • MGMing Gu
    Ming Gu
  • XSXiaoyu Song
    Xiaoyu Song
  • HWHai Wan
    Hai Wan

Abstract
Programable logic controllers (PLCs) are complex cyber-physical systems which are widely used in industry. This paper presents a robust approach to design and implement PLC-based embedded systems. Timed automata are used to model the controller and its environment. We validate the design model with resort to model checking techniques. We propose an algorithm to generate PLC code from timed automata and implement this algorithm with a prototype tool. This method can condense the developing process and guarantee the correctness of PLC programs. A case study demonstrates the effectiveness of our method.