Skip to content

Commit

Permalink
zasm: rename #inc to .inc
Browse files Browse the repository at this point in the history
scas, it's not needed any more.
  • Loading branch information
Virgil Dupras committed Oct 6, 2019
1 parent 340a474 commit f4b6c76
Show file tree
Hide file tree
Showing 28 changed files with 159 additions and 159 deletions.
6 changes: 3 additions & 3 deletions apps/at28w/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@
;
; *** Includes ***

#include "user.h"
#include "err.h"
.inc "user.h"
.inc "err.h"
.org USER_CODE
.equ AT28W_RAMSTART USER_RAMSTART

jp at28wMain

#include "at28w/main.asm"
.inc "at28w/main.asm"
16 changes: 8 additions & 8 deletions apps/ed/glue.asm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "user.h"
.inc "user.h"

; *** Overridable consts ***
; Maximum number of lines allowed in the buffer.
Expand All @@ -8,18 +8,18 @@

; ******

#include "err.h"
.inc "err.h"
.org USER_CODE

jp edMain

#include "lib/util.asm"
#include "lib/parse.asm"
.inc "lib/util.asm"
.inc "lib/parse.asm"
.equ IO_RAMSTART USER_RAMSTART
#include "ed/io.asm"
.inc "ed/io.asm"
.equ BUF_RAMSTART IO_RAMEND
#include "ed/buf.asm"
.inc "ed/buf.asm"
.equ CMD_RAMSTART BUF_RAMEND
#include "ed/cmd.asm"
.inc "ed/cmd.asm"
.equ ED_RAMSTART CMD_RAMEND
#include "ed/main.asm"
.inc "ed/main.asm"
4 changes: 2 additions & 2 deletions apps/memt/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
;
; *** Includes ***

#include "user.h"
.inc "user.h"
.org USER_CODE

jp memtMain

#include "memt/main.asm"
.inc "memt/main.asm"
4 changes: 2 additions & 2 deletions apps/sdct/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@
;
; *** Includes ***

#include "user.h"
.inc "user.h"
.org USER_CODE
.equ SDCT_RAMSTART USER_RAMSTART

jp sdctMain

#include "sdct/main.asm"
.inc "sdct/main.asm"
6 changes: 3 additions & 3 deletions apps/zasm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ is very useful for variable definitions and for jump tables.

## Includes

The `#inc` directive is special. It takes a string literal as an argument and
The `.inc` directive is special. It takes a string literal as an argument and
opens, in the currently active filesystem, the file with the specified name.

It then proceeds to parse that file as if its content had been copy/pasted in
Expand All @@ -108,7 +108,7 @@ elsewhere. Constants too. An exception is local labels: a local namespace always
ends at the end of an included file.

There an important limitation with includes: only one level of includes is
allowed. An included file cannot have an `#inc` directive.
allowed. An included file cannot have an `.inc` directive.

## Directives

Expand Down Expand Up @@ -143,7 +143,7 @@ allowed. An included file cannot have an `#inc` directive.
RAM constants, etc. The value is only outputted during the second
pass.

**#inc**: Takes a string literal as an argument. Open the file name specified
**.inc**: Takes a string literal as an argument. Open the file name specified
in the argument in the currently active filesystem, parse that file
and output its binary content as is the code has been in the includer
file.
Expand Down
2 changes: 1 addition & 1 deletion apps/zasm/directive.asm
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ directiveNames:
.db ".ORG"
.db ".FIL"
.db ".OUT"
.db "#inc"
.db ".INC"
.db ".BIN"

; This is a list of handlers corresponding to indexes in directiveNames
Expand Down
28 changes: 14 additions & 14 deletions apps/zasm/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
; FS_HANDLE_SIZE
; BLOCKDEV_SIZE

#include "user.h"
.inc "user.h"

; *** Overridable consts ***
; Maximum number of symbols we can have in the global and consts registry
Expand All @@ -63,26 +63,26 @@

; ******

#include "err.h"
.inc "err.h"
.org USER_CODE

jp zasmMain

