5/19/2011 11:43 AM | |
Posts: 30 Rating:
|
Hi,
I'm working on programming a PLC program in Step7. For wich I need to calculate an average value. First I have 144 samples in a DB8 and second I have 180 samples in a DB9. So I need a block wich can just say: ADD all the samples in DB8 and DEV them by the number of samples (= DB8.DBW12?). And the same for DB9. So I found a block that might do the trick at: https://support.automation.siemens.com/WW/llisapi.dll?func=cslib.csinfo&objId=39333121&load=treecontent&lang=en&siteid=cseus&aktprim=0&objaction=csview&extranet=standard&viewreg=WW I put the file in my program and I hit compile STL source file. When I do so I get 6 error's: E Ln 000026 Col 013: Syntax error at #RESET. E Ln 000027 Col 013: Syntax error at _001. E Ln 000034 Col 013: Syntax error at ;. E Ln 000043 Col 013: Syntax error at #BY_VALUE_CHANGE. E Ln 000044 Col 013: Syntax error at nmw. E Ln 000052 Col 013: Syntax error at ;. Now I don't know how to fix this and so I'm stuck at this point. I'm not a great programmer and I can only work with FBD and not with STL so if somebody would know a solution I would be very thankful. Thanks in advance. Kind regards, MatthiasV |
5/19/2011 12:15 PM | |
Joined: 3/21/2006 Last visit: 4/25/2024 Posts: 10228 Rating:
|
Hello, For Step7 the right link is http://support.automation.siemens.com/WW/view/en/19345299 And another one - http://support.automation.siemens.com/WW/view/en/1021364 Best regards, Hristo Mihalev |
Last edited by: UMENCHO at: 5/19/2011 12:17 PM |
|
5/19/2011 1:15 PM | |
Posts: 30 Rating:
|
Thanks for the quick response UMENCHO. The second link you send me is the one I tried to use in the program but like I said I had 6 errors that I described in the above post. This one looks like the easiest way for me to program because It's for a project at school in wich I need to every step in the program. The first link looks a little hard for me. I can open the file but it doesn't allow a FBD view and only STL view. And like I said I reallydon't know anything about STL programming :s. Do you maybe know a way to make the second link work without the errors I'm having? Or is there a simple explanation for the first link that I could understand without any knowledge of accu, STL, ...? Kind regards, MatthiasV |
5/19/2011 1:25 PM | |
Joined: 3/21/2006 Last visit: 4/25/2024 Posts: 10228 Rating:
|
My suggestion is to follow MM1234' answer. Best regards, Hristo Mihalev |
This contribution was helpful to
4 thankful Users |
Follow us on