trunk/src/emu/machine/rp5h01.c
| r31522 | r31523 | |
| 1 | 1 | /*************************************************************************** |
| 2 | 2 | |
| 3 | | RP5H01 - Ricoh 64x1bit PROM with 6/7-bit counter |
| 3 | RP5H01 - Ricoh 64x1bit(+8bit) PROM with 6/7-bit counter |
| 4 | 4 | |
| 5 | | TODO: |
| 6 | | - follow the datasheet better (all dumps presumably needs to be redone |
| 7 | | from scratch?) |
| 5 | In reality, PROM data is 72bits (64 + 8bit 'dummy'). In 7-bit counter mode, |
| 6 | from 64 to 127 (%1000000 to %1111111), the dummy bits are read repeatedly, |
| 7 | with a mask of %1010111. For example if the 8 dummy bits are $7c, |
| 8 | bits 64 to 127 are read as $7c $7c $00 $00 $7c $7c $00 $00. |
| 9 | To simplify this, our emulation expects 'overdumps', 128bits total. |
| 8 | 10 | |
| 9 | 11 | ***************************************************************************/ |
| 10 | 12 | |
| r31522 | r31523 | |
| 39 | 41 | |
| 40 | 42 | void rp5h01_device::device_start() |
| 41 | 43 | { |
| 44 | assert(region()->bytes() == 0x10); |
| 42 | 45 | m_data = *region(); |
| 43 | 46 | |
| 44 | 47 | /* register for state saving */ |
| r31522 | r31523 | |
| 58 | 61 | m_counter = 0; |
| 59 | 62 | m_counter_mode = COUNTER_MODE_6_BITS; |
| 60 | 63 | m_enabled = 0; |
| 61 | | m_old_reset = -1; |
| 64 | m_old_reset = 0; |
| 62 | 65 | m_old_clock = 0; |
| 63 | 66 | } |
| 64 | 67 | |
trunk/src/emu/machine/rp5h01.h
| r31522 | r31523 | |
| 1 | 1 | /*************************************************************************** |
| 2 | 2 | |
| 3 | | RP5H01 - Ricoh 64x1bit PROM with 6/7-bit counter |
| 3 | RP5H01 - Ricoh 64x1bit(+8bit) PROM with 6/7-bit counter |
| 4 | 4 | |
| 5 | 5 | **************************************************************************** |
| 6 | 6 | ___________ |
| 7 | 7 | DATA 1 |* | 8 COUNTER OUT |
| 8 | | | | |
| 8 | | | |
| 9 | 9 | _CE/Vpp 2 | RP5H01 | 7 RESET |
| 10 | | | RF5H01 | |
| 10 | | RF5H01 | |
| 11 | 11 | Vcc 3 | | 6 DATA CLOCK |
| 12 | | | | |
| 12 | | | |
| 13 | 13 | GND 4 |___________| 5 TEST |
| 14 | 14 | |
| 15 | 15 | ***************************************************************************/ |