Hello there,
we are developing a project using PCGU1000 in our own hardware for medical purposes, using Delphi 2009. Everything is working fine so far.
But I’m facing problems using the Sweeping function over 2MHz.
[code]
// Interface declaration, taken from the Delphi programming example provided by Velleman
// Single has a range from 1,5 x 10^-45 to 3,4 x 10^38, 4 bytes
procedure SetSweep(freq1, freq2, ampl, offset, time: Single; form: Longint); stdcall; external ‘FGULink.dll’;
PCGU1000_DLL.LogSweep(FSweepingMethod = smLog); // Lin sweep, so this is FALSE
PCGU1000_DLL.SetSweep(
FStartFrequency, // 2100000 = 2,1 MHz
FEndFrequency, // 2100000 = 2,1 MHz
FAmplitude, // 5V
FOffset, // 0 V
FDuration / 1000, // 3000ms = 3s
Byte(FWaveForm) + 1 // 1 = Sine
);[/code]
No matter what I set, everything above 2.000.000 Hz produces a “Invalid floating point operation” error. Everything below (or equal to) 2.000.000 Hz works …
Any suggestions?
Thanks.