我們的品牌

Impact-Company-Logo-English Black-01-177x54

歡迎造訪施耐德電機全球網站

歡迎訪問我們的網站
		
我们今天能为您提供什么帮助?
How to generate a PTO (pulse train output) using a M241 controller with SoMachine?

Issue:
This is a step by step procedure on how to write a small program in SoMachine to generate a PTO (pulse train output) using a M241 controller

Product Line:
M241 controllers

Environment:
SoMachine v4.3

Cause:
To have a starting project that will help a customer generate a PTO (pulse train output) with a M241 controller

Resolution
1. Start a new project in SoMachine and select a M241 controller
2. Go to the Logic Builer. Go to View / Classic Navigators / Devices. This will open a window called Devices.
3. In the Devices window double-click on Pulse_Generators. This will open a window called Pulse_Generators.
4. In the Pulse_Generators window select a Pulse generation function by clicking on the Value field. Select PTO and hit Enter
5. Select the Output Mode. You have four options. For this resolution we will select Quadrature
6. Select the outputs to be used by selecting a Fast output in the "A output location" and "B output location"
7. The Instance Name is the name that will be used by the input pin "Axis" of the MC_xx_PTO function blocks. You can leave the default PTO_0 or change it
8. Create a POU and add it to the Mast task. To create a POU go to Devices window / right click on Application / Add object / POU. Select  CFC for this example, any other implementation language can be used. To add the POU to the MAST task just drag it there
9. Double-click on the new POU. From the Toolbox window select "Box" and then click in the POU window.
10. We will create the following function blocks: MC_Power_PTO, MC_Stop_PTO, MC_ReadActualPosition_PTO, MC_MoveRelative_PTO, MC_MoveVelocity_PTO. Other function blocks can be used
11. For the Axis pin we will type in PTO_0 or if you change the Instance name from step 7, used the new name.
12. Build your project and download it to your controller. Tu build it go to Build / Build. To download go to Online / Multiple Download / Always perform a full download. This will update the boot application and download the project to the RAM. Connect to your controller by going to Online / Login.
13. To enable MC_Power_PTO function block, pin Enable and DriveReady have to be TRUE. You can create variables that you can turn ON or you can type the word TRUE instead of a variable
14. We can generate an unlimited pulse train output with a fixed frequency by using the MC_MoveVelocity_PTO. You will need to have values entered at least for Velocity, Acceleration, Deceleration and Direction
14. By turning the Execute bit ON of the MC_MoveVelocity_PTO function block, the M241 will generate a PTO with a frequency equal with the Velocity value.
15. To stop the pulses execute a MC_Stop_PTO
16. You can generate a finite number of pulses by executing the MC_MoveRelative_PTO. You will have to have values entered at least for Distance, Velocity, Acceleration, Deceleration. After that you will have to turn the Execute bit ON.



This completes the step by step procedure on how to write a small program in SoMachine to generate a PTO (pulse train output) using a M241 controller

If this FAQ did not solve your issue, you can chat with us at chat with us or e-mail us at customer.services@se.com to create a case with our Technical Support Team.

If you are not located in North America, please contact your local Customer Care Center for assistance:

Support | Schneider Electric Global (se.com)


施耐德電機Taiwan

探索更多
系列:
探索更多
系列:

需要協助?

  • 產品選型工具

    快速輕鬆地為您的應用找到合適的產品和附件。

  • 取得報價

    立即線上提交您的銷售需求,專業團隊將主動聯繫您。

  • 購買地點

    輕鬆在您所在地區找到最近的施耐德電機經銷商。

  • 支援中心

    在同一位置找到滿足您所有需求的支援資源。

  • 產品文檔
  • 軟體下載
  • 產品選型工具
  • 產品替代和替換
  • 幫助和聯絡中心
  • 尋找我們的辦公室
  • 取得報價
  • 人才招募
  • 公司簡介
  • 舉報不當行為
  • 無障礙
  • 新聞中心
  • 投資者
  • 專業洞察
  • 台灣施耐德電機學院
  • 綠色影響力落差調查
  • Schneider Go Green 2025
  • 隱私政策
  • Cookie通告
  • 使用條款
  • Change your cookie settings