#include "zasm/const.asm"
#include "lib/util.asm"
#include "zasm/util.asm"
.inc "zasm/const.asm"
.inc "lib/util.asm"
.inc "zasm/util.asm"
.equ IO_RAMSTART USER_RAMSTART
#include "zasm/io.asm"
.inc "zasm/io.asm"
.equ TOK_RAMSTART IO_RAMEND
#include "zasm/tok.asm"
#include "lib/parse.asm"
.inc "zasm/tok.asm"
.inc "lib/parse.asm"
.equ INS_RAMSTART TOK_RAMEND
#include "zasm/instr.asm"
.inc "zasm/instr.asm"
.equ DIREC_RAMSTART INS_RAMEND
#include "zasm/directive.asm"
#include "zasm/parse.asm"
#include "zasm/expr.asm"
.inc "zasm/directive.asm"
.inc "zasm/parse.asm"
.inc "zasm/expr.asm"
.equ SYM_RAMSTART DIREC_RAMEND
#include "zasm/symbol.asm"
.inc "zasm/symbol.asm"
.equ ZASM_RAMSTART SYM_RAMEND
#include "zasm/main.asm"
.inc "zasm/main.asm"
2 changes: 1 addition & 1 deletion kernel/shell.asm
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ shellPrintErr:
; Extra commands: Other parts might define new commands. You can add these
; commands to your shell. First, set SHELL_EXTRA_CMD_COUNT to
; the number of extra commands to add, then add a ".dw"
; directive *just* after your '#include "shell.asm"'. Voila!
; directive *just* after your '.inc "shell.asm"'. Voila!
;

; Set memory pointer to the specified address (word).
Expand Down
20 changes: 10 additions & 10 deletions recipes/rc2014/eeprom/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -11,35 +11,35 @@ jp init
.fill 0x38-$
jp aciaInt

#include "err.h"
#include "core.asm"
#include "parse.asm"
.inc "err.h"
.inc "core.asm"
.inc "parse.asm"
.equ ACIA_RAMSTART RAMSTART
#include "acia.asm"
.inc "acia.asm"

.equ MMAP_START 0xd000
#include "mmap.asm"
.inc "mmap.asm"

.equ BLOCKDEV_RAMSTART ACIA_RAMEND
.equ BLOCKDEV_COUNT 1
#include "blockdev.asm"
.inc "blockdev.asm"
; List of devices
.dw mmapGetC, mmapPutC

.equ STDIO_RAMSTART BLOCKDEV_RAMEND
#include "stdio.asm"
.inc "stdio.asm"

.equ AT28W_RAMSTART STDIO_RAMEND
#include "at28w/main.asm"
.inc "at28w/main.asm"

.equ SHELL_RAMSTART AT28W_RAMEND
.equ SHELL_EXTRA_CMD_COUNT 5
#include "shell.asm"
.inc "shell.asm"
; Extra cmds
.dw a28wCmd
.dw blkBselCmd, blkSeekCmd, blkLoadCmd, blkSaveCmd

#include "blockdev_cmds.asm"
.inc "blockdev_cmds.asm"

init:
di
Expand Down
12 changes: 6 additions & 6 deletions recipes/rc2014/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ jp init
.fill 0x38-$
jp aciaInt

#include "err.h"
#include "core.asm"
#include "parse.asm"
.inc "err.h"
.inc "core.asm"
.inc "parse.asm"
.equ ACIA_RAMSTART RAMSTART
#include "acia.asm"
.inc "acia.asm"

.equ STDIO_RAMSTART ACIA_RAMEND
#include "stdio.asm"
.inc "stdio.asm"

.equ SHELL_RAMSTART STDIO_RAMEND
.equ SHELL_EXTRA_CMD_COUNT 0
#include "shell.asm"
.inc "shell.asm"

init:
di
Expand Down
14 changes: 7 additions & 7 deletions recipes/rc2014/ps2/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,21 @@

jp init

#include "err.h"
#include "core.asm"
#include "parse.asm"
.inc "err.h"
.inc "core.asm"
.inc "parse.asm"
.equ ACIA_RAMSTART RAMSTART
#include "acia.asm"
.inc "acia.asm"

.equ KBD_RAMSTART ACIA_RAMEND
#include "kbd.asm"
.inc "kbd.asm"

.equ STDIO_RAMSTART KBD_RAMEND
#include "stdio.asm"
.inc "stdio.asm"

.equ SHELL_RAMSTART STDIO_RAMEND
.equ SHELL_EXTRA_CMD_COUNT 0
#include "shell.asm"
.inc "shell.asm"

