diff --git a/decomp.h b/decomp.h index ce8729e5..c99f0eac 100644 --- a/decomp.h +++ b/decomp.h @@ -11,3 +11,10 @@ // get the N versions. #define FLAGS_ZERO (_FLAGS & 0x40) /* JZ */ // ---------------- + +// Alternate version that sets the value first +#define OUTW2(port, val) __asm { \ + mov ax, val; \ + mov dx, port; \ + out dx, ax; \ +} diff --git a/th01/hardware/egcscopy.c b/th01/hardware/egcscopy.c index 4c78319a..8e9787ed 100644 --- a/th01/hardware/egcscopy.c +++ b/th01/hardware/egcscopy.c @@ -1,9 +1,4 @@ -// Alternate version that sets the value first -#define OUTW2(port, val) __asm { \ - mov ax, val; \ - mov dx, port; \ - out dx, ax; \ -} +#include "decomp.h" void pascal egc_start_copy(void) {