If the address is static throughout the experiment, you could simply
declare a constant in the global user section:
Const MYPORT% = &H4000
You can then use MYPORT anywhere in your inline scripts.
xyz.OnsetSignalEnabled= True
xyz.OnsetSignalPort= MYPORT
xyz.OnsetSignalData= 25
The conversion to CInt is never required since the hex-value is
already interpreted as integer value.
cheers
Paul
Const MYPORT% = &H4000
is a type-declaration character that declares the constant MYPORT as
type Integer. In newer dialects you can achieve the same effect with
Const MYPORT as Integer = &H4000
depending on your own programming style.
-- David McFarlane