Floats F8, Status S2, and Control R6

showshocka

Member
Join Date
Mar 2011
Location
USA
Posts
510
I was looking for a Glossary on these terms to learn the difference in these. What is a round about meaning for each F8,S2,and R6 when associated with a project, such as F23:8 in this screenshot attached. i know it's being used as a " Jam at elevator" alarm output to the PV, but why not use an interger. What's the difference?
 
These are different file types. A F type is floating point, 8 is the file number. F8 is created by default, but as with the rest, you can have as many as memory allows. S2 is a status file which contains infomation about the processor. You can't create them. R6 is a default control file type. You use these with certain functions such as FIFOs, FSCs. You can create files as needed.
 
Last edited:
If you need to work with decimals on smaller numbers, Floating Point is the way to go. If your numbers are large (google "mantissa" for lots of fun reading) then a floating point becomes inaccurate. On the other hand an integer can only go as high as the memory word holding it allows. You run out of bits eventually. Either way, you have to learn to manage your numbers.

Edit:
By "smaller numbers" I mean small compared to very large. Actually, very small numbers will be inaccurate as well. If you're not actually programming you don't need to worry about it haha.
 
Last edited:
I'm guessing that a float is being used because the particular CPU does not have the Long (L) data type available and they want a number higher that 32767.

The help file for RSLogix 500 will have the meaning of the different data types as well as the PDF manual (available from Allen Bradley free online).

S2 is the file containing various information generated by the system status.

R6 are control structures for some more complex instructions which execute over many scans to keep track of information - like position within a file for example.
 
So basically what I'm getting from what you guys are explaining is that a float F is probably the only one close to being used to what an integer or a bit will be used for, to communicate various states to the PV? basically. i'm going through the PLC project and i'm noticing that everwhere they have a value of 600000 in the LEQ instrutions they use a float F, and for smaller numbers such as 320000 in the LEQ instructions, they use integers N....sounds about right?
 
Last edited:
Integer is 'N' (7) by default
Bits are 'B' (3) by default
I like to use a different number for Screen area values - it is easier to fault trace.
ie N10: or B11: etc.
 
A signed integer in a 16 bit word will max out at 32,767. So yeah, maybe they are using floats to compare numbers larger than that. I would have used floats for all if I was going to use them for some, but that's just me. The LEQ is a comparison block (less than or equal to).
 
such as F23:8 in this screenshot attached. i know it's being used as a " Jam at elevator" alarm output to the PV, but why not use an interger. What's the difference?
It appears to me that F23:8 is not actually an alarm output, but is some number that has a value of about 60,000. If were simply an On/Off alarm output, you are correct that it would not have to be a Floating-point number, and the shorter number used, generally the less memory wasted.
 

Similar Topics

This is all pertaining to the Micro850 and modbus. A couple things: 1.) How do you read double words? I can read/write words but there's no...
Replies
4
Views
5,014
You can't use decimals in a 1747-l524? I have an analog output card that needs a number from 31208 to 0 for 4-20 mA I need to calculate...
Replies
19
Views
3,973
I am writing a program for a training course to use floats to control the inlet and outlet valves on a water tank. I've got the program done to...
Replies
2
Views
1,724
First off, I'd like to thank everyone on here. Although this is my first post this forum has always been very helpful. I am renovating a WWTP...
Replies
0
Views
1,943
PLC SLC5/04 i am doing some limit comparisons based on ranges coming from an analog input card. Thing is the analog input card will have a raw...
Replies
3
Views
1,651
Back
Top Bottom