User manual
PC Oscilloscope PCSU100019
© 2005 ... Velleman
#include
"DSOLink.h"
#include
"DSOLink_demo.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource
"*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall
TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void
__fastcall
TForm1::Button1Click(TObject *Sender)
{
int
data[
5000
];
ReadCh1(data);
Memo1->Clear();
Memo1->Lines->Add(
"Sample rate [Hz]: "
+IntToStr(data[
0
]));
Memo1->Lines->Add(
"Full scale [mV]: "
+IntToStr(data[
1
]));
Memo1->Lines->Add(
"GND level [counts]: "
+IntToStr(data[
2
]));
Memo1->Lines->Add(
""
);
for
(
int
i =
0
; i <
20
; i++)
{
Memo1->Lines->Add(
"Data "
+IntToStr(i)+
char
(
9
)+IntToStr(data[i+
3
]));
}
}
//---------------------------------------------------------------------------
Opmerking:
Is de importbibliotheek niet compatibel met uw versie van Borland C++ version, dan kan
u een importbibliotheek creëren door IMPLIB op de DLL te laten draaien.
IMPLIB works like this:
IMPLIB (destination lib name) (source dll)
Voorbeeld,
IMPLIB DSOLink.lib DSOLink.dll