Answer from cs61c-ay (Peter Lau 16743989) for Question 4
The i/o terminal can be controlled by writing to special memory locations. 

     li $t1, 0x00000001

loop:
     lw $t0, 0(0xffff0000)
     beq $t1, $t0, received
     j loop
received:
     lw $v0, 0xffff0004 
