Thema: Delphi C Programm nach Pascal

Einzelnen Beitrag anzeigen

Benutzerbild von Neutral General
Neutral General

Registriert seit: 16. Jan 2004
Ort: Bendorf
5.219 Beiträge
 
Delphi 10.2 Tokyo Professional
 
#3

Re: C Programm nach Pascal

  Alt 3. Feb 2009, 21:01
Hi 3_of_8,

Den map_base Pointer musst du vorher noch nach Cardinal casten. Sonst gibts nen Compilerfehler:

Zitat von 3_of_8:
So würde ich jetzt sagen:

Delphi-Quellcode:
const PIO_A27: LongWord = 1 shl 27;

var
  map_base: Pointer;

//Das sagtest du ja ist kein Problem

PLongWord(Cardinal(map_base)+ (PIOA_PER and MAP_MASK))^ := PIO_A26 or PIO_A25 or PIO_A24 or PIO_All or PIO_A14;
Michael
"Programmers talk about software development on weekends, vacations, and over meals not because they lack imagination,
but because their imagination reveals worlds that others cannot see."
  Mit Zitat antworten Zitat