Beckhoff#TwinCAT TE1111 EtherCAT Simulation

今次我會向大家介紹一下TE1111 EtherCAT Simulation。我們可以利用這個function去import由其他project的ethercat io 設定,這些被import的ethercat io就會成為mirrored image,這止image可以和twincat的module連接起來。(例如te1400的simulink targe/te1420/或是普肯的plc process io等等)

總結來說,利用TE1111可以為你們提供這止解決方案:

  • 利用Mirrored Image IO和其他modules連接
  • 真實裝置和simulation裝置混在同一個環境
  • AOE/SOE Support(?)
  • COE參數Support(?COE)
  • Fault Simulation

題外話,te1111的demo 序號只可以讓simulatio io運行30分鐘。

使用CASE1

我們可能會在Virtual Commissioning使用這個te1111。裝置的配置就像下圖一樣,ethercat master和control pc simulation連接起來,然後ethercat master就和一部機的真實裝置連接起來。

這個配置的話,我們就需要在ethercat simulation device安裝te1111。

然後這兩合ipc是用標準ethercat 網線連接起來。

使用CASE2

這個case,ethercat network之間是用同1個ipc來simulation。

程式debug,Virtual Commissioning都是用同1台ipc用控制,今次的blog我們會用這個配置。

使用CASE3

使用cx而且配置著ek1110,然後和ethercat simulation ipc連接起來。

使用CASE4

使用CU2508。我也不知道。

Example

今次我們會介紹case2。

Real-Hardware Project side

首先打開配置ethercat master和coupler的project。

點擊Devices> Devices 1(EtherCAT)。

EtherCATのTabでExport Configuration File..でいまの構成をExportします。

在ethercat tab設定畫面中點擊export configuration file。

這個功能會把你project內的配置export出來。

另存新檔。

你會保存了1個xml file。

EtherCAT Simulation Project

新しいプロジェクト作成します。新增1個twincat project,點擊I/O>Devices,然後右擊Add New Item…。

選擇EtherCAT>EtherCAT Simulation,點擊ok。

現在你會見到在project中新增了一個ethercat simulation devices。

右點新增的Device 1,選Import ENI File。

選擇你剛才export的xml,然後open。

同じの構成がそのSimulation TwinCAT Projectも出てきます。

你會見到在新的project中和你剛才的export的配置是一樣的。

Activate Configuration。

你會見到有下圖的warning popup。

因為twincat中如果你不將devices io跟你project中的變數連接起來,那些變數是不會更新的。之類。

當然這只是一個warning,你的twincat system仍然可以無事start。

那我們現在就這加1個plc和一些變數跟ethercat simulation 的input/output modules連接起來。

在pou中定義定義一些process io。

そしてBuild Solutionします。そのStepはすごく大事です。

BuildしないとLinkできません。

請注意在定義完process io後,你一定需要build solution。

如果你不build solution的話,之前定義了變數不會出現。

EL1008

那我們現在點擊EL1008的channel1。

點擊Variable tab。

點擊Linked to..。

選擇剛材定義了的process io Term2_IN_2。

EL2008

然後在output module也做同一樣的設定。

今次選i的變數,選ok。


TEST

首先我們在plc中將q的現在值變成true。

你會見到EL1008的INPUT Channel1信號是變成true。

然後今次我們確定一下EL2008的Channel 1。

將Channel1的現在值變成True。

你會見到i的信號也會變成true。

byebye!

Twitter:@3threes2

email:soup01threes*gmail.com (*を@に)

Footer_Basic

Please Support some devices for my blog

Amazon Gift List

Find ME

Twitter:@3threes2
Email:soup01threes*gmail.com (* to @)
YoutubeChannel:https://www.youtube.com/channel/UCQ3CHGAIXZAbeOC_9mjQiWQ

シェアする

  • このエントリーをはてなブックマークに追加

フォローする