Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[HOWTO] - Write TRS-80 Floppy's using Debian

Share your HowTo, Documentation, Tips and Tricks. Not for support questions!.
Post Reply
Message
Author
lkraemer
Posts: 209
Joined: 2011-02-09 05:02
Been thanked: 4 times

[HOWTO] - Write TRS-80 Floppy's using Debian

#1 Post by lkraemer »

[HOWTO] - Write TRS-80 Floppy's using Debian

Postby lkraemer » 2022-01-24 07:30

UPDATED - 08/12/2022 for some typo's


This HOWTO: explains how to use Debian to write 5.25" Boot Floppy's for a TRS-80 Model 4's Diagnostics.

If you are not familiar with DOSBOX, refer to the following URL as DOSBOX is used to create the .RAW Image (Sector Dump)
viewtopic.php?f=16&t=61888

I had previously used IMAGEDISK Ver 1.18 by Dave Dunfield to create a Preservation file on my OLD DOS Computer. TRSDIAG2.IMD

My problem was that my OLD DOS computer was 1500 miles away, and I needed to make a couple floppy's. I located a 5.25" SS/DD
Floppy Drive, and strapped it as DS1 in the DS{0..3} configuration. This matched my Desktop's Floppy cable which had conductors
10 thru 16 twisted for the floppy at the end of the cable. When I tried to access the floppy drive I had no response from the drive.
Finally, I remembered to check the /etc/mediaprm file to locate the proper settings. TRS180 was the proper choice. I used a Terminal
to check and set the drive Parameters.

/etc/mediaprm contained:

Code: Select all

"TRS180":
 SS DD sect=18 ssize=256
$ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
fd0 2:0 1 4K 0 disk <------------------Proper Floppy Drive
sda 8:0 0 465.8G 0 disk
├─sda1 8:1 0 117.2G 0 part /
├─sda2 8:2 0 24.4G 0 part
├─sda3 8:3 0 321.7G 0 part
└─sda4 8:4 0 2.5G 0 part [SWAP]
$ getfdprm /dev/fd0
get geometry parameters: No such device
$ sudo setfdprm -p /dev/fd0 TRS180
$ getfdprm /dev/fd0
SS DD sect=18 ssize=256
$ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
fd0 2:0 1 180K 0 disk <------------------- Correct size for Floppy
sda 8:0 0 465.8G 0 disk
├─sda1 8:1 0 117.2G 0 part /
├─sda2 8:2 0 24.4G 0 part
├─sda3 8:3 0 321.7G 0 part
└─sda4 8:4 0 2.5G 0 part [SWAP]
All that was left to do was to convert the TRSDIAG2.IMD file to a .RAW (Sector Dump) type file and write it to the
floppy with dd. I used the Imagedisk utilities (IMDA & IMDU) to create the .RAW file from within DOSBOX.


******************DOSBOX*******************
>mount c: ~/trs80gp/
>c: <enter>

>IMDA TRSDIAG2.IMD > TRSDIAG2.TXT
>IMDU TRSDIAG2.IMD TRSDIAG2.RAW /B /E /D >> TRSDIAG2.TXT

>z <enter>
>mount -u c
>exit

******************DOSBOX*******************

TRSDIAG2.TXT Contains:

Code: Select all

IMageDisk Analyzer 1.18 / Mar 12 2012
IMD 1.18: 23/01/2022 09:25:17

trs80gp blank disk 1 sides 40 tracks
Required cylinders: 40
Required heads    : 1
Data rate         : 250kbps
Est. maximum track: 6223 bytes

Possible drives/options to write TRSDIAG2.IMD :

 5.25" DD 40-track
   Double-step: OFF

 5.25" QD 80-track
   Double-step: ON

 5.25" HD 80-track
   Double-step: ON
   250 kbps -> 300 kbps

 3.5" DD 80-track   NOTE: *1
   Double-step: OFF

 3.5" HD 80-track   NOTE: *1
   Double-step: OFF

*1 40 track image will use only first 1/2 of 80-track drive.


IMageDisk Utility 1.18 / Mar 07 2012
IMD 1.18: 23/01/2022 09:25:17

trs80gp blank disk 1 sides 40 tracks
Assuming 1:1 for Binary output
 0/0 250 kbps DD  18x256
      1   4   7   10  13  16  2   5   8   11  14  17  3   6   9   12  15  18 
      D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 1/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 2/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 3/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 4/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 5/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 6/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 7/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 8/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
 9/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
10/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
11/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
12/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
13/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
14/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
15/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
16/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
17/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
18/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
19/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
20/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
21/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
22/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
23/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
24/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
25/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
26/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
27/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
28/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
29/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
30/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
31/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
32/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
33/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
34/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
35/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
36/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
37/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
38/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
39/0  D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D   D  
40 tracks(40/0), 720 sectors
At this point you have two options. I run Debian Linux so I chose to use dd to write the sector dump.
If you have the SDLTRS Emulator installed on your computer you can use it to write the real floppy.
Skip to the SDLTRS section below.

******************TERMINAL*******************

Code: Select all

dd if=TRSDIAG2.RAW bs=256 of=/dev/fd0 conv=notrunc
******************TERMINAL*******************

The Floppy's booted when placed in a TRS-80 Model 4.



********************SDLTRS********************
SDLTRS is located at: https://gitlab.com/jengun/sdltrs

To use SDLTRS for writing the Floppy use the following command for startup. Use BACKUP :0 :1
to format and make a floppy from the TRSDIAG2.DMK file.

$ cd /path/to/sdltrs/

NOTE: the ROM images are in this path.

$ sdltrs -keystretch 400 -model 4 -romfile model4.rom -disk0 TRSDIAG2.DMK -disk1 /dev/fd0


********************SDLTRS********************

The floppy should boot on the Model 4.

Larry

Post Reply