Twincat

Keep Open and Learning
jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Twincat

Post by jiataifeng » 28 Aug 2018 05:29

Last edited by jiataifeng on 16 Nov 2018 04:28, edited 4 times in total.

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Re: Twincat

Post by jiataifeng » 29 Aug 2018 05:28

DUT data unit type

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Re: Twincat

Post by jiataifeng » 01 Sep 2018 02:47

 ST – Structured Text
 FBD – Function Block Diagram
 LD – Ladder Diagram
 SFC – Sequential Function Chart
 IL – Instruction List
 CFC – Continuous Function Chart(Not part of the IEC standard)
 ADS - Automation Device Specification
 SPS-Variable
Last edited by jiataifeng on 20 Oct 2018 02:59, edited 2 times in total.

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Re: Twincat

Post by jiataifeng » 01 Sep 2018 02:53

1.png
1.png (41.35 KiB) Viewed 4136 times

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Re: Twincat

Post by jiataifeng » 01 Sep 2018 04:22

Following the Beckhoff coding convention, the name of the Function starts with F_

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Re: Twincat

Post by jiataifeng » 01 Sep 2018 04:36

Function Blocks are instantiated, therefore each time a Function
Block is used it must be assigned a unique instance name. Each instance receives
its own space in memory and therefore will retain its values from one PLC scan to
the next.

Local variable: static, i.e. the local data are available again in the next cycle. Each
FB call has its own local data.

Transfer by reference: 0,1,2,3.. VAR_IN_OUT

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Re: Twincat

Post by jiataifeng » 01 Sep 2018 04:58

The := symbol signifies that a value of the variable is being passed into the FB and
the => symbol signifies that a value of the variable is being passed out of the FB

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Re: Twincat

Post by jiataifeng » 07 Sep 2018 21:04

为了方便代码管理,应该尽量:
1. 将各个模块放到文件夹中管理。
2. 尽量减少全局变量的使用,非要使用,也应该在相应的模块中使用,不应该脱离其使用上下文。
3. 尽量使用FUNCTION.
4. 尽量使用Function block 去完成特定的子功能。

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

缩写

Post by jiataifeng » 20 Oct 2018 02:13

OPC UA:Open Platform Communications Unified Architecture
OPC-DA: Open Platform Communications Data Access
Last edited by jiataifeng on 20 Oct 2018 03:10, edited 1 time in total.

jiataifeng
Posts: 178
Joined: 30 Apr 2009 06:31

Twincat 功能范围

Post by jiataifeng » 20 Oct 2018 02:28

1. Database:读写数据库
2. TwinCAT OPC UA: 设备之间的通信,设备状态远程读取,实时地远程查询等
3. TwinCAT TCP/IP : sample
4. TwinCAT Modbus TCP:communicate over a network connection (TCP/IP) with the Modbus protocol.
5. TwinCAT SMTP/SMS:send alerts
6. TwinCAT PLC Serial Communication, sample
7. TwinCAT PLC Serial Communication 3964R-RK512
8. TwinCAT XML: write-/read-access for XML data
9. TwinCAT IEC-60870-5-10x
10. TwinCAT Ads:可以读写订阅ADS中的变量,例子
11. TwinCAT Modbus RTU: for serial communication with Modbus end devices
12. TwinCAT FTP: sample
13. TwinCAT TCP/UDP: direct access to network cards from the real-time environmen, sample
14. TwinCAT RFID Reader Communication:射频卡,ID认证
15. TwinCAT IoT Communication MQTT,物联网,云通信
16. TwinCAT Simulation Manager : supports a "virtual machine", which corresponds to the real machine in its performance characteristics
17. TwinCAT Management Server: enables the central administration of Beckhoff controllers
18. TwinCAT Backup/Restore:备份与恢复

Post Reply