Welcome, Guest
Username Password: Remember me
  • Page:
  • 1

TOPIC: Code to link status bits to outputs

Code to link status bits to outputs 1 year, 9 months ago #1669

  • KCL64
  • OFFLINE
  • Posts: 9
  • Karma: 0
Hi can someone suggest what code I would use to link Status bits 12 (Brs) and 13 (Bls)
to an output to signal a solid state relay to trigger a limit fault on my machine.

Thanks

Re: Code to link status bits to outputs 1 year, 9 months ago #1675

  • csearcy
  • OFFLINE
  • Posts: 480
  • Karma: 23
IF B(0,14)|B(0,15) OS(0) ELSE OR(0) ENDIF

NOTE: EDITED FOR TYPO
Last Edit: 1 year, 9 months ago by csearcy.

Re: Code to link status bits to outputs 1 year, 9 months ago #1678

  • KCL64
  • OFFLINE
  • Posts: 9
  • Karma: 0
Thanks but I'm still having an issue with the above code.
The output I would like to trigger with the Brs and Bls S/W limit switches is (Exp I/O 18)

Tried changing the code around but still no solution yet.
What I have at the moment is

IF(B(1,12)|(B(1,13) OS(17,2)
ENDIF

but I have an invalid expression term in it.

Any idea's Thanks Kent.

Re: Code to link status bits to outputs 1 year, 9 months ago #1679

  • csearcy
  • OFFLINE
  • Posts: 480
  • Karma: 23
Sorry Kent... I had a typo in the previous post. The following should work ok.

WHILE 1
IF B(0,14)| B(0,15) OS(17) ELSE OR(17) ENDIF
LOOP
END
  • Page:
  • 1
Moderators: hsummer, csearcy
Time to create page: 0.46 seconds