Menu

#223 +3 3D Construction Kit Save Fails

v1.2
closed-fixed
nobody
None
5
2016-04-26
2011-08-01
No

John Elliott reports on WoS (http://www.worldofspectrum.org/forums/showthread.php?p=552955#post552955) that the save function on 3D construction kit fails on Fuse (and several emulators other than RealSpectrum).

Discussion

  • Sergio Baldoví

    Sergio Baldoví - 2013-08-04

    The same happens with the load function and it is easier to reproduce:

    1) Download 3DCK program and data-file images [1] for spectrum.
    2) Start a +3 machine and load 3DCK program disk.
    3) Select option 1 - 128K EDITOR.
    4) Press 2 for cursor keys.
    5) Select the LOAD button with the arrow keys.
    6) Press 0.
    7) Load data file from disk or tape? Select disk and press 0.
    8) Insert the data-file disk.
    9) File number? Type 0.
    10) The load never ends.

    The traces of the floppy disk controller are:

    READ_DATA   (MSR ST0 ST1 ST2 ST3)
    write  66   (90  80  80  00  51 )
    write  00   (90  80  80  00  51 )
    write  0C   (90  80  80  00  51 )
    write  00   (90  80  80  00  51 )
    write  C9   (90  80  80  00  51 )
    write  02   (90  80  80  00  51 )
    write  C9   (90  80  80  00  51 )
    write  2A   (90  80  80  00  51 )
    write  FF   (30  00  04  00  51 )
    read...
    
    RECALIBRATE (MSR ST0 ST1 ST2 ST3)
    write  07   (90  40  80  00  51 )
    write  00   (80  00  80  00  51 )
    
    SENSE_INT   (MSR ST0 ST1 ST2 ST3)
    write  08   (D0  E8  80  00  51 )
    read   E8
    read   0C
    
    SEEK        (MSR ST0 ST1 ST2 ST3)
    write  0F   (90  E8  80  00  51 )
    write  00   (90  E8  80  00  51 )
    write  00   (80  E8  80  00  51 )
    
    SENSE_INT   (MSR ST0 ST1 ST2 ST3)
    write  08   (D0  E8  80  00  51 )
    read   E8
    read   0C
    
    {last command repeats in an endless loop}
    

    The data-file disk is inserted before RECALIBRATE command that fails to position the head to cylinder 0. The significant breakpoint for RECALIBRATE command is 0xCC87.

    The problem is that the READY signal from the floppy drive never gets active after inserting the new disk. The TEAC FD55 specifications state:

     (13) READY output signal
       i)   The FDD is powered on.
       ii)  Disk is installed.
       iii) The disk rotates at more than 50% of the rated speed.
       iv)  Two index pulses have been counted after item iii) is satisfied.
    

    The motor-on signal is active so the ready signal should be activated after installing the disk on the drive? The attached patch fix this issue. The traces state:

    RECALIBRATE (MSR ST0 ST1 ST2 ST3)
    write  07   (90  40  80  00  51 )
    write  00   (81  00  80  00  51 )
    
    SENSE_INT   (MSR ST0 ST1 ST2 ST3)
    write  08   (D1  80  80  00  51 )
    read   80
    
    {last command repeats for a while}
    
    SENSE_INT   (MSR ST0 ST1 ST2 ST3)
    write  08   (D0  20  80  00  51 )
    read   20
    read   00
    
    {head positioned on cylinder 0}
    

    So apparently it works but I feel that the current implementation is a bit clumsy because it don't check the rotation speed.

    [1] http://www.3dconstructionkit.co.uk/

     
  • Fredrick Meunier

    Looks like a reasonable option to me.

     
  • Sergio Baldoví

    Sergio Baldoví - 2013-08-19

    Thanks, committed in revision [r5028].

     

    Related

    Commit: [r5028]

  • Sergio Baldoví

    Sergio Baldoví - 2013-08-19
    • status: open --> pending-fixed
    • Group: --> future
     
  • Fredrick Meunier

    • Group: future --> v1.2
     
  • Sergio Baldoví

    Sergio Baldoví - 2016-04-26
    • status: pending-fixed --> closed-fixed
     

Log in to post a comment.