@8_Bit
  @8_Bit
8-Bit Show And Tell | Soft-Patching C64 ROMs for Benchmark BASIC: 6510 Assembly Code Walkthrough @8_Bit | Uploaded September 2024 | Updated October 2024, 23 minutes ago.
Today we'll look through the Commodore 64 6510 assembly language source of the Benchmark BASIC utility. Even if you have no interest in the benchmarking aspects, we'll cover a wide variety of development techniques, including: use of the Turbo Macro Pro assembler, soft-patching the C64 ROMs, fixing the ?OUT OF MEMORY error, great resources for understanding the BASIC and KERNAL codebase, how location 1's memory control really works, how to use BASIC's floating point math routines, and even more.

To support 8-Bit Show And Tell:
Become a patron: patreon.com/8BitShowAndTell
One-time donation: paypal.me/8BitShowAndTell
2nd channel: youtube.com/channel/UCAgWzEh5c8391eJnELDy9OA

Download the Benchmark BASIC .d64 (see instructions below, and in video):
8bitshowandtell.com/downloads/bbasic.d64

Links mentioned in video:
Original Benchmark BASIC video: youtu.be/B-Cky_2l11U
Block Transfer fix: youtu.be/dG_oZV6s0Zg
PageTable: pagetable.com/c64ref/c64disasm
Tool Kit video: youtu.be/O8DRGqIZpPg
CodeBase: codebase64.org/doku.php?id=base:kernal_floating_point_mathematics
Transactor Anthology: archive.org/details/transactor-anthology
Greg's C64 OS 6510 port article: c64os.com/post/6510procport
Advanced machine language: archive.org/details/The_Advanced_Machine_Language_Book_for_the_Commodore_64
TI$ video: youtu.be/VkabHdR15xs

To use: mount/attach the .d64 image
LOAD"BENCHMARK BASIC",8,1
SYS 49152 to start
STOP+RESTORE keys to disable

To load the source code (requires REU):
LOAD"TMP+REU",8,1
SYS 32768
to view disk directory: [back arrow] *
to load: [back arrow] L
file name: bb33 (or whatever latest filename is on disk)
cursor keys to navigate source file
[back arrow] 3
press S to start

The REU is required to assemble to RAM at $C000 (where Benchmark BASIC lives) because Turbo Macro Pro also uses that memory range. But if you don't have access to an REU, a workaround is to assemble to disk with [back arrow] 5, and then give a filename. Once assembly is complete, you can reset the computer, load the object code with ,8,1 and SYS 49152 to start it.

Index:
0:00 Recap about Benchmark BASIC use
2:08 How to load the source in Turbo Macro Pro
4:28 About the $C000 origin, and why REU
8:50 SEI: Set Interrupt Disable
10:06 ?OUT OF MEMORY ERROR fix
13:53 ROM copy routine
18:06 Modify READY. prompt
19:20 Resources: PageTable.com and Dan Heeb's Tool Kit books
21:34 Patching RUN
23:00 Location 1: Switching out the ROMs
28:46 When RUN is typed... more patching
32:14 Jiffy Clock reset, handing control back
34:12 Just scrolling once, the wonders of C='s screen editor
38:44 Final cleanup
40:18 About BASIC's floating-point routines
43:10 Stashing, printing, converting, dividing floating points
48:36 ENDing
49:51 Conclusion, thanks!
Soft-Patching C64 ROMs for Benchmark BASIC: 6510 Assembly Code WalkthroughCommodore Magic Voice Software Prototype and Easter EggsOptimizing With Integers in Commodore 64 BASIC?Exploring the SuperCPU Accelerator for C64Project Creators Talk at VCFMW 2022: Meatloaf, Amiga Video, 8-Bit Guy, Giant SX-64INPUT Bug on Commodore VIC-20 #8bit #vic20 #shortsA Very Commodore 64 Christmas Special1979 Home Computer Buyers Guide: Apple II, Commodore PET, TRS-80, and The Very Obscure!Cracking a C64 Game From Cassette: Livingstone, I Presume?SuperCPU Sky Travel Easter Egg Hunt for Commodore 64C-64 Auto Player #2Re-typing My 1983 Game Programming Inspiration

Soft-Patching C64 ROMs for Benchmark BASIC: 6510 Assembly Code Walkthrough @8_Bit

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER