Autor Beitrag
heinze
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 112

XP
D4 Prof
BeitragVerfasst: Do 01.07.04 14:14 
Hi

Kann mir vieleicht jemand sagen wie ich den 8-Poligen Stecker am PC über delphi anspreche?
fuser
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 23



BeitragVerfasst: Fr 02.07.04 12:11 
Was für einen 8-Poligen Stecker ?? Das LAN ist doch eine Buchse...
Falls Du Dich verzählt hast :wink: :
Für RS232 gibt es Komponenten.
Barfuss geht's so :

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
function TFormCOMRead.COMCreate(const COMName:String):THandle;
begin
   Result:= CreateFile(
    pchar(COMName),              // pointer to name of the file
    GENERIC_WRITE or GENERIC_READ,  // access (read-write) mode
    0,                              // share mode fdwShareMode parameter must be 0(exclusive access),
    nil,                            // pointer to security attributes
    OPEN_EXISTING,                  // how to create the fdwCreate parameter must be OPEN_EXISTING,
    FILE_ATTRIBUTE_NORMAL,          // file attributes
    0                               // handle to file with attributes to copy  and the hTemplate parameter must be NULL.
   );
end;


Dann WriteFile und ReadFile

Für direkten Hardwarezugriff für W9X, NT, XP gibt's
von Alexander Weitzman smallport: smport.vxd und smport.sys
heinze Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 112

XP
D4 Prof
BeitragVerfasst: Fr 02.07.04 12:53 
Also ich hab hinten am PC einen anschlus (zapfen stehen nach drausen) und über des will i Daten von ein Geräge auslesen. Ist der des Etwa?

Jedenfals auf dem Adapter für den Stecker steht nur 8 Polliger Addapter