init:
di
Expand Down
24 changes: 12 additions & 12 deletions recipes/rc2014/sdcard/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -20,44 +20,44 @@ jp sdcSendRecv
.fill 0x38-$
jp aciaInt

#include "err.h"
#include "core.asm"
#include "parse.asm"
.inc "err.h"
.inc "core.asm"
.inc "parse.asm"
.equ ACIA_RAMSTART RAMSTART
#include "acia.asm"
.inc "acia.asm"
.equ BLOCKDEV_RAMSTART ACIA_RAMEND
.equ BLOCKDEV_COUNT 2
#include "blockdev.asm"
.inc "blockdev.asm"
; List of devices
.dw sdcGetC, sdcPutC
.dw blk2GetC, blk2PutC


.equ STDIO_RAMSTART BLOCKDEV_RAMEND
#include "stdio.asm"
.inc "stdio.asm"

.equ FS_RAMSTART STDIO_RAMEND
.equ FS_HANDLE_COUNT 1
#include "fs.asm"
.inc "fs.asm"

.equ SHELL_RAMSTART FS_RAMEND
.equ SHELL_EXTRA_CMD_COUNT 11
#include "shell.asm"
.inc "shell.asm"
.dw sdcInitializeCmd, sdcFlushCmd
.dw blkBselCmd, blkSeekCmd, blkLoadCmd, blkSaveCmd
.dw fsOnCmd, flsCmd, fnewCmd, fdelCmd, fopnCmd

#include "blockdev_cmds.asm"
#include "fs_cmds.asm"
.inc "blockdev_cmds.asm"
.inc "fs_cmds.asm"

.equ PGM_RAMSTART SHELL_RAMEND
#include "pgm.asm"
.inc "pgm.asm"

.equ SDC_RAMSTART PGM_RAMEND
.equ SDC_PORT_CSHIGH 6
.equ SDC_PORT_CSLOW 5
.equ SDC_PORT_SPI 4
#include "sdc.asm"
.inc "sdc.asm"

init:
di
Expand Down
2 changes: 1 addition & 1 deletion recipes/rc2014/zasm/cfsin/hello.asm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "user.h"
.inc "user.h"
.org USER_CODE

ld hl, sAwesome
Expand Down
26 changes: 13 additions & 13 deletions recipes/rc2014/zasm/glue.asm
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,14 @@ jp aciaInt
jp sdcPutC
jp blkGetC

#include "err.h"
#include "core.asm"
#include "parse.asm"
.inc "err.h"
.inc "core.asm"
.inc "parse.asm"
.equ ACIA_RAMSTART RAMSTART
#include "acia.asm"
.inc "acia.asm"
.equ BLOCKDEV_RAMSTART ACIA_RAMEND
.equ BLOCKDEV_COUNT 4
#include "blockdev.asm"
.inc "blockdev.asm"
; List of devices
.dw sdcGetC, sdcPutC
.dw blk1GetC, blk1PutC
Expand All @@ -62,33 +62,33 @@ jp aciaInt


.equ MMAP_START 0xe000
#include "mmap.asm"
.inc "mmap.asm"

.equ STDIO_RAMSTART BLOCKDEV_RAMEND
#include "stdio.asm"
.inc "stdio.asm"

.equ FS_RAMSTART STDIO_RAMEND
.equ FS_HANDLE_COUNT 2
#include "fs.asm"
.inc "fs.asm"

.equ SHELL_RAMSTART FS_RAMEND
.equ SHELL_EXTRA_CMD_COUNT 11
#include "shell.asm"
.inc "shell.asm"
.dw sdcInitializeCmd, sdcFlushCmd
.dw blkBselCmd, blkSeekCmd, blkLoadCmd, blkSaveCmd
.dw fsOnCmd, flsCmd, fnewCmd, fdelCmd, fopnCmd

#include "fs_cmds.asm"
#include "blockdev_cmds.asm"
.inc "fs_cmds.asm"
.inc "blockdev_cmds.asm"

.equ PGM_RAMSTART SHELL_RAMEND
#include "pgm.asm"
.inc "pgm.asm"

.equ SDC_RAMSTART PGM_RAMEND
.equ SDC_PORT_CSHIGH 6
.equ SDC_PORT_CSLOW 5
.equ SDC_PORT_SPI 4
#include "sdc.asm"
.inc "sdc.asm"

.out SDC_RAMEND

Expand Down
Loading

0 comments on commit f4b6c76

Please sign in to comment.