How do you pulse an IO point from a button?
Answers
-
Go to the control panel on the pendant. There you will find programmable keys. Set up the key you want to use and select pulse and the DO to pulse.Lee Justice0
-
Thomas J said:I want to pulse a specific IO point when a button is pressed. Is there an example available that shows how to do this?As you've posted in the AppStudio section, I presume you mean using an AppStudio button, not a flex pendant physical button.This functionality doesn't appear to have been implemented for the TComponents.ButtonIt should be!There should be on option to pulse a DO in "onClick" or toggle it on/off in onPointDown and onPointRelease so that you have a momentary switch operation.
At present we can only use a TComponents.Switch which is not momentary.The best work around I can suggest is the create a procedure which in turn calls PulseDOYou can then use the "Execute procedure" function in the OnClick behaviour to call that procedure.
EDIT:
I've found that you can create a function in AppStudio ans set the DO in that.
There appears to be pulse functionality but I can't find any documentation on the parameters.
I'm able to set a DO but unsure how to pulse it.
Something like thisasync () => {API.RWS.SIGNAL.setSignalValue("doFr1ErrorQuit", 1,{activePulse:1,passivePulse:0,pulses:10});}
But this just sets the signal high. I don't know if activPulse and passivePulse are supposed to be the state, the duration or what?
Post edited by od1 on0 -
After finding the documentation I was able to pulse a signal by creating this function in the button "onClick" behaviorAPI.RWS.SIGNAL.setSignalValue("doMySignal", 1,{mode:"pulse",activePulse:500,passivePulse:100,pulses:2});
setSignalValue(signalName, value, mode:, pulses:, activePulse:, passivePulse:, deviceType, networkType, attr)
Modify signal's valueParameters:
Name Type Description signalName
string value
number mode:
string value | pulse | invert | toggle | delay pulses:
number Number of pulses.Pulses is required if mode is toggle/pulse. activePulse:
number Active pulse length, in ms passivePulse:
number Passive pulse length, in ms deviceType
string networkType
string attr
*
0
Categories
- All Categories
- 5.6K RobotStudio
- 398 UpFeed
- 20 Tutorials
- 13 RobotApps
- 299 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 250 ScreenMaker
- 2.8K Robot Controller
- 327 IRC5
- 65 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 821 RAPID Programming
- 8 AppStudio
- 3 RobotStudio AR Viewer
- 19 Wizard Easy Programming
- 105 Collaborative Robots
- 5 Job listings