ZxPand+ not working the same as ZxPand original

Discussions about Sinclair ZX80 and ZX81 Hardware
Post Reply
tdg8934
Posts: 304
Joined: Mon Sep 23, 2013 6:10 pm

ZxPand+ not working the same as ZxPand original

Post by tdg8934 »

I have been doing some initial testing of Beans new ZXGame Interface and it’s had intermittent results with my ZxPand+ and a TS1000 or ZXMore (modified to work with s ZXPand or ZXPand+). One thing the WII controller on the ZXGame Interface with a short POKE program should result X and Y coordinates between 0 and 63 which it does on a ZXPand original but if a ZXPand+ is used with the ZXGame Interface and a TS1000 or ZXMore, it has X and Y coordinates of 97 and 98 even if the WII controller is not plugged into the ZXGsme Interface and no stick movements change it’s high values like you can change when using a ZXPand original. The ZXGame Interface uses 8K-16K so you need to first set CONFIG “M=H” which when entering a CONFIG “M” then moves ram higher to 16K-48K outside of the ZXGame Interface range allowing its use.

I did some more testing. I was able to get my original ZXPand working with TROLL 2.62 firmware installed and used a separate SD card in it.

CAT ">DEMOS"
CAT
CONFIG "M=H"
CONFIG
(shows 16K to 48K)

LOAD "WIITEST1.P"
RUN

It worked with the WII Classic Controller as I repeated this on the ZXMORE and TS1000.

I then went back to my ZXPand+ working with 1.10 MOGGY firmware installed and used a separate SD card in it.

CAT ">DEMOS"
CAT
CONFIG "M=H"
CONFIG
(shows 16K to 48K)

LOAD "WIITEST1.P"
RUN

It DID NOT WORK showing the X=97 and Y=98 and did not change with stick movement. I tried it on both the TS1000 and ZXMORE.

This tells me there is a difference between the CONFIG "M=H" between the ZXPand and the ZXPand+.

Does anyone have any ideas about this , Siit Morris (Charley)?

Thank you.

(Tim)
Moggy
Posts: 3231
Joined: Wed Jun 18, 2008 2:00 pm

Re: ZxPand+ not working the same as ZxPand original

Post by Moggy »

Hi Tim.

The first thing to mention is that the Spand+ should be on v1.12 firmware which is the latest version.
There is a v1.13 which Charlie hasn't made public yet as it mainly focused on a specific area and is a bit experimental.

The problem could be centred around a slight corruption of the firmware, I have had this happen to me and a simple re flash solved the problem and may do so for you plus it doesn't hurt to have the latest firmware.

The following is taken from the manual....


FIRMWARE UPDATES

Interface firmware updates are performed via the SD card boot loader. The firmware binary image, ZXPANDFW.BIN, should be copied to a freshly FAT/FAT16 formatted card. This is then inserted and the interface rebooted by executing a hard reset or power cycle. The yellow LED will come on and the green will flash. When the firmware has updated then the ZX81 will be reset.

The firmware revision is displayed at power-on.

The ZXpand+ contains some programmable logic in the form of a CPLD and this can also be updated in-place. Should the need arise then a file should placed on the SD card and the device rebooted. Because the main firmware is in charge of this process, rather than the space-limited bootloader, then the restrictions outlined above are not relevant.

To determine which revision of overlay ROM you have, type

PRINT PEEK 7679 / 10

This will yield a version something like ‘7.1’. Although not planned at this time it may become necessary to update the ROM. This should be easier than with the classic ZXpand as the code is stored in an EEPROM. It is not possible to update the code in place, however, as the chip does not support this. An external programmer is required but no eraser is necessary. If an update is desired then the chip can be returned to base for reprogramming or a new chip supplied for a minimum cost.


The re-flash code on the spand+ is very robust and even if something happens like a power off or a wobble of the spand+ during flashing only requires that you re-flash again.

Attached is v1.12
Attachments
zxpandfw-1.12.zip
(22.12 KiB) Downloaded 129 times
tdg8934
Posts: 304
Joined: Mon Sep 23, 2013 6:10 pm

Re: ZxPand+ not working the same as ZxPand original

Post by tdg8934 »

Thank you Moggy. I was able to copy over the latest v1.12 firmware and it displays correctly. I also did the Print Peek 7679/10 and it displayed 7.

I ran my previous test on the ZXPand+ and I still see incorrect values of X and Y coordinates being 97 and 98 when they should be variable never higher than 63 and lower than 0. There is still some memory difference between the ZXPand original and ZXPand+.

Tim
tdg8934
Posts: 304
Joined: Mon Sep 23, 2013 6:10 pm

Re: ZxPand+ not working the same as ZxPand original

Post by tdg8934 »

