Skip to content

Back-to-back reads not returning incremented address data #4

@jburks

Description

@jburks

DS1Z_QuickPrint2

This was seen in a test setup driving communication from a Raspberry Pi connected via I2C to a 16 bit GPIO expander and then to a VERA implemented using an UPduino 3.1 on a solderless breadboard. The official X16 emulator was modified such that all register IO within the emulator system and the emulated VERA was duplicated out to the VERA on the breadboard. The results of all register reads from the emulator are compared and mismatches are reported. The only mismatches observed so far happens during a cursor blink (at a "READY." prompt) at which time the second read always, or almost always, comes back with the same data from the first read as though the address had not been incremented.

Attached is a logic analyzer trace from the UPduino-based VERA. D7 of the analyzer appears to have an internal connection and is always reading ground but probing it separately does show the D7 signal behaving as expected. The analyzer probes are connected between the GPIO expander and the UPduino module. The Pi and GPIO expander are both operating with 3.3v IO. The only change to the VERA source code was the addition of a PLL to derive a 25MHz clock from the 12MHz clock on the module. A log of video activity from the emulator and VERA HW activity was collected on some runs, the relevant portion of a failure similar to the one in the LA trace looks like this:

VERA  READ $(00) == $0C
VERA  READ $(01) == $B8
VERA  READ $(02) == $11
VERA WRITE $(00) <= $00
VIDEO WRITE $(00) <= $00
VERA WRITE $(01) <= $B9
VIDEO WRITE $(01) <= $B9
VERA WRITE $(02) <= $11
VIDEO WRITE $(02) <= $11
VERA  READ $(03) == $20
READ  video_space[$1B900] = $20
VERA  READ $(03) == $20
READ  video_space[$1B901] = $61
!! MISMATCH !! ($03): 20 != 61

The emulator VERA correctly returned $61 while the hardware VERA returned $20. Immediately preceding the mis-matched read is a successfully matched read of $20 and a write to ADDR_L/_M/_H of $1B900 and setting the increment to 1.

In the attached trace, Cursor A (solid vertical line) on the left is marking the approximate location of the write to ADDR_H with the value $11. Cursor B (dotted vertical line) is marking the approximate location of the first read of DATA0 and getting the value $20. The next CS# assertion to the right of Cursor B is the second read of DATA0 which gets the erroneous value of $20.

A python script to perform a similar sequence was also written but always sees the correct, address-incremented value. A trace when that script is running has not yet been collected, but when it is the result will be posted as a reply to this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions