EasyManuals Logo

Nidec SM-Applications Series User Manual

Nidec SM-Applications Series
132 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #89 background imageLoading...
Page #89 background image
SM-Applications Modules & Motion Processors User Guide 89
Issue Number: 4
Safety
Information
Introduction Installation
Getting
Started
Parameters
DPL
Programming
Communications
Freeze and
Marker
CTSync
Inter-option
Synchronization
Diagnostics
Migration
Guide
Quick
Reference
Index
ANSIREPLY examples:
The first output argument returns the status of the ANSIREPLY command and can be
one of the following values:
-65536 = No reply received yet
-65537 = Reply received, but with bad checksum
-65538 = EOT received (i.e. parameter does not exist)
-65539 = NAK received
-65540 = ACK received
Result% = ANSIREADN(12, 1811) //perform ansi read
//has message been sent successfully
IF Result% = 0 THEN
//message not sent successfully
goto top:
ENDIF
Timeout% = 0 //message sent successfully so intialise timeout
DO
(status%, reply%) = ANSIREPLY()// get status and value of read
DELAY(1) // delay 100ms
LOOP WHILE Status% = -65536 AND Timeout% < 50 //Timeout=50xclock timebase
Background{
top:
Value% = #18.11
Result% = ANSIWRITEN(12, 1811, Value%, 1);write value to remote drive
IF Result% = 0 THEN
//message not sent successfully
goto top:
ENDIF
CALL get_reply: //get reply
GOTO top:
} //Background
get_reply:{
Timeout% = 0
DO
(Status%, Reply%) = ANSIREPLY()
LOOP WHILE Status% = -65536 AND Timeout% < 50
} //get_reply:

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Nidec SM-Applications Series and is the answer not in the manual?

Nidec SM-Applications Series Specifications

General IconGeneral
BrandNidec
ModelSM-Applications Series
CategoryControl Unit
LanguageEnglish

Related product manuals