Now that I have the latest versions of firmware on both my ZXPand+ and ZXPand original, I still see this BASIC Wii Classic Controller test (below) not running right on the ZXPand+ but it runs correct on the ZXPand original. It uses the WII Classic Controller on Beans new ZXGame Interface board going between the TS1000 /ZXMore and either the ZXPand original or ZXPand+. I have tried soldering in resistor (i.e. 100 ohm, 470 ohm) values in parallel with RP3 (390 ohm resistor running between the Parallax Propeller diode/resistor inputs and D0-D7 lines. I know the ZIP file ZXGame Interface schematic shows 100 ohm values for RP3 but the parts list shows 390 ohms which I have measured to be 390 ohms. See the attached ZIP file for the data on this.

This should show values between 0 and 63 that change when you move the left joystick.

10 POKE 8800, 34
20 POKE 8801, 0
30 SCROLL
40 PRINT "X=";PEEK 8801,"Y=";PEEK 8802
50 GOTO 20
-------------------------------------------
ZXGame Interface Info:

The module is memory mapped to the 8K thru 16K region. You cannot have any RAM in this region. If you have a ZXPand you need to use “CONFIG M=H”.

The module only uses 4 memory addresses that are repeated from 8192 thru 16383.
It is easy to remember addresses: 8800,8801,8802, and 8803 so that is what I will use.
When using assembly language you can use (IY-4)=8800; (IY-3)=8801; (IY-2)=8802; (IY-1)=8803

The module is register based.
The registers are 16-bits, the lower 8 bits are the LSB, and the upper 8 bits are the MSB.
Address 8800 selects the register (0 to 255).
Address 8801 read/write the LSB of the register.
Address 8802 read/write the MSB of the register.
Address 8803 is the status register. When read if bit 7 is 1, then the interface is busy.
Usually you don't have to bother testing this, but some things do take some time like drawing lines and such.

34 = “WIICC” WII Classic Controller
LSB Write:
0 = Return LX,LY (0-63,0-63)
1 = Return RX,RY (0-31, 0-31)
2 = Return D-PAD Up/Down,Left/Right (0=neither, 1=Up or Left; 2=Down or right)
3 = Return Button A,B (0=Not Pressed; 1=Pressed)
4 = Return Button X,Y (0= Not Pressed; 2=Pressed)
5 = Return Left Trigger, Right Trigger (0=Not Pressed; 31=Pressed)
6 = Return LZ,RZ (0=Not Pressed; 1=Pressed)
7 = Return Select,Home,Start (1=Select Pressed; 2=Home Pressed; 4=Start Pressed)

LSB Read: First return parameter (LX, RX, Up/Down, etc)
MSB Read: Second return parameter (LY, RY, Left/Right, etc)

-----------------------------------------------------------------------------------------

When the ZXPand original is used with the TS1000/ZXMore and the ZXGame Interface, I see values of X=32 Y=32 and change between values of 0 and 63 when I move the left joystick on the Wii Classic Controller plugged into the ZXGame Interface.

When the ZXPand+ is used with the TS1000/ZXMore and the ZXGame Interface, I see values of X=97 Y=98 (which shouldn't be above 63) and moving the left joystick on the Wii classic controller does nothing. Even if the controller is not plugged in, I get the high 97/98 values.

I tried using 8 470 ohm resistors on the underside of the ZXGame Interface in parallel with RP3 (390 ohm values) which gave me an RT of 211 ohms. Now running the program still works fine with the ZXPand original (X=32 Y=32) but with the ZXPand+ the left joystick still has no effect with (X=6 Y=0).

I then removed the 8 470 ohm resistors and tried using 8 100 ohm resistors on the underside of the ZXGame Interface in parallel with RP3 (390 ohm values) which gave me an RT of 78 ohms. Now running the program still works fine with the ZXPand original (X=32 Y=32) but with the ZXPand+ the left joystick still has no effect with (X=0 Y=14).

Not sure what to do at this point. Does anyone know what differences exist between the ZXPand original and the ZXPand+ ?

Thanks - Tim
Attachments
ZXGame Rev A 0_5.zip
(1.64 MiB) Downloaded 122 times
User avatar
mrtinb
Posts: 1906
Joined: Fri Nov 06, 2015 5:44 pm
Location: Denmark
Contact:

Re: ZxPand+ not working the same as ZxPand original

Post by mrtinb »

Do you have the AY-sound-extension on the original ZXpand?

Because ZXpand+ has the AY-sound-expansion built-in.
Martin
https://zx.rtin.be
ZX81, Lambda 8300, Commodore 64, Mac G4 Cube
tdg8934
Posts: 304
Joined: Mon Sep 23, 2013 6:10 pm

Re: ZxPand+ not working the same as ZxPand original

Post by tdg8934 »

Yes I do have the AY sound interface daughter board plugged in the original ZXPand original (which is the working one).

Tim
Post Reply