A Visual Studio Code extension that provides language support for C64 development using the c6510 Assembler.
- Syntax highlighting
- Hovering shows information about
- Instruction Set - including illegal instructions
- Addressing modes
- Affected status flags
- Byte count
- Cycle count
- Known addresses
- VIC
- SID
- CIA1
- CIA2
- Number representations
- Decimal
- Hexadecimal
- Binary
- Instruction Set - including illegal instructions
- Go to definition of
- variable
- constant
- label
- macro
- macro parameter
- Go to references of
- variable
- constant
- label
- macro
- macro parameter
- instructions
- Commands for
- Build current file
- Build and Run current file
- Completion and hover support for embedded Lua and Squirrel scripts
Language support like syntax highlighting of the embedded script languages Lua and Squirrel require installation of separate extensions for those.
The following settings are available for the extension. They are organized under the C6510
header.
- Build File: Name of the file describing how to build the source in the directory of the currently open file. This file also specifies paths to search for included files when looking for definitions/references.
- Assembler » Executable Path: Path to the c6510 binary. Unless specified it is expected to be found in the default search path.
- Assembler » Clear Previous Output: When enabled this will clear the output from previous run every time.
- Assembler » Include Paths: An array of strings specifying global include search paths, i.e. directories
that are always considered when reading included source files while searching for definitions in
Go to definition
. E.g. the directory with the c6510 provided include files. - Assembler » Option » Output File: Specifies the name and optionally path of the resulting output PRG file.
- Assembler » Option » Symbol file: Specifies the name and optionally path of a symbol file in VICE format resulting from building the source files.
- Assembler » Option » Additional Sources: Array of strings of paths of additional implicit source files to be processed before the current source file is processed.
- Assembler » Option » Preset Defines: Array of strings of additional implicit constant definitions before the source files are processed.
- Assembler » Option » Command Line: Command line used to invoke assembler. The following placeholder
variables may be used.
${executablePath}
- path to the c6510 executable.${includes}
- list of all specified include paths, each prepended with proper command line option.${presets}
- list of all specified preset definitions, each prepended with proper command line option.${additionals}
- list of all specified additional source files, to process before the current text document, each prepended with proper command line option.${symbolPath}
- path to the symbol file.${outputPath}
- path to the target output PRG file.${sourceFile}
- file name of the current text document.
- Emulator » Command Line: Command line used to invoke emulator. The following placeholder variables may be used:
${symbolPath}
- path to the symbol file.${outputPath}
- path to the target output PRG file.
This is a JSON file currently only used to specify include search paths. It is read when a
Go to definition
is requested within a source file in the same directory. The include search paths
specified within it will be temporarily added to the list of directories that are searched for included files.
Both when processing the current source file and any source file included.
The paths to the directories can be absolute or relative. Relative paths are relative the location of the build file itself.
Example file build.json
:
{
"includePaths": [ "/foo/bar", "baz" ]
}
There is a known limitation for embedded Lua scripts that require the ending curly bracket to be alone on an empty line.
- Icon by Markus Klein (LMan)
- Embedded Squirrel script syntax highlighting based on grammar file from VS Code Extension marcinbar.vscode-squirrel
- Memory reference information from Joe Forster/STA
- OpCode reference information from mass:werk (Original author unknown).
- Illegal Opcode reference information originally from this document by Freddy Offenga. The web page is not available anymore but can be found on Internet Archive / Wayback Machine.
- Added
Go to references
support. - Corrected opcode hover info.
- Fixed loading of embedded script language extensions (in a hacky way).
- Fixed incorrect scope limits where auto-named labels where treated as global when they should be ignored.
- Limit search for local names inside macro to macro body.
- Added symbol file placeholder variable to Build And Run Current command.
- First public release.
- Added completion and hover support for Lua and Squirrel scripts.
- Fixed build (and run) commands so they now appear in command palette as expected.
- Updated parser to support new features (
virtual
anderror
) added to c6510. - Changed the composition of the build command line to now use a configurable string with placeholder variables.
- Updated parser to support new operators added to c6510.
- Added documentation of configuration properties in readme file.
- Fixed broken include path conf following changes when added build (and run) commands.
- Added command to build current source file.
- Added command to build and run current source file.
- Fixed searching for local variable definition, only local labels were handled.
- Fixed searching for local names up the syntax tree. Previously only labels at the same level in the syntax tree were considered.
- Fixed unnecessary processing multiple times of the same file when included from different sources.
- Prevented failure and never reaching a result due to recursive or cross inclusion.
- Added multi-file support for
Go to definition
. Source files included are now also searched. - Added support for build file, currently only for specifying local include directories.
- Added configuration parameters to specify build file name and global include directories.
- Added
Go to definition
support in the same file - Fixed missing syntax highlight of local labels
- Added and adapted Squirrel grammar file from VS Code Extension marcinbar.vscode-squirrel
- Uses embedded language id and scope
c6510-sq
so it wont be used for normal Squirrel files - Added support for c6510 variable references within the script
- Uses embedded language id and scope
- Added missing
vice
keyword
- Added icon by Markus Klein (LMan).
- Added missing Squirrel support (semi-working)
- Initial pre-release