View Full Version : Help~This error comes up after I download my program.

September 29th, 2010, 04:50 PM
I'm useing 315-2PN/DP.

September 29th, 2010, 04:51 PM
Why is that happening? What's that means? I couldn't find anything wrong. Thanks a lot.

September 29th, 2010, 05:11 PM
Try to remove OB8x and OB12x letting the CPU stop. Then the 'Open Block' button is clickable and you can find the cause.


September 29th, 2010, 05:43 PM
Thanks, I found the problem. The reason is I used a variable to open a DB indirectly like this:

OPN DB [#AlarmDB]

on the top of a FB. However, I have to repeat it more times in between of the program, otherwise, the program will create errors if I use DBWxxx . Seems like it doesn't know which DB it belongs to.

Have you experienced that?

L D[AR2,P#0.0]
September 29th, 2010, 05:48 PM
Are you accessing any other global db variables ?


OPN DB [#AlarmDB]

the global DB open is specified by AlarmDB

If you now have some processing as follows

A DB1.DBX0.0
= M0.0

The global DB open is now DB1

September 29th, 2010, 06:03 PM
No, I don't have any other global DB opened in the same FB.
If there is a Network that doesn't contain any data fron the DB[#AlarmDB], before the next Network with DBXxxx, I have to do "OPN DB [#AlarmDB] again, otherwise, it won't work.

September 29th, 2010, 06:06 PM
The internal variable in FB belongs to it's own instance DB, is it affecting the global DB? shouldn't , right?

L D[AR2,P#0.0]
September 29th, 2010, 06:06 PM
Post your code.

Here's an example showing the global DB changing from 200 to 5

September 30th, 2010, 09:44 AM

L D[AR2,P#0.0]
September 30th, 2010, 09:52 AM
No. Look at the column heading - you are displaying the accumulator (standard). Right click in the RH pane and you can make the DB1 resgister visible.

September 30th, 2010, 09:57 AM
OH, OK, it shows 1 from top to the bottom.

I know how to troubleshoot now. Thanks a lot. You are so diligent, alway available to help me. That's so nice. What is your time now?

L D[AR2,P#0.0]
September 30th, 2010, 09:59 AM

September 30th, 2010, 10:04 AM
WOW. yesterday, when I was 18:00, you were already 23:00. you sleep so late.

September 30th, 2010, 10:08 AM
Actually, I have more questions, I don't know how to ask. I already struggled for a long time.

I have an FC to create a "one shot" signal every time the input change the status. It works fine if I call it in OB1. However, if I call it an an FB, it doesn't work, it works but the "one shot" signal doesn't show in the FB. I don't know why.

L D[AR2,P#0.0]
September 30th, 2010, 11:46 AM
You are probably using a temp variable to store the rising edge status in the FC- temps are not remembered between calls.(although it can happen depending on what other blocks are called and what they do to their allocated temp data).

When you have a problem post your code.

September 30th, 2010, 01:28 PM
I changed it to FB and made a STAT multi instance in another FB. Now it works fine.
Thanks. I'll post the code next time.