Help on SFC59

Greet

Member
Join Date
Aug 2003
Location
Mol
Posts
58
We have an analog input-module who has a fault. Now, I want to read the diagnostic data of this module. I have read the manual on how to call SFC59 in OB82 several times, but can not understand the whole thing.

CPU 318-2DP, S7 V5.1
It is an analog inputmodule with starting adress PIW300.

My questions:
1. REQ= can this always be 1 ? What happens: is he always reading the data or only once if the error rise?
2. IOID = B#16#54 -> OK?
3. LADDR = IW 300 -> OK?
4. RECNUM ???
5. RET_VAL = for example MW804
6. BUSY = M 5.0
7. RECORD = for example MW 806 ---->or is only data type BYTE permitted??

8.What is the difference between the RET_VAL- and the RECORD-output?
9.What can you do with the local dat of OB82?

Lot's of questions, isn't it ;)
 
If you just need to troubleshoot the module right here and now, just look in the diagnostics for the module in the hardware configuration in STEP7.

By the way, you do look a little bit young to be playing with PLCs :eek:
 
Greet said:
We have an analog input-module who has a fault. Now, I want to read the diagnostic data of this module. I have read the manual on how to call SFC59 in OB82 several times, but can not understand the whole thing.

SFC59???? isn't that for data transfer, i.e comms processors?

For diagnostics you want SFC51 or FB125, although I would use Jespers suggestion. Jesper asked a question on these blocks a little while ago click here for that thread


Paul
 
OK, but SFC51 is to read out the diagnostics of the DP-slaves, and I want to read the diagnostics of an Analog Input-card.

The error is there for just a little time (0.1ms). In the diagnostics of the CPU ther is only: External module error, channel error detected, external error, incoming event, Event 16#3942.

Now I want more specific diagnostic data by calling SFC59(RD-REC) in OB82.
 
In the STEP7 hardware configuration, highlight the DP node that has the error (not the CPU !), then select PLC ... Module Information.

That should display status and diagnostics for the particular node.

I believe that the SFC51 will simply provide the same diagnostic information as you can view in STEP7.
 
But if ther's no error, there is no module information available.

I want to program that I store the information if an error occures. An analog inpu-card is no DP-node, or am I so wrong?
 
I believe the diagnostics window allows you to browse previous errors.

Edit: I see now that you say it is in the CPU rack. Look in the diagnostics file if there are more messages (one error can generate several messages).
I do not know if you can open a diagnostics window for the analog module. Maybe you can.
 
Last edited:
Yes, but I want the informaton more specified.

I am using an analog module that supports diagnostics. If this detects an error, it sends a diagnostic interrupt request to the CPU. The OS then calls the OB82. In its local variables, the OB82 includes the logical basic adress and4 bytes of diagnostics information .

I should use SFC59 to read out the channel-specific diagnostics data.
 
Greet

The penny has finally dropped.. I understand what you are trying to do.

I still stand by my statement that you can't use SFC59 for this, but I do believe SFC51 will do what you want. I have never used this SFC so I can't be much help with setting it up, the Siemens help files will have to be your source of information, we know how helpfull they are....not!

Paul
 
greet,
maybe you can get additional information about that diagnostics entry with the button "Help on event" in the lower right corner of the diagnostics window.
 
Dear Greet,
Regarding SFC59
REQ should be 1 for one scan and cannot be again 1 until you'll see 0 at BUSY output.
IOID is ok.
LADDR should be w#16#012C (300 in hex).
RECNUM 0 or 1 however in your case should be 1.
RECORD is output of the SFC and can be as long as 240 bytes of data. You must provide here ANY pointer to large enough area.

You can do the same with SFC51.

Have look at manual "S7-300 Programmable Controller
Module Specifications" Appendix B "Diagnostics Data of Signal Modules". And have nice reading. :D
 

Similar Topics

I'm fairly new to Rockwell software, I've had some basic training in the past but nothing too advanced. My company and I use Reliable products for...
Replies
9
Views
238
Hi all I need help on this As in my project used Schneider TM241 controller. Now I want to communicate Elite energy meter with controller by...
Replies
3
Views
148
Hi all, I am having issues accessing my Cimplicity software - the site code changed after re-install and I am no longer able to attain a new key...
Replies
10
Views
156
Good day all! Can someone help me with the procedure to update Beijers E700 firmware? The Panel I am working on is firmware 2.04v and I would...
Replies
1
Views
62
Back
Top Bottom