MX FAQ0001
01-Jun-2011
Q: Will it be possible to program the older DL-PLCs with DirectSOFT-MX?
A: No, only the MX-275 and MX-275e are currently programmable with DirectSOFT-MX.
Originally we intended to allow the programming of the older DL-PLCs, but as the design developed we realized by moving to strong data types and structures we were fundamentally changing the way we did some critical things which moved us further and further away from maintaining compatibility with DL-PLCs. So the decision was made to build the best controller and software we could instead of trying to maintain compatibility with DL-PLCs.
MX FAQ0002
01-Jun-2011
Q: Will there be a DirectSOFT6 for the older DL-PLCs?
A: Yes. After MX is rolled out, there are plans to do another major release of
DirectSOFT for the older DL-PLCs.
MX FAQ0003
03-Jun-2011
Q: Why are there no ISG (Initial Stage) instructions?
A: In the DL-PLCs there is no
program modularity and users are therefore forced to modularize their programs
with stages and therefore multiple ISGs were needed. By contrast, MX-PLCs
are designed to be modular (Tasks & Programs) with Programs supporting stages.
Since each Program can have its own block of 128 stages running independently
and the very first stage is the initial one, then the ISG instruction is not
needed. This simplifies stages and encourages a better programming practice of
having a single well-defined entry point for a sequence.
If multiple parallel sequences are needed in a
single program, use the DIVERGE instruction in the first stage or simply set the
other stages from the first stage.
In an MX-PLC, Programs should be thought of as individual sequencing operations
and each sequencing operation should have one starting point.
MX FAQ0004
03-Jun-2011
Q: Does the MX-CPU have more memory than the DL260?
A: Yes.
MEMORY ELEMENT | DL260 | MX-275/275e |
Data | 34 Kbytes | 256 Kbytes |
Program | 15,872 instruction words | 65,536 instruction words |
MX FAQ0005
03-Jun-2011
Q: Are the more complex high-level instructions (e.g. network R/W and Math) more
efficient that IBoxes in the DL260?
A: Except for MATH, yes. IBoxes are just macros whereas all the complex
instructions in MX are native and all of the interlocking to the instruction and
device driver are internal. But as for MATH it is still much faster in the MX
(e.g. integer MATH in MX is nearly as fast as the simple contact/coil
instructions!).
MX FAQ0006
03-Jun-2011
Q: What is the typical scantime of an MX-PLC?
A: Like all things PLC, this is a wide open question. The minimum scan time is
about 150 µs. Certain modules that tax the DL205 backplane a bit (e.g. CTRIO/CTRIO2)
will raise that. With a single CTRIO2 in the base the minimum scan is about 258
µs. Boolean instructions, math and boolean stack operations, and most integer
math operations are all very fast, generally running at about 50 ns per
instruction, or 50 µs per K of logic.
More complex instructions, of course, will increase the scan accordingly. Given
typical PLC programming the typical scantime will probably be submillisecond to
a few milliseconds. So for most users, speed won't be an issue, especially if
Stages and modularity mechanisms are utilized as intended.
MX FAQ0007
03-Jun-2011
Q: Will interrupts be supported?
A: Not at this point. We are considering come changes to that in the future, but
it is not critical for the MX-PLC given its performance (speed).
MX FAQ0008
03-Jun-2011
Q: Is the serial communication half or full duplex?
A: Full duplex. It is possible to fill the MX base with H2-SERIO-4 modules
and run MX Server, Modbus RTU Server, Modbus RTU Client, K-Sequence Server, or
even custom protocols on every port simultaneously.
MX FAQ0009
03-Jun-2011
Q: How many Modbus TCP clients (masters) can talk to the MX-275e internal
Ethernet port?
A: The MX-275e can maintain 16 connections as a Modbus TCP Server (slave). If
the 17th master attempts a TCP connection, the MX-275e would simply reject the
connection request.
MX FAQ0010
07-Jun-2011
Q: Will DirectSOFT-MX be free?
A: We have not decided yet. There are many pros and cons we are considering.
MX FAQ0011
07-Jun-2011
Q: Will there be any type of utility (like DNLoader) that the end customer can
use to update their PLC without needing a copy of DirectSOFT-MX and without
knowing the PLC password?
A: There are plans on having a very elaborate tool for MX that does this. This
tool will button up firmware, program, and data into a single encrypted file and
basically take an MX-PLC from an unknown state to ready to run.
MX FAQ0012
07-Jun-2011
Q: What kind of program security does MX have?
A: Each code block in an MX-PLCs can be individually configured as Full Access,
Read Only, or Locked. When Locked, the block is not even viewable without a
password.
MX FAQ0013
08-Jun-2011
Q: Is there a utility that will translate DL230, DL240, DL250(-1) and DL260
projects into MX projects?
A: Currently, no. Try exporting your DL boolean logic STR/AND/OR/OUT coil
and with some minor edits to that file you might could get that to import to MX.
However, there is no accumulator exposed via user instructions (i.e. no LD/OUT
word, no LD LD LD OP type sequences), hence converting a higher level 240 to an
MX program would be like converting assembly into C++, with lots
of caveats. But the Export/Import could possibly convert 60-80% of the code with
contact/coil, rung comments, and element documentation, but it's the last 20-40%
that will need a complete rewrite in DirectSOFT-MX. And actually, it will
probably be much easier to write the MX version due to the greatly
enhanced high level functions.
MX FAQ0014
08-Jun-2011
Q: What communication protocols are supported by MX?
A:
The following:
Natively:
Write your own:
MX FAQ0015
08-Jun-2011
Q: Will current OPC servers for the DL-PLCs also work for the MX-CPU?
A: Yes, using either Modbus or K-sequence drivers. An MX driver for KepDirect is
to be announced.
MX FAQ0016
08-Jun-2011
Q: What are the highest values for timers and counters?
A: Timers are all millisecond resolution using 32-bit signed numbers
(-2,147,483,648 to +2,147,438,647), thus millisecond resolution for more than 24
days. Counters are also 32-bit signed numbers, hence you can count up to
2,147,438,647 or down to -2,147,438,648.
MX FAQ0017
02-Jun-2011
Q: Are the familiar DL-PLC memory types supported in MX-PLCs?
A: Most DL memory types also exist in an MX-PLC. X, Y, and
C are Discrete Input, Discrete Output, and Internal Bits. However, MX
element blocks are numbered in decimal, not octal.
So, yes, there is an X8 (and an X9).
V memory in MX is a 16-bit unsigned integer, with a range of 0-65,535.
Instead of storing 32-bit IEEE real numbers in V memory, or 32-bit integer in V
memory, we created two additional memory blocks, R and D,
respectively. Each element in the R block is a 32-bit real number. Each element
in the D block is a 32-bit signed 2's complement integer number. Both of these
blocks also have decimal IDs.
Use V memory when you need integer values 0-65535.
Use D memory when you need a signed integer.
Use R memory when you need real.
The good news is that the MATH instruction can properly handle mixing and
matching any of these data types in MX. For instance, this is a valid MATH
expression:
(ROUND(SQRT(R0)) + V8) * D3.
Timer/Counter bits and accumulator values are now part of Timer and
Counter structures. T0 represents the entire Timer structure for timer T0.
Within these structures are various "dot fields," e.g. .Done .Acc .Reset. To
know when Timer #0 is done, enter T0.Done. To look at Counter #9's accumulator,
enter CT9.Acc. This means that V0 is User V memory, not T0's accumulator like in
the DL-PLCs. Also, all of the .Acc accumulators are 32-bit signed integers with
a range of -2,147,438,648 to +2,147,438,647.
MX FAQ0018
01-Jun-2011
Q: Is there an instruction list for MX?
A: What follows is a complete instruction list for MX-275/275e CPUs:
Contacts
Normally Open, Normally Closed,
Positive Differential, Negative Differential, Inline Inverter, Inline
Differential, Delta(Changed)
Relational Contacts - ALL 6 = <> < <= > >=
Able to compare ANY types of numeric data V7 > R3 Can also be used inside MATH
instruction
Coils – OUT, SET, RST, END, NOP
Alarm Boxes
ALDEV – Deviation Alarm
ALHILO – High/Low Alarm
ALRATE – Rate of Change Alarm
Assignment Boxes
INIT – Initialize Multiple Elements
MEMCOPY – Copy Memory
MOVE – Move Value
MOVER – Move Range of Values
REFWRITE – Write Value Indirectly
RSTR – Reset Bit Range
SETNUMR – Set Numeric Range
SETR – Set Bit Range
BCD Boxes
BCDTO – BCD to Integer/Real
TOBCD – Integer/Real to BCD
Bit Boxes
DECO – Decode to Set Bit
ENCO – Encode Bit Position
PONOFF – Push On/Push Off
SUMBITS – Count # of 1 Bits
MX/DL Communication Boxes
DLRX – DirectLOGIC Network Read
DLWX – DirectLOGIC Network Write
PEERLINK – Share Data w/PLCs
Conversion Boxes
FREQCNT – Frequency Counter
FREQTMR – Frequency Timer
GRAY – Gray Code to Integer
SCALE – Scale Value
SEG – Hex/BCD to 7 Segment Display
STR2INT – Convert String to Integer
STR2REAL – Convert String to Real
SWAPB – Swap Bytes
Counter Boxes
CNT – Up Counter
CNTDN – Down Counter
RSTCT - Reset Counter
UDC - Up/Down Counter
CTRIO Boxes
CTAXCFG – CTRIO2 Axis Configuration
CTAXDYNP – CTRIO2 Axis Run Dynamic Pos.
CTAXJOG – CTRIO2 Axis Jog
CTAXLIMT – CTRIO2 Axis Run Trapzd w/Limits
CTAXTRAP – CTRIO2 Axis Run Trapezoid
CTDYNPOS – CTRIO Run Dynamic Position
CTDYNVEL – CTRIO Run Dynamic Velocity
CTPLSADD – CTRIO Add Entry to PLS
CTPLSEDT – CTRIO Edit PLS Entry
CTREGRD – CTRIO Read Register
CTREGWR – CTRIO Write Register
CTROMWRT – CTRIO Write File to ROM
CTRUNPOS – CTRIO Run Position Mode
CTRUNVEL – CTRIO Run Velocity Mode
CTTBLADD – CTRIO Add Entry to Preset Table
CTTBLCLR – CTRIO Clear Table
CTTBLEDT – CTRIO Edit Preset Table Entry
CTTBLLD – CTRIO Load Table
CTUPDLVL – CTRIO Update Level Mode
Date/Time/Calendar Boxes
DT2EPOCH – Convert Date/Time to Epoch
DTCMP – Compare Date/Time
DTDIFF – Difference between 2 Date/Times
DTOFFSET – Add Offset to Date/Time
EPOCH2DT – Convert Epoch to Date/Time
NETTIME – SNTP Client
SETTIME – Set PLC Date/Time
Device Boxes
CLOSE – Close Device
DEVCLEAR – Clear Device
DEVREAD – Read Device Register
DEVWRITE – Write Device Register
OPENDEV – Open Device
Differential/Edge/Clock Boxes
ND – Trailing Edge One-Shot
PD – Leading Edge One-Shot
Drum Boxes
DRUM – Timed/Event/Timed-Event Drum
Ethernet Boxes
EMAIL – Send EMail
OPENTCP – Open TCP Connection
SETUPIP – Setup TCP/IP Parameters
SETUPNOD – Setup Ethernet Node Parms
TCPLISTEN – Listen on TCP Port
UDPIN – Input UDP Packet to String
UDPOUT – Output UDP Packet
Externally Sourced Data Boxes
PUBLISH – Translate from MX
SUBSCRIB – Translate to MX
Hardware Information Boxes
HWINFO – Get Hardware Information
Intelligent Module Boxes
RD – Read from Intelligent Module
WT – Write to Intelligent Module
Looping Boxes
FOR – Index Loop
NEXT – Index by Step
REPEAT – Start of Repeat/Until Loop
UNTIL – Repeat/Until Condition is Non-0
WHILE – Loop While Condition is Non-0
WEND – End While Loop
BREAK – Exit Loop
CONTINUE – Skip to Loop End
Math Boxes
MATH – Calculate Expression
Math-Basic Boxes
DEC – Decrement
INC – Increment
Math-High Level Boxes
RANDSEED – Random Number Seed
Modbus Boxes
MRX – Modbus Network Read (TCP & RTU)
MWX – Modbus Network Write (TCP & RTU)
Process Boxes
CLAMP – Limit Range
DEADBAND – Set Outside Deadband
FILTER – First Order Filter
INTEGRAT – Integrate over Time
PID – Closed Loop Controller
PIDINIT – Set PID Tuning Constants
RAMPSOAK – Ramp/Soak Profile
SLOPE – Calculate Slope
TIMEPROP – Time Proportional Control
Program Control Boxes
ENTASK – Enable Task
EXIT – Exit this Program
GOTO – Go To Label
HALT – Halt Program or Task
LABEL – Code Label
REBOOT – Reboot PLC
RESTART – Restart Program or Task
RSTWT – Reset Watchdog Timer
RUN – Run Program
STOP – Switch to Program Mode
SUSPEND – Suspend Program/Task Execution
YIELD – Yield Program/Task Execution
Protocol Boxes
CHECKSUM – Checksum Algorithm
STRGETB – Get Bytes Out of a String
STRPUTB – Put Bytes Into a String
Serial Port
SETUPSER – Setup Serial Port
Shift Boxes
ROTL – Rotate Left
ROTR – Rotate Right
SR – Shift Register
Stage Boxes
JMP – Jump to Stage
JMPI – Indexed Jump to Stage
SG – Stage (first SG is Initial SG)
SGCONVRG – Converge Multiple SGs
SGDIVRG – Jump to Multiple Stages
SGRST – Disable Stage
SGRSTR – Disable Range of Stages
SGSET – Enable Stage
String (ASCII/Buffer) Boxes
STRCMP – String Compare
STRFIND – Find within a String
STRIN – Input String from Device
STROUT – Output String to Device
STROUTL – Output String to User Log
STROUTS – Output String to String
STRSUB – Get Sub-String
STRTRIM – Trim Whitespace
STRTRUNC – Set String Length
Timer Boxes
OFFDTMR – Off Delay Timer
ONDTMR – On Delay Timer
RSTT – Reset Timer
TMR – Timer
TMRA – Accumulating Timer
TMRADOWN – Accumulating Time Down
TMRDOWN – Time Down
MATH Operators & Functions
+ - * / Add, Subtract, Multiply, Divide
% Modulo (Remainder)
** Raise to Power
- Negate
& Bitwise AND
| Bitwise OR
^ Bitwise XOR
~ Bitwise Invert
<< Shift Left
>> Shift Right
>>> Unsigned Shift Right
&& Logical AND
|| Logical OR
! Logical NOT
== Equal To
!= Not Equal To
< Less Than
<= Less Than or Equal To
> Greater Than
>= Greater Than or Equal To
ABS(exp) Absolute Value
ACOS(exp) Arc Cosine
ASIN(exp) Arc Sine
ATAN(exp) Arc Tangent
AVG(start, #val) Average of range
COS(exp) Cosine of radian angle
DEG(exp) Convert radians to degrees
FRAC(exp) Fractional part of real
LN(exp) Natural Log base e
LOG(exp) Log base 10
MIN(start, #val) Min. value in range
MAX(start, #val) Max. value in range
NOW() $Now 1970 Epoch value
RAD(exp) Convert degrees to radians
RANDINT() Random Int 0 to 2,147,483,647
RANDREAL() Random Real 0.0-1.0
ROUND(exp) Round real number
SIN(exp) Sine of radian angle
SQRT(exp) Square Root
SUM(start, #val) Sum values in range
TAN(exp) Tangent of radian angle
TICKus() System uSec Counter Val
TICKms() System mSec Counter Val
TOINT(exp) Convert Real to Integer
TOREAL(exp) Convert Int. to Real
TRUNC(exp) Truncate Real number
MX FAQ0019
07-Jun-2011
Q: What do the PUBLISH and SUBSCRIB instructions do?
A: These instructions could possibly be needed when an external system is
providing data or the MX-PLC is providing data to an external system and the
data types do not exactly match. These instructions let you move/convert/align
the data to MX memory locations. Both of these are table instructions, where for
each row in the table instruction, you enter a source, destination and number of
elements and the options for converting it.
Those options are:
The way it was envisioned was to stick one or more SUBSCRIB instructions in the Top of Scan task, and one or more PUBLISH instructions at the Bottom of Scan task, whose sole purpose is to move/convert data to/from 'public' memory and from/to 'internal' memory. Clean and well-bounded.
MX FAQ0020
10-Jun-2011
Q: Is there an OROUT instruction (or equivalent) so that an output can be
controlled from more than one ladder rung?
A: There is no OROUT instruction or an equivalent. However the functionality
of an OROUT can be implemented by using the system block $TopOfScan and an RST
of the output there. Then elsewhere in the program use SET of that same output.
MX FAQ0021
10-Jun-2011
Q: The XRef (cross reference) only shows addresses. Can it show rung numbers
instead?
A: The address that is shown is a link to the instruction that it is used
in. Rung numbers map to multiple instructions. Just click on the link and it
will take you to the rung and the block cursor will be overtop of the exact
instruction. Once there, you can see the rung number in the margin. However, in
a future version of MX we are considering keeping the link to be addressed based
but the display you actually see is the rung number.
MX FAQ0022
15-Jun-2011
Q: How can I clear a string (SS or SL)?
A: Use the STRTRUNC instruction and set the length to 0 (which is the
default).
MX FAQ0023
13-Jun-2011
Q: What is the functional equivalent to a DirectLOGIC LD (Load) instruction?
A: Use the INIT or MOVE instruction.