raw-call-on-nonraw-fc.awl 357 B

123456789101112131415161718192021
  1. FUNCTION FC 1 : VOID
  2. VAR_INPUT
  3. IN0 : INT;
  4. END_VAR
  5. BEGIN
  6. L #IN0
  7. END_FUNCTION
  8. ORGANIZATION_BLOCK OB 1
  9. BEGIN
  10. // Using UC together with a non-raw FC shall fail gracefully.
  11. // Note that on S7 this might "succeed" and do some undefined stuff,
  12. // but we don't support that.
  13. UC FC 1
  14. CALL SFC 46 // STOP CPU
  15. END_ORGANIZATION_BLOCK