adumont / hrm-cpu

Human Resource Machine - CPU Design #HRM
https://twitter.com/i/moments/1017515777610649601
GNU General Public License v3.0
71 stars 8 forks source link

Transform INBOX into a FIFO #1

Closed adumont closed 6 years ago

adumont commented 6 years ago

That will allow us to plug a UART-RX to the FIFO.

Also modify the CPU FSM so that when in state DECODE, when Instr=INBOX & empty=1 , next_state <= DECODE (that is: stay in the same state until something arrives in INBOX)

eine commented 6 years ago

You mind find these references useful:

adumont commented 6 years ago

Related discussion in #FPGAwars groups at https://groups.google.com/d/msg/fpga-wars-explorando-el-lado-libre/f8mjYT8JR5k/c-YnNGiPAAAJ .

adumont commented 6 years ago

"Also modify the CPU FSM so that when in state DECODE, when Instr=INBOX & empty=1 , next_state <= DECODE (that is: stay in the same state until something arrives in INBOX)"

--> That part was done in cf450b8fa02cfb57a90b57e8325119aad9afeec1. Limitation in Logisim forces me to add new state WAIT_INBOX instead of stay in DECODE until empty=0. Review in #7.

adumont commented 6 years ago

See https://github.com/adumont/uartrx-fifo/ for a working FIFO example that could be used for INBOX.

adumont commented 6 years ago

Done in e28dc764246d5af42a15573c7af151057fdb22d8