I am programming in VB.net using VS2005 pro. I have a Picoscope 3224.
I have my declare function as follows:
Declare Function ps3000_run_streaming_ns Lib "ps3000.dll" (ByVal handle As Short, ByVal sample_interval As Long, ByVal time_units As Short, ByVal max_samples As Long, ByVal auto_stop As Short, ByVal noOfSamplesPerAggregate As Long, ByVal overview_buffer_size As Long) As Short
However, I get a stack imbalance whenever I call the function, with the suggestion that what I am passing to the unmanaged code is not what the unmanaged code is expecting. it maybe a coincidence, but only functions with the time_units parameter throw this error. The documentation only specifies a type of PS3000_TIME_UNIT?
short ps3000_run_streaming_ns (
unsigned long sample_interval,
unsigned long max_samples,
unsigned long noOfSamplesPerAggregate,
unsigned long overview_buffer_size )
I have tried a short type but this also fails. Any help?