Follow this link: luxlink.com
I believe there're plenty similar devices. This is simply first thing I ran into after googling.
Regards,
Jacek
Do it right or don't do it at all.
"Most electricians understand BCD rather than decimal or hex. I am glad octal has all but vanished though."
BCD is numeric format - it describes what is meaning of bits in bit string.
Hex, decimal and octal as well as binary are forms of presenting bit strings.
And god save us from electricians...
Have a look at the S_PEXT S5 timer. You won't need the one-shot then.
If you ask of symbol of the one-shot in LAD then you have two options: -(P)- or POS. But check manual to be sure. It's been long time since I used LAD.
Regards,
Jacek
Do it right or don't do it at all.
Surely no. But to solve your problem quickly, I'd advise you to write these 9's from your program into the DB directly.
Otherwise you have two ways:
- using functions from library (like I_STRNG) which are aware of how a string data type should be properly assembled
- writting your own functions...
If your string starts at 0.0 (or 12.0) then you should put manually at 1.0 (or 13.0) actual number of valid characters (in your case 9 ?). Otherwise there's zero so FC10 sees two empty strings (even if you enter something) and result of such a comparison is always "true".
Regards,
Jacek
Do it...
Switch your LAD editor to STL View and try this:
L input1 //input1, input2 ... to be repleaced with actual
ITD //addresses or symbols
//-------------
L input2
ITD
+D
//-------------
//part between dashed lines to be repeated
//until you use all inputs
L 12
/D
T average //here is your...
CPUs with order number 6ES7 314-6CF01-0AB0 (firmware 2.0.0) and newer are DPV1. I'm not sure about olders.
Regards,
Jacek
Do it right or don't do it at all.
I put your data to Excel. x - analog reading, y - gate position. Made a char out of this data. Added a trend line (2nd order poly) and that's what I got: y = -7E-07x2 + 0,0092x - 6,1082. However it looks like poor fitting.
You could improve it by taking more measurements.
Regards,
Jacek
Do it...
Use SFC21 FILL. First initialize some memory area with desired value then use FILL with this area as input BVAL.
Other solution is as always DIY:
OPN DB 100 //target DB
LAR1 P#DBX 100.0 //start of target area
L 0 //init val...
When I said "yes" I ment:
CALL "READ_CLK"
RET_VAL:=#iRetVal
CDT :=DB1.DT1
where DT1 is data of type DT defined in DB1.
Regards,
Jacek
Do it right or don't do it at all.