Zmotion focus on motion control and automation solutions. There are motion controller, vision motion controller, also motion control card, and each has several series. Today, motion control card is the "main character", that is, Zmotion motion control card -- ECIO series IO card. Specifically, through C# language, develop ECI IO card and test interaction speed of multiple IO reading and writing.
Let's begin!
(1) IO Card Function
For, ECI0032/ECI0064 ECIO series motion control card, it can be connected to the PC through Ethernet, RS232 communication interface for receiving commands from PC to execute. In addition, each expansion module can be linked through CAN bus to expand inputs and outputs.
ECIO series motion control cards (ECI0032/ECI0064) uses optimized network communication protocol to watch logic control and IO status in real-time.
As for the application program, VC, VB, C++, C# can be used to develop. While the program is running, it is necessary to use dynamical library zmotion.dll. During debugging, it can connect to ZDevelop and controller at the same time, in this way, easy to debug and convenient to observe.
ECI0032
ECI0064
(2) IO Card Hardware Interface
general input wiring reference
general output wiring reference
For more specific information, please refer to each user manual from "download".
(3) IO Control Card Basic Information
(1) New build WinForm project & Add function library
In VS2015 menu, click "file" -- "new build" -- "project".
Select "Visual C#", .NET Framework 4 and Windows app.
Obtain C# function library from the manufacturer, or c ontact us directly.
Copy obtained C# library files and relevant files into new-built project.
--copy zmcaux.cs file to new created project--
--put zaux.dll and zmotion.dll file into bin\debug folder--
Now, use vs to open new-built project file, click "show all files" in the right "solution resource manager". Then, right-click zmcaux.cs file -- included in project.
Double click Form1 in Form1.cs, when code editing interface appeared, write " using cszmcaux" in the beginning of the file, and declare controller handle "g_handle".
Here, project was created, it is time to do C# project development.
(2) PC Function Introduction
Get PC manual firstly from Zmotion website -- download -- software manual, or contact us directly.
--link with controller to get link handle--
--rapidly read multiple inputs' current status--
--rapidly read multiple outputs' current status--
(1) Routine Interface
(2) Relevant Codes
--call the interface function ZAux_OpenEth() that is used to link with controller in event processing function of link button to connect to controller, then open timer 1 to watch controller IO states when linked--
--watch controller IO status through timer 1--
--test function: multiple inputs' state reading speed--
--test function: multiple outputs' state reading speed--
--test function: multiple outputs' state configuration--
(3) Test Result of Interaction Speed Between Multi-IO And Upper Computer
32 inputs and 32 outputs.
Reading and writing times: 1000
Interaction speed test result:
32 inputs and 32 outputs.
Reading and writing times: 10000
Interaction speed test result:
32 inputs and 32 outputs.
Reading and writing times: 100000
Interaction speed test result:
The above is to test the reading speed of 32 inputs, the reading speed of 32 outputs and the writing speed of 32 outputs. From the data display of the above operation effect diagram, whether it is an input port or an output port, their interaction speed is maintained at around 200us.
When the number of tests increases from 1000 to 1W or even 10W, the interaction speed remains at around 200us. That is, the test results are very stable.
Then, the test data is shown in the table below:
ABOUT ZMOTION
That's all, thank you for your reading -- Zmotion Ethernet IO Control Card | C# Writing and Reading Test
For more information, please pay close attention to "Support" and "Download" , and there are other platforms about Zmotion - Youtube & LinkedIn & Twitter & Tiktok & Facebook, including technical information (development environment, routine code), product showing, company development, etc.
Hope to meet you, talk with you and be friends with you. Welcome!
This article is edited by ZMOTION, here, share with you, let's learn together.
ZMOTION: DO THE BEST TO USE MOTION CONTROL.
Note: Copyright belongs to Zmotion Technology, if there is reproduction, please indicate article source. Thank you.
Zmotion Technology focuses on development of motion control technology and general motion control products, it is a national high and new technology enterprise. Due to its concentration and hard work in motion control technology, ZMOTION already become one of the fastest growing industrial motion control companies in China, and is also the rare company who has managed core technologies of motion control and real time industrial control software completely. Here, Zmotion provides motion controller, motion control card, vision motion controller, expansion module and HMI. In addition, there is one program software developed by Zmotion -- ZDevelop. It is a good choice for you to program and compile. And program through upper computer, there is PC manual.
Zmotion Technology provides motion control card, motion controller, vision motion controller, expansion module and HMI. ( more keywords for Zmotion: EtherCAT motion control card, EtherCAT motion controller, motion control system, vision controller, motion control PLC, robot controller, vision positioning...)
Have a good day, best wishes, see you next time.