0

所以我正在尝试组装它,但是当我尝试时,它给了我错误:在操作数 1 之后需要逗号

这是代码。

option_screen:
mov ax, os_init_msg     ; Set up the welcome screen
mov bx, os_version_msg
mov cx, 10011111b       ; Colour: white text on light blue
call os_draw_background

mov ax, dialog_string_1     ; Ask if user wants app selector or command-line
mov bx, dialog_string_2
mov dx, 1           ; We want a two-option dialog box (OK or Cancel)
call os_dialog_box

cmp ax, 1           ; If OK (option 0) chosen, start app selector
jne near app_selector

call os_clear_screen        ; Otherwise clean screen and start the CLI
call os_command_line

jmp option_screen       ; Offer menu/CLI choice after CLI has exited


; Data for the above code...

os_init_msg     db 'Welcome to 0x539's OS!', 0
os_version_msg      db 'Version ', OS_VER, 10

dialog_string_1     db 'Thanks for trying out MikeOS!', 0
dialog_string_2     db 'This project is currently in Alpha version.', 0

错误发生os_init_msg在线路上。请帮忙!

4

1 回答 1

1

您的字符串中有一个单引号,这使汇编程序认为您已经输入了 string 'Welcome to 0x539',然后是 characters s OS!', 0

改为使用双引号作为分隔符:"Welcome to 0x539's OS!", 0.

于 2013-10-21T15:13:52.113 回答