10-10-2022, 11:06 AM
Hi
about using a 16bit program (FABS.COM tsr program) and machine code calls
I think your solution in Windows 64bit is only to use DosBox or similar emulator of 16bit machine...
You cannot get work QB64 and FABS, IMHO, you must access to memory by Call Absolute instructions
that in QB64 are emulated (?) or forbidden for incompatibility with 64bit OS.
A workaround can be using _MEM to access memory for reading and for writing, but it lasts that FABS.COM is a 16bit program TSR of DOS era.
It needs to be rewritten in QB64, if it is possible or with reverse engineering.
Good Luck
about using a 16bit program (FABS.COM tsr program) and machine code calls
I think your solution in Windows 64bit is only to use DosBox or similar emulator of 16bit machine...
You cannot get work QB64 and FABS, IMHO, you must access to memory by Call Absolute instructions
Code: (Select All)
The FABS routine would be this:
SUB fabs (cmnd$, recno, fseg, errf%, adrkey%)
'------------------------------------ FABSP ROUTINE ---------------- ----------------
DEF SEG = fseg
offset% = &H8
CALL ABSOLUTE(cmnd$, errf%, recno%, adrkey%, offset%)
rnlo = recno%: IF rnlo < 0 THEN rnlo = rnlo + 65536
cmnd$ = "X"
CALL ABSOLUTE(cmnd$, dum%, recno%, dum%, offset%)
rnhi = recno%: IF rnhi < 0 THEN rnhi = rnhi + 65536
recno = rnlo + rnhi * 65536
DEF SEG
END SUB
that in QB64 are emulated (?) or forbidden for incompatibility with 64bit OS.
A workaround can be using _MEM to access memory for reading and for writing, but it lasts that FABS.COM is a 16bit program TSR of DOS era.
It needs to be rewritten in QB64, if it is possible or with reverse engineering.
Good Luck