Hello;
The gain parameter of the NI-DAQ functions is always a integer number. If you input 0.5 as that parameter you will get a compiler error.
To set the gain to 0.5, as the NI-DAQ on line help states, you should set that parameter to -1.
Regards
Filipe A.
Applications Engineer
National Instruments