Skip to content

UltraWarp screen corruption (workaround attached) #180

@ryucats

Description

@ryucats

Hello,

Using ADTPro in a machine that has an UltraWarp accelerator installed has issues with screen corruption when receiving packets with an Uthernet.

The issue appears to be caused by the unilateral disable/re-enable of the ZipChip and TransWarp accelerators in the RECEIVE_LOOP_PAUSE routine in src/client/prodos/ethernet/ethproto.asm. Replacing those bits with an UltraWarp-specific disable/re-enable results in a working ADTPro client.

The workaround looks like this:

diff --git a/src/client/prodos/ethernet/ethproto.asm b/src/client/prodos/ethernet/ethproto.asm
index 80f9fb1..acffd00 100644
--- a/src/client/prodos/ethernet/ethproto.asm
+++ b/src/client/prodos/ethernet/ethproto.asm
@@ -956,30 +956,34 @@ RECEIVE_LOOP_WARM:
        rts
 
 RECEIVE_LOOP_PAUSE:
-       lda #$5a
-       sta $c05a
-       sta $c05a
-       sta $c05a
-       sta $c05a       ; Unlock ZipChip
+;      lda #$5a
+;      sta $c05a
+;      sta $c05a
+;      sta $c05a
+;      sta $c05a       ; Unlock ZipChip
 
-       lda #$00
-       sta $c05a       ; Disable ZipChip       
+;      lda #$00
+;      sta $c05a       ; Disable ZipChip       
 
-       lda #$01
-       sta $C074       ; Disable TransWarp
+;      lda #$01
+;      sta $C074       ; Disable TransWarp
+        lda #$01
+        sta $C05D       ; Slow down UltraWarp
 
 PauseValue:
        lda #$7f
        jsr DELAY       ; Wait!
 
-       lda #$00
-       sta $c05b       ; Enable ZipChip
+;      lda #$00
+;      sta $c05b       ; Enable ZipChip
 
-       lda #$a5
-       sta $c05a       ; Lock ZipChip
+;      lda #$a5
+;      sta $c05a       ; Lock ZipChip
 
-       lda #$00        ; Enable TransWarp
-       sta $C074
+;      lda #$00        ; Enable TransWarp
+;      sta $C074
+        lda #$01
+        sta $C05C       ; Speed up UltraWarp
 
        jmp RECEIVE_LOOP_WARM

I think that it's the ZipChip disable/enable that is frying the UltraWarp, as the address in question is adjacent to the UltraWarp address. I am going to engage Henry at ReactiveMicro for further investigation; there may be a way to detect the UltraWarp and skip the offending instructions thereby.

Edit: it's the ZipChip enable -- writing to $C05B disables the UltraWarp and leaves the system in an indeterminate state.

Cheers.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions