Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Pointer in Basic
#11
(07-16-2023, 09:57 PM)Kernelpanic Wrote: I've tried this now with VarPtr, Peek and Poke, and I didn't find any error in my exercise to achieve this. I don't see any at the moment either.

Remember that those commands were created to suit the 8-bit and 16-bit side of things. When Microsoft came up with WindowsXP they finished removing all the CALL INTERRUPT mechanism, the input/output ports and anything else that would make worthwhile accessing absolute memory locations to get serious work done. For a multitasking operating system using threads such commands could have caused a lot of harm and loss of money. PEEK and POKE made better sense when there was only a 64KB memory pool to work with, and everything had to fit in there: code, data, interpreter settings etc.

There used to be a page on the QB64 Wiki that listed the locations to use with PEEK and POKE to find functions in GW-BASIC and BASICA. It even had stuff to deal with the cassette recorder that was provided with the very first 16-bit IBM PC. It was extended for storing the current number of rows and columns of the terminal, for video memory and more.

QB64 emulates the DEF SEG for video memory but probably nothing else, and also what has to do with that for INP(), OUT and WAIT because an awful lot of programs written for QuickBASIC and QBasic rely on those ancient commands. Somebody programming exclusively in QB64 should never look back at that stuff. If he/she really wants pointers in BASIC "without the schmaltz" then use Freebasic or Purebasic, or just go into C or C++.
Reply


Messages In This Thread
Pointer in Basic - by Kernelpanic - 07-16-2023, 09:57 PM
RE: Pointer in Basic - by bplus - 07-16-2023, 10:17 PM
RE: Pointer in Basic - by mnrvovrfc - 07-17-2023, 12:05 AM
RE: Pointer in Basic - by SagaraS - 07-17-2023, 12:17 AM
RE: Pointer in Basic - by OldMoses - 07-17-2023, 12:40 AM
RE: Pointer in Basic - by bplus - 07-17-2023, 01:00 AM
RE: Pointer in Basic - by a740g - 07-17-2023, 02:53 AM
RE: Pointer in Basic - by SpriggsySpriggs - 07-17-2023, 11:55 AM
RE: Pointer in Basic - by Kernelpanic - 07-17-2023, 07:04 PM
RE: Pointer in Basic - by SagaraS - 07-17-2023, 09:39 PM
RE: Pointer in Basic - by mnrvovrfc - 07-17-2023, 10:52 PM
RE: Pointer in Basic - by Kernelpanic - 07-18-2023, 12:17 AM
RE: Pointer in Basic - by SagaraS - 07-18-2023, 02:42 AM
RE: Pointer in Basic - by bplus - 07-18-2023, 12:39 PM
RE: Pointer in Basic - by SMcNeill - 07-18-2023, 04:13 PM
RE: Pointer in Basic - by Kernelpanic - 07-18-2023, 04:26 PM
RE: Pointer in Basic - by SMcNeill - 07-18-2023, 04:59 PM
RE: Pointer in Basic - by SagaraS - 07-18-2023, 04:49 PM
RE: Pointer in Basic - by SMcNeill - 07-18-2023, 05:04 PM
RE: Pointer in Basic - by mnrvovrfc - 07-18-2023, 08:15 PM
RE: Pointer in Basic - by SagaraS - 07-18-2023, 07:30 PM
RE: Pointer in Basic - by SMcNeill - 07-18-2023, 10:11 PM
RE: Pointer in Basic - by SagaraS - 07-19-2023, 10:27 AM
RE: Pointer in Basic - by SMcNeill - 07-19-2023, 01:42 PM
RE: Pointer in Basic - by DSMan195276 - 07-19-2023, 11:15 PM



Users browsing this thread: 10 Guest(s)