EtherCAT I/O Solutions-Taiwan Pulse Motion

How to detect the communication status of Motionnet in a program?

After opening the Master card, initiate a mechanism to poll the Motionnet Ring status. The flowchart is as follows:

如何在程式中偵測Motionnet的通訊狀態_於Master開卡後,啟動一個輪詢Motionnet Ring狀態的機制

Command Descriptions:

1._mnet_get_ring_error_counter

This API provides a numeric value that continuously increases up to the maximum value of 65535 in case of communication abnormalities. In contrast, during normal communication, the value remains unchanged

Format

I16 status=_mnet_get_ring_error_counter(U16 RingNo, U16*ErrCount)

Purpose

Get the value of ring communication error counter.

Parameters

Name

Type

Description

RingNo

U16

Motionnet Ring number

ErrCount

U16*

The Value Of Ring Communication Error Counter

 

Status Return

Function Name

Description

ERR_NoError

The API Is Succes Return

ERR_Invalid_RingNo

Make Sure The Ring Is Active

 

Command Descriptions:

2._mnet_reset_ring_error_counter

This command is primarily used to reset the error count

Format

I16 status=_mnet_get_ring_error_counter(U16 RingNo)

Purpose

Reset the ring communication error counter.

Parameters

Name

Type

Description

RingNo

U16

Motionnet Ring number

 

Status Return

Function Name

Description

ERR_NoError

The API Is Succes Return

ERR_Invalid_RingNo

Make Sure The Ring Is Active

Command Descriptions:

3.__mnet_get_ring_status

Retrieve the status of the Ring in a bit format

Format

I16 status=_mnet_get_ring_error_counter(U16 RingNo,U16* status)

Purpose

Get the active ring status.

Parameters

Name

Type

Description

RingNo

U16

Motionnet Ring number

ErrCount

U16*

Ring Status

Bit

Meaning

0

Axis Command Empty

1

Reserved

2

Input change

3

IO Device Error

4

Axis Device Error

5

Master Setting

6

Master Operating Error

7

Reserved

8

Output Data

9

New Axis Command

A

New Axis Data

B

Reserved

C

IO cycle Busy

D

Soft reset

E

Axis cycle Busy

F

Reserved

 

Status Return

Function Name

Description

ERR_NoError

The API Is Succes Return

Command Descriptions:

4._mnet_get_com_status

You can detect the Ring’s status presented in a simplified numerical format (simplified status)

Format

I16 status=_mnet_get_com_status(U16 RingNo)

Purpose

Get the status of ring communication.

Parameters

Name

Type

Description

RingNo

U16

Motionnet Ring number

 

Status Return

Function Name

Description

ERR_NoError

Make Sure The Ring Is Active

 

Communication Status

Bit

Meaning

00

Ring Disconnected

01

Ring Connect

02

Slave Error

03

Ring Idle

04

Ring Error

05

CPU Access Error

06

IO Cycle Error

07

Data Communication Error

Close
Select the fields to be shown. Others will be hidden. Drag and drop to rearrange the order.
  • Image
  • SKU
  • Rating
  • Price
  • Stock
  • Availability
  • Add to cart
  • Description
  • Content
  • Weight
  • Dimensions
  • Additional information
  • Attributes
  • Custom attributes
  • Custom fields
Click outside to hide the compare bar
Compare
Close