Skip to content

thinkyhead/6502-Tools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

83 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

6502-Tools

Tools and enhancements to make working with 6502 Assembly Language on macOS more enjoyable, especially for retro-coding the Atari Computer and Atari 2600 VCS.

Atari800.tmTheme

For Sublime Text 3

Open the Sublime folder and copy the two plugin folders to your Packages folder (~/Library/Application Support/Sublime Text 3/Packages). Then, copy all the .sublime-settings files to the User subfolder. For the BASIC theme you'll need the font linked below.

Two plugins are currently provided:

  • ATASCII Insert adds commands to insert ATASCII text and to invert characters.
  • AtariTools provides two perfect themes, support for AtariBASIC and Batari BASIC, and a variety of useful capabilities to enhance your classic Atari 8-bit coding experience.

Atari BASIC Source Book

In celebration of the 50th birthday of the 6502 I cleaned up and repaired the Atari BASIC Source Code based on the original "Atari BASIC Source Book" by Bill Wilkinson, Kathleen O'Brien, and Paul Laughton. I started with a very good cleaned up dump Atari BASIC Rev.A/B/C from AtariAge that builds with ca65 and made the following improvements:

  • BNF Macros: BNF elements are now neatly defined inline with .byte. Much easier to modify and extend.
  • Added sourcebook.inc header with aliases for older / original symbol names for better alignment with the Source Book.
  • Applied original comments throughout the code — including almost all original typos!
  • Applied uppercase to all the Rev.1 mnemonics, leaving Rev.2/3 lowercase and un-documented.

This language can be improved by a mile. To modify the language you should add new BASIC_REVISION conditionals, then modify the link size and headers as-needed to get it to build and run. The Makefile is set up to build the historical cartridge ROMs, but it shouldn't be too hard to make runnable XEX files.

Watch this space as I'm working on implementing an AtariBASIC tokenizer and runner in Python and Javascript. This source code is going to be a very helpful guide in that project.

For Atom (obsolete)

.atom-build.js

This file, set up for a 2600 cartridge build, is used by Atom's standard Build package to specify the project build command and error pattern. Use the AtomBuild folder as a template for other 2600 code builds. For some cases make might be preferable.

Fast build with dasm.

  • Set asm_name in .atom-build.js. Then it will build with F9 (and build-on-save, if set). Passes all errors back to the build module.
  • Uses /usr/local install of 'dasm' and 'vcs' to build the project. Change if needed.
  • Public domain 2600 combat game source code included for testing.

Other things you'll need…

  • Sublime Text 3 - A light and fast extensible editor with a Python core. Can use TextMate bundles.
  • atari800 - A good, working Atari emulator that fails much of the acid test but runs pretty well. (Use F1 for settings!) Also available via package managers like MacPorts and Homebrew.
  • Atari800MacX - This nice Mac UI wrapper for Atari800. There's a Universal version 6.0.1 but sometimes 5.3.1 seems to work better.
  • Atari Classic Fonts - Regular, Chunky, Smooth, and ExtraSmooth - especially for use with Atari800.tmTheme. Use the newest all-in-one font for full ATASCII support. This is the preferred font for editing AtariBASIC.
  • Eightbit-Atari-Fonts - A collection of custom Atari fonts for use with Atari800.tmTheme.
  • dasm - A 6502 cross-assembler most commonly used to build Atari 2600 code. Also included with bAtariBASIC.
  • cc65 - A C cross-compiler for many 6502 platforms. A rich set of libraries is included.
  • ca65 - A 6502 macro-assembler, also including headers for many 6502 platforms.
  • Atari tools - Includes the atr command-line tool to manage ATR disk images and files.

Future Plans

Python is a great language for quick implementations and it's natively supported in Sublime Text.

  • Sublime Importer to convert Atari BASIC tokenized files.
  • Tokenizer for AtariBASIC so no emulator is needed to convert LST to BAS.
  • Interpreter to run and debug AtariBASIC in other environments.
  • Better support for Batari Basic in the macOS ecosystem.
  • Tools: Character, Map, Player/Missile, and Bitmap editing tools.

About

Support for AtariBASIC, 6502 Assembler, and bAtariBASIC in Sublime Text.

Topics

Resources

Stars

Watchers

Forks

Contributors