hallo
Code:
//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include <conio.h>
#define Par_Sst 0x378
#define LPT1 0x378
#include "Unit1.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//==============================================
void outp (unsigned int portadr, unsigned char value)
{
_asm mov edx,portadr
_asm mov al, value
_asm out dx,al
}
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button1Click(TObject *Sender)
{
outp(Par_Sst,1);
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button2Click(TObject *Sender)
{
outp(Par_Sst,0);
}
//
da habe ich es besser beschrieben
https://www.roboternetz.de/phpBB2/viewtopic.php?t=1841
Lesezeichen