This commit is contained in:
parent
14cfa3e109
commit
354c72a637
|
@ -15,8 +15,6 @@
|
|||
# dd if=boot.bin of=code.img conv=notrunc
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Since we start out in 16-bit mode, we need instructions SubX doesn't
|
||||
# support.
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex1.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: blank screen with no errors
|
||||
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex10.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output:
|
||||
# Values between -256 and +255 as you move the mouse over the window.
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex11.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: a spline with 3 control points. Use `Tab` to switch cursor
|
||||
# between control points, and arrow keys to move the control point at the
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex12.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: text with slowly updating colors
|
||||
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex2.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
|
||||
fn main screen: (addr screen), keyboard: (addr keyboard), data-disk: (addr disk) {
|
||||
var y/eax: int <- copy 0
|
||||
|
|
|
@ -5,8 +5,6 @@
|
|||
# ./translate apps/ex3.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: a new green pixel starting from the top left corner of the
|
||||
# screen every time you press a key (letter or digit)
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex4.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: letter 'A' in green near the top-left corner of screen
|
||||
|
||||
|
|
|
@ -5,8 +5,6 @@
|
|||
# ./translate apps/ex5.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: text in green near the top-left corner of screen
|
||||
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex6.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: a box and text that doesn't overflow it
|
||||
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
# ./translate apps/ex7.mu # emits code.img
|
||||
# To run:
|
||||
# qemu-system-i386 code.img
|
||||
# Or:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
#
|
||||
# Expected output: an interactive game a bit like "snakes". Try pressing h, j,
|
||||
# k, l.
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# To build a disk image:
|
||||
# ./translate apps/ex8.mu # emits code.img
|
||||
# To run:
|
||||
# bochs -f bochsrc # bochsrc loads code.img
|
||||
# Set a breakpoint at 0x7c00 and start stepping.
|
||||
# qemu-system-i386 code.img
|
||||
# You shouldn't see any exceptions.
|
||||
|
||||
fn main screen: (addr screen), keyboard: (addr keyboard), data-disk: (addr disk) {
|
||||
var n/eax: int <- copy 0
|
||||
|
|
|
@ -8,9 +8,8 @@
|
|||
# echo 'abc def ghi' |dd of=data.img conv=notrunc
|
||||
# 3. Familiarize yourself with how the data disk looks within xxd:
|
||||
# xxd data.img |head
|
||||
# 4. Run in an emulator, either Qemu or Bochs.
|
||||
# 4. Run:
|
||||
# qemu-system-i386 -hda code.img -hdb data.img
|
||||
# bochs -f bochsrc.2disks
|
||||
# 5. Exit the emulator.
|
||||
# 6. Notice that the data disk now contains the word count of the original text.
|
||||
# xxd data.img |head
|
||||
|
|
Loading…
Reference in New Issue