Hi,
I try to set the amplitude from some RSI SOURCE Objects and send the signal over ethernet. I adapted the Ethernet Example for this. But the line
ret=RSI_SETPUBLICPAR(CONTID,"SOURCE1","Amplitude", SIG1)
and the 3 lines after that gives me a "Invalid Parameter ID" and i cant find any information on this and there are no matches for "parameter ID" in the forum elsewhere. The signal values are Dummys
This is my full code. I am gratefull for any help.
--------- Code ------------
&ACCESS RVP
&REL 4
&PARAM TEMPLATE = C:\KRC\Roboter\Template\vorgabe
&PARAM EDITMASK = *
DEF RSI_AxisCorr( )
; Declaration of KRL variables
DECL INT ret ; Return value for RSI commands
DECL INT CONTID ; ContainerID
DECL REAL SIG1, SIG2, SIG3, SIG4
;FOLD INI
;FOLD BASISTECH INI
GLOBAL INTERRUPT DECL 3 WHEN $STOPMESS==TRUE DO IR_STOPM ( )
INTERRUPT ON 3
BAS (#INITMOV,0 )
;ENDFOLD (BASISTECH INI)
;FOLD USER INI
;Make your modifications here
;ENDFOLD (USER INI)
;ENDFOLD (INI)
; Prepare Values of for RSI communication
SIG1 = 1
SIG2 = 2
SIG3 = 3
SIG4 = 4
; Create RSI Context
ret = RSI_CREATE("ros_rsi_slm.rsi",CONTID,TRUE)
IF (ret <> RSIOK) THEN
HALT
ENDIF
; Modify Source parameter
ret=RSI_SETPUBLICPAR(CONTID,"SOURCE1","Amplitude", SIG1)
ret=RSI_SETPUBLICPAR(CONTID,"SOURCE2","Amplitude", SIG2)
ret=RSI_SETPUBLICPAR(CONTID,"SOURCE3","Amplitude", SIG3)
ret=RSI_SETPUBLICPAR(CONTID,"SOURCE4","Amplitude", SIG4)
IF (ret <> RSIOK) THEN
HALT
ENDIF
; Start RSI execution
ret = RSI_ON(#ABSOLUTE)
IF (ret <> RSIOK) THEN
HALT
ENDIF
; Sensor guided movement
RSI_MOVECORR()
; Turn off RSI
ret = RSI_OFF()
IF (ret <> RSIOK) THEN
HALT
ENDIF
END