Added tinybasic
This commit is contained in:
@@ -9,7 +9,7 @@ METAL_RELFILES := $(METAL_ASM_SRCFILES:%.asm=$(BUILDDIR)/metal/%.rel) \
|
|||||||
METAL_CC := sdcc
|
METAL_CC := sdcc
|
||||||
METAL_AS := sdasz80
|
METAL_AS := sdasz80
|
||||||
METAL_MAKEBIN := makebin
|
METAL_MAKEBIN := makebin
|
||||||
METAL_FLAGS := -mz80 --no-std-crt0 --code-loc 0xC080 --code-size 0x2F80 --data-loc 0xF000
|
METAL_FLAGS := -mz80 --no-std-crt0 --code-loc 0xC080 --code-size 0x0F80 --data-loc 0xF000
|
||||||
METAL_CPPFLAGS := -I src -I $(BUILDDIR)/metal/generated --disable-warning 283
|
METAL_CPPFLAGS := -I src -I $(BUILDDIR)/metal/generated --disable-warning 283
|
||||||
METAL_BIN_SIZE := 32768
|
METAL_BIN_SIZE := 32768
|
||||||
METAL_RAM_SIZE := 16384
|
METAL_RAM_SIZE := 16384
|
||||||
@@ -17,6 +17,11 @@ METAL_IMAGE_SIZE := 65536
|
|||||||
MONITOR_BASE := 0xC000
|
MONITOR_BASE := 0xC000
|
||||||
MONITOR_ROM_OFFSET := 128
|
MONITOR_ROM_OFFSET := 128
|
||||||
|
|
||||||
|
TINYBASIC_BASE := 0xD000
|
||||||
|
TINYBASIC_ROM_OFFSET := 4096
|
||||||
|
TINYBASIC_SRC := tinybasic_sdas.asm
|
||||||
|
TINYBASIC_BUILD := $(BUILDDIR)/tinybasic
|
||||||
|
|
||||||
.DEFAULT_GOAL := metal
|
.DEFAULT_GOAL := metal
|
||||||
|
|
||||||
.PHONY: all metal clean
|
.PHONY: all metal clean
|
||||||
@@ -31,9 +36,9 @@ metal: $(BUILDDIR)/metal/$(TARGET).ihx $(BUILDDIR)/metal/$(TARGET).bin $(BUILDDI
|
|||||||
END { \
|
END { \
|
||||||
printf "\nMemory usage:\n"; \
|
printf "\nMemory usage:\n"; \
|
||||||
printf " ROM storage: %5u / %5u bytes (%5.1f%%)\n", stored, rom_capacity, 100 * stored / rom_capacity; \
|
printf " ROM storage: %5u / %5u bytes (%5.1f%%)\n", stored, rom_capacity, 100 * stored / rom_capacity; \
|
||||||
printf " Runtime RAM: %5u / %5u bytes (%5.1f%%), %5u bytes for growth/stack\n", code + data, ram_capacity, 100 * (code + data) / ram_capacity, ram_capacity - code - data; \
|
printf " Monitor linked: %5u bytes (%5u code/vector + %5u static data)\n", code + data, code, data; \
|
||||||
printf " code/vector: %5u bytes; static data: %5u bytes\n", code, data; \
|
|
||||||
}' $(BUILDDIR)/metal/$(TARGET).map
|
}' $(BUILDDIR)/metal/$(TARGET).map
|
||||||
|
@printf " Tiny BASIC: %5u bytes at D000\n" $$(wc -c < $(TINYBASIC_BUILD)/tinybasic.bin)
|
||||||
|
|
||||||
$(BUILDDIR)/metal/$(TARGET).ihx: $(METAL_RELFILES)
|
$(BUILDDIR)/metal/$(TARGET).ihx: $(METAL_RELFILES)
|
||||||
@mkdir -p $(@D)
|
@mkdir -p $(@D)
|
||||||
@@ -42,12 +47,13 @@ $(BUILDDIR)/metal/$(TARGET).ihx: $(METAL_RELFILES)
|
|||||||
$(BUILDDIR)/metal/$(TARGET).flat.bin: $(BUILDDIR)/metal/$(TARGET).ihx
|
$(BUILDDIR)/metal/$(TARGET).flat.bin: $(BUILDDIR)/metal/$(TARGET).ihx
|
||||||
$(METAL_MAKEBIN) -s $(METAL_IMAGE_SIZE) $< $@
|
$(METAL_MAKEBIN) -s $(METAL_IMAGE_SIZE) $< $@
|
||||||
|
|
||||||
$(BUILDDIR)/metal/$(TARGET).prog.bin: $(BUILDDIR)/metal/$(TARGET).flat.bin
|
$(BUILDDIR)/metal/$(TARGET).prog.bin: $(BUILDDIR)/metal/$(TARGET).flat.bin $(TINYBASIC_BUILD)/tinybasic.bin
|
||||||
@payload_end=$$(awk '$$1 == "DEF" && $$2 == "monitor_image_end" { print $$3 }' $(BUILDDIR)/metal/$(TARGET).noi); \
|
@payload_end=$$(awk '$$1 == "DEF" && $$2 == "monitor_image_end" { print $$3 }' $(BUILDDIR)/metal/$(TARGET).noi); \
|
||||||
payload_size=$$((payload_end - $(MONITOR_BASE))); \
|
payload_size=$$((payload_end - $(MONITOR_BASE))); \
|
||||||
test $$payload_size -gt 0; \
|
test $$payload_size -gt 0; \
|
||||||
dd if=$< of=$@ bs=1 count=$(MONITOR_ROM_OFFSET) status=none; \
|
dd if=$< of=$@ bs=1 count=$(TINYBASIC_ROM_OFFSET) status=none; \
|
||||||
dd if=$< of=$@ bs=1 skip=$$(( $(MONITOR_BASE) )) seek=$(MONITOR_ROM_OFFSET) count=$$payload_size conv=notrunc status=none
|
dd if=$< of=$@ bs=1 skip=$$(( $(MONITOR_BASE) )) seek=$(MONITOR_ROM_OFFSET) count=$$payload_size conv=notrunc status=none; \
|
||||||
|
dd if=$(TINYBASIC_BUILD)/tinybasic.bin of=$@ bs=1 seek=$(TINYBASIC_ROM_OFFSET) conv=notrunc status=none
|
||||||
|
|
||||||
$(BUILDDIR)/metal/$(TARGET).bin: $(BUILDDIR)/metal/$(TARGET).flat.bin $(BUILDDIR)/metal/$(TARGET).prog.bin
|
$(BUILDDIR)/metal/$(TARGET).bin: $(BUILDDIR)/metal/$(TARGET).flat.bin $(BUILDDIR)/metal/$(TARGET).prog.bin
|
||||||
dd if=$< of=$@ bs=$(METAL_BIN_SIZE) count=1 status=none
|
dd if=$< of=$@ bs=$(METAL_BIN_SIZE) count=1 status=none
|
||||||
@@ -58,9 +64,30 @@ $(BUILDDIR)/metal/%.rel: %.c
|
|||||||
$(METAL_CC) $(METAL_FLAGS) $(METAL_CPPFLAGS) -o $@ -c $<
|
$(METAL_CC) $(METAL_FLAGS) $(METAL_CPPFLAGS) -o $@ -c $<
|
||||||
|
|
||||||
$(BUILDDIR)/metal/%.rel: %.asm
|
$(BUILDDIR)/metal/%.rel: %.asm
|
||||||
|
@mkdir -p $(@D)
|
||||||
|
$(METAL_AS) -I$(BUILDDIR)/metal/generated -plosgff -o $@ $<
|
||||||
|
|
||||||
|
$(BUILDDIR)/metal/boot.rel: $(BUILDDIR)/metal/generated/tinybasic.inc
|
||||||
|
|
||||||
|
$(TINYBASIC_BUILD)/tinybasic.rel: $(TINYBASIC_SRC)
|
||||||
@mkdir -p $(@D)
|
@mkdir -p $(@D)
|
||||||
$(METAL_AS) -plosgff -o $@ $<
|
$(METAL_AS) -plosgff -o $@ $<
|
||||||
|
|
||||||
|
$(TINYBASIC_BUILD)/tinybasic.ihx: $(TINYBASIC_BUILD)/tinybasic.rel
|
||||||
|
sdldz80 -n -i -m -j $(basename $@) $<
|
||||||
|
|
||||||
|
$(TINYBASIC_BUILD)/tinybasic.flat.bin: $(TINYBASIC_BUILD)/tinybasic.ihx
|
||||||
|
$(METAL_MAKEBIN) -s $(METAL_IMAGE_SIZE) $< $@
|
||||||
|
|
||||||
|
$(TINYBASIC_BUILD)/tinybasic.bin: $(TINYBASIC_BUILD)/tinybasic.flat.bin
|
||||||
|
@tiny_size=$$(awk '$$1 == "TINYBASIC0" { print $$5 + 0 }' $(TINYBASIC_BUILD)/tinybasic.map); \
|
||||||
|
test $$tiny_size -gt 0; \
|
||||||
|
dd if=$< of=$@ bs=1 skip=$$(( $(TINYBASIC_BASE) )) count=$$tiny_size status=none
|
||||||
|
|
||||||
|
$(BUILDDIR)/metal/generated/tinybasic.inc: $(TINYBASIC_BUILD)/tinybasic.ihx
|
||||||
|
@mkdir -p $(@D)
|
||||||
|
@awk '$$1 == "TINYBASIC0" { printf "TINYBASIC_SIZE = 0x%04X\n", $$5 }' $(TINYBASIC_BUILD)/tinybasic.map > $@
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -rf $(BUILDDIR)
|
rm -rf $(BUILDDIR)
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
# Z80 UART monitor
|
# Z80 UART monitor
|
||||||
|
|
||||||
This ROM provides a small interactive monitor on the UART/CTC card at I/O base
|
This ROM provides a small interactive monitor and a bundled Z80 Tiny BASIC
|
||||||
`20`. At reset, a small ROM bootstrap copies the monitor into the top 16 KiB of
|
interpreter on the UART/CTC card at I/O base `20`. At reset, a small ROM
|
||||||
RAM at `C000-FFFF` and starts it there. Only the occupied vector/code bytes are
|
bootstrap copies both programs into the top 16 KiB of RAM and starts the
|
||||||
stored and copied; uninitialized data is cleared directly in high RAM. The low ROM can subsequently be disabled
|
monitor. Only occupied code/vector bytes are stored and copied; uninitialized
|
||||||
without taking the monitor, its data, or its interrupt table away. Runtime code
|
data is cleared directly in high RAM. The low ROM can subsequently be disabled
|
||||||
and vectors occupy the lower part of this window, globals begin at `F000`, and
|
without taking away the monitor, Tiny BASIC, monitor data, or interrupt table.
|
||||||
the stack grows downward from `FFFF`; no RAM below `C000` is used.
|
No runtime RAM below `C000` is used.
|
||||||
|
|
||||||
Connect a terminal at **2400 baud, 8 data bits, no parity, 1 stop bit**.
|
Connect a terminal at **2400 baud, 8 data bits, no parity, 1 stop bit**.
|
||||||
Commands are case-insensitive and all numeric arguments are hexadecimal; an
|
Commands are case-insensitive and all numeric arguments are hexadecimal; an
|
||||||
@@ -20,6 +20,8 @@ optional `0x` prefix is accepted.
|
|||||||
| `I 20` | Read I/O port 20 |
|
| `I 20` | Read I/O port 20 |
|
||||||
| `O 20 57` | Write 57 to I/O port 20 |
|
| `O 20 57` | Write 57 to I/O port 20 |
|
||||||
| `G 8000` | Execute code at address 8000 |
|
| `G 8000` | Execute code at address 8000 |
|
||||||
|
| `G D000` | Start the bundled Z80 Tiny BASIC interpreter |
|
||||||
|
| `B` or `BASIC` | Shortcut for `G D000` |
|
||||||
| `HELP` | Show the command summary |
|
| `HELP` | Show the command summary |
|
||||||
|
|
||||||
`G` transfers control with a return address on the stack, so code ending in
|
`G` transfers control with a return address on the stack, so code ending in
|
||||||
@@ -32,13 +34,65 @@ Build the ROM and programmer-format images with:
|
|||||||
make
|
make
|
||||||
```
|
```
|
||||||
|
|
||||||
The outputs are `build/metal/monitor.bin` (32 KiB ROM image) and
|
The outputs are:
|
||||||
`build/metal/monitor.prog.bin` (compact programmer image). The ROM layout is:
|
|
||||||
|
- `build/metal/monitor.bin`: complete 32 KiB ROM image
|
||||||
|
- `build/metal/monitor.prog.bin`: compact image ending at the last occupied byte
|
||||||
|
- `build/tinybasic/tinybasic.bin`: standalone relocated Tiny BASIC payload
|
||||||
|
|
||||||
|
The current compact image is 6,157 bytes. Its ROM layout is:
|
||||||
|
|
||||||
- `0000-007F`: reset/copy bootstrap
|
- `0000-007F`: reset/copy bootstrap
|
||||||
- `0080...`: compact vector/code image copied to RAM starting at `C000`
|
- `0080-0F6E`: monitor image copied to RAM at `C000-CEEE`
|
||||||
- Remaining bytes: unused and available for additional ROM content
|
- `0F6F-0FFF`: unused space reserved for monitor growth
|
||||||
|
- `1000-180C`: Tiny BASIC image copied to RAM at `D000-D80C`
|
||||||
|
- `180D-7FFF`: unused space available for additional ROM content
|
||||||
|
|
||||||
The monitor executable starts at `C080`; its IM 2 vector table is at `C040`.
|
The monitor executable starts at `C080`; its IM 2 vector table is at `C040`.
|
||||||
`monitor.prog.bin` ends immediately after the occupied payload, while
|
The bootstrap obtains both copy lengths from generated/linker symbols, so the
|
||||||
`monitor.bin` remains a complete 32 KiB chip image.
|
copied sizes track changes to the programs automatically.
|
||||||
|
|
||||||
|
The resulting high-RAM layout is:
|
||||||
|
|
||||||
|
- `C000-CEEE`: monitor vectors, services, and code
|
||||||
|
- `CEEF-CFFF`: free
|
||||||
|
- `D000-D80C`: Tiny BASIC code
|
||||||
|
- `D80D-DFFF`: free
|
||||||
|
- `E000-E7FF`: Tiny BASIC workspace and BASIC program text
|
||||||
|
- `E800-E877`: Tiny BASIC variables and input buffer
|
||||||
|
- `E878-EFFF`: Tiny BASIC stack space
|
||||||
|
- `F000-FFFF`: monitor globals and monitor stack
|
||||||
|
|
||||||
|
## Tiny BASIC
|
||||||
|
|
||||||
|
The original GNU-z80asm listing is retained as `tinybasic/tinybasic.asm`. Its
|
||||||
|
`sdasz80` port is `tinybasic/tinybasic_sdas.asm` and is built automatically.
|
||||||
|
The port replaces fixed low-page `RST` calls with relocatable calls and uses a
|
||||||
|
marker-based command table so addresses in the `D000` page work correctly.
|
||||||
|
|
||||||
|
At reset the bootstrap copies Tiny BASIC from ROM offset `1000` to `D000`.
|
||||||
|
Start it from the monitor with:
|
||||||
|
|
||||||
|
```text
|
||||||
|
B
|
||||||
|
```
|
||||||
|
|
||||||
|
`BASIC` and `G D000` are equivalent alternatives.
|
||||||
|
|
||||||
|
Tiny BASIC calls the monitor ABI at `C050` for output and `C053` for
|
||||||
|
non-blocking input. The assembly ABI wrappers preserve the working registers,
|
||||||
|
and Tiny BASIC keeps interrupts enabled so it can share the monitor's configured
|
||||||
|
interrupt-driven UART.
|
||||||
|
|
||||||
|
Line editing accepts either `BS` (`08`) or `DEL` (`7F`) for backspace and emits
|
||||||
|
`BS SPACE BS` so ANSI-style terminals erase the character visually. Ctrl-U
|
||||||
|
clears the complete input line.
|
||||||
|
|
||||||
|
During execution, Ctrl-O toggles output suppression without stopping the BASIC
|
||||||
|
program. Press Ctrl-O again to resume output. Ctrl-C stops execution and
|
||||||
|
returns to the Tiny BASIC prompt.
|
||||||
|
|
||||||
|
Tiny BASIC resets the stack pointer when it starts, so it does not currently
|
||||||
|
return through the monitor's `G` call. Reset the machine to return to the
|
||||||
|
monitor. The first currently unused ROM byte is `180D`; `1900` is a convenient
|
||||||
|
aligned starting point for another ROM payload.
|
||||||
|
|||||||
@@ -2,6 +2,10 @@ STACK_TOP = 0xFFFF
|
|||||||
DELAY_LOOPS_PER_MS = 40
|
DELAY_LOOPS_PER_MS = 40
|
||||||
MONITOR_BASE = 0xC000
|
MONITOR_BASE = 0xC000
|
||||||
MONITOR_ROM_SOURCE = 0x0080
|
MONITOR_ROM_SOURCE = 0x0080
|
||||||
|
TINYBASIC_BASE = 0xD000
|
||||||
|
TINYBASIC_ROM_SOURCE = 0x1000
|
||||||
|
|
||||||
|
.include "tinybasic.inc"
|
||||||
|
|
||||||
.globl _main
|
.globl _main
|
||||||
.globl _delay_ms
|
.globl _delay_ms
|
||||||
@@ -10,6 +14,8 @@ MONITOR_ROM_SOURCE = 0x0080
|
|||||||
.globl _enable_interrupts
|
.globl _enable_interrupts
|
||||||
.globl _disable_interrupts
|
.globl _disable_interrupts
|
||||||
.globl _jump_to
|
.globl _jump_to
|
||||||
|
.globl _monitor_uart_putc
|
||||||
|
.globl _monitor_uart_getc
|
||||||
.globl monitor_image_end
|
.globl monitor_image_end
|
||||||
.globl s__DATA
|
.globl s__DATA
|
||||||
.globl l__DATA
|
.globl l__DATA
|
||||||
@@ -29,6 +35,11 @@ boot_copy:
|
|||||||
ld de, #MONITOR_BASE
|
ld de, #MONITOR_BASE
|
||||||
ld bc, #(monitor_image_end - MONITOR_BASE)
|
ld bc, #(monitor_image_end - MONITOR_BASE)
|
||||||
ldir
|
ldir
|
||||||
|
|
||||||
|
ld hl, #TINYBASIC_ROM_SOURCE
|
||||||
|
ld de, #TINYBASIC_BASE
|
||||||
|
ld bc, #TINYBASIC_SIZE
|
||||||
|
ldir
|
||||||
jp init
|
jp init
|
||||||
|
|
||||||
.area _ITABLE (ABS)
|
.area _ITABLE (ABS)
|
||||||
@@ -58,6 +69,13 @@ boot_copy:
|
|||||||
.dw ctc_isr ; CTC channel 2: vector 0x44
|
.dw ctc_isr ; CTC channel 2: vector 0x44
|
||||||
.dw uart_isr ; CTC channel 3: vector 0x46
|
.dw uart_isr ; CTC channel 3: vector 0x46
|
||||||
|
|
||||||
|
; Stable entry points for programs living alongside the monitor.
|
||||||
|
; C050: write the character in A. C053: return a character in A, or 0.
|
||||||
|
.org MONITOR_BASE + 0x50
|
||||||
|
jp monitor_service_putc
|
||||||
|
.org MONITOR_BASE + 0x53
|
||||||
|
jp monitor_service_getc
|
||||||
|
|
||||||
.area _HOME
|
.area _HOME
|
||||||
init:
|
init:
|
||||||
di
|
di
|
||||||
@@ -110,6 +128,38 @@ monitor_image_end:
|
|||||||
|
|
||||||
.area _CODE
|
.area _CODE
|
||||||
|
|
||||||
|
; Monitor ABI services preserve all working registers. PUTC also preserves AF;
|
||||||
|
; GETC returns the received byte (or zero) in A.
|
||||||
|
monitor_service_putc:
|
||||||
|
push af
|
||||||
|
push bc
|
||||||
|
push de
|
||||||
|
push hl
|
||||||
|
push ix
|
||||||
|
push iy
|
||||||
|
call _monitor_uart_putc
|
||||||
|
pop iy
|
||||||
|
pop ix
|
||||||
|
pop hl
|
||||||
|
pop de
|
||||||
|
pop bc
|
||||||
|
pop af
|
||||||
|
ret
|
||||||
|
|
||||||
|
monitor_service_getc:
|
||||||
|
push bc
|
||||||
|
push de
|
||||||
|
push hl
|
||||||
|
push ix
|
||||||
|
push iy
|
||||||
|
call _monitor_uart_getc
|
||||||
|
pop iy
|
||||||
|
pop ix
|
||||||
|
pop hl
|
||||||
|
pop de
|
||||||
|
pop bc
|
||||||
|
ret
|
||||||
|
|
||||||
.macro MAKE_ISR entry, handler
|
.macro MAKE_ISR entry, handler
|
||||||
.globl handler
|
.globl handler
|
||||||
entry:
|
entry:
|
||||||
|
|||||||
@@ -45,6 +45,23 @@ static void uart_putc(char c)
|
|||||||
uart_kick();
|
uart_kick();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Stable monitor ABI implementations, reached through the jump table at C050. */
|
||||||
|
void monitor_uart_putc(char c)
|
||||||
|
{
|
||||||
|
uart_putc(c);
|
||||||
|
}
|
||||||
|
|
||||||
|
uint8_t monitor_uart_getc(void)
|
||||||
|
{
|
||||||
|
char c;
|
||||||
|
uint8_t received;
|
||||||
|
|
||||||
|
disable_interrupts();
|
||||||
|
received = buffer_dequeue(&rx_buf, &c);
|
||||||
|
enable_interrupts();
|
||||||
|
return received ? (uint8_t)c : 0;
|
||||||
|
}
|
||||||
|
|
||||||
static void uart_puts(const char *s)
|
static void uart_puts(const char *s)
|
||||||
{
|
{
|
||||||
while (*s) uart_putc(*s++);
|
while (*s) uart_putc(*s++);
|
||||||
@@ -182,6 +199,7 @@ static void print_help(void)
|
|||||||
" I|IN port Read an I/O port\r\n"
|
" I|IN port Read an I/O port\r\n"
|
||||||
" O|OUT port byte Write an I/O port\r\n"
|
" O|OUT port byte Write an I/O port\r\n"
|
||||||
" G|GO address Execute code; RET returns here\r\n"
|
" G|GO address Execute code; RET returns here\r\n"
|
||||||
|
" B|BASIC Start Tiny BASIC at D000\r\n"
|
||||||
" H|HELP|? Show this help\r\n");
|
" H|HELP|? Show this help\r\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -265,6 +283,16 @@ static void command_out(uint8_t argc, char **argv)
|
|||||||
uart_puts("OK\r\n");
|
uart_puts("OK\r\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void execute_address(uint16_t address)
|
||||||
|
{
|
||||||
|
uart_puts("Executing at ");
|
||||||
|
print_hex16(address);
|
||||||
|
uart_puts("...\r\n");
|
||||||
|
uart_flush();
|
||||||
|
jump_to(address);
|
||||||
|
uart_puts("Returned to monitor\r\n");
|
||||||
|
}
|
||||||
|
|
||||||
static void command_go(uint8_t argc, char **argv)
|
static void command_go(uint8_t argc, char **argv)
|
||||||
{
|
{
|
||||||
uint16_t address;
|
uint16_t address;
|
||||||
@@ -273,12 +301,16 @@ static void command_go(uint8_t argc, char **argv)
|
|||||||
uart_puts("Usage: G address\r\n");
|
uart_puts("Usage: G address\r\n");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
uart_puts("Executing at ");
|
execute_address(address);
|
||||||
print_hex16(address);
|
}
|
||||||
uart_puts("...\r\n");
|
|
||||||
uart_flush();
|
static void command_basic(uint8_t argc)
|
||||||
jump_to(address);
|
{
|
||||||
uart_puts("Returned to monitor\r\n");
|
if (argc != 1) {
|
||||||
|
uart_puts("Usage: B\r\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
execute_address(0xd000);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void execute_line(char *line)
|
static void execute_line(char *line)
|
||||||
@@ -300,6 +332,8 @@ static void execute_line(char *line)
|
|||||||
command_out(argc, argv);
|
command_out(argc, argv);
|
||||||
} else if (strings_equal(argv[0], "g") || strings_equal(argv[0], "go")) {
|
} else if (strings_equal(argv[0], "g") || strings_equal(argv[0], "go")) {
|
||||||
command_go(argc, argv);
|
command_go(argc, argv);
|
||||||
|
} else if (strings_equal(argv[0], "b") || strings_equal(argv[0], "basic")) {
|
||||||
|
command_basic(argc);
|
||||||
} else {
|
} else {
|
||||||
uart_puts("Unknown command; type HELP\r\n");
|
uart_puts("Unknown command; type HELP\r\n");
|
||||||
}
|
}
|
||||||
|
|||||||
+1836
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user