Skip to content

GreaseWeazle

Grease Weazle F7 Plus

Isn’t she a thing of beauty? What? You’ve not heard of the GreaseWeazle? Then you’re not alone, I only discovered this amazing gadget very recently and wish I’d know sooner…

Why do you need one? don’t you have enough gadgets?

You can never have enough useful gadgets!

Back in the 80’s I used to develop code, reverse engineer other peoples and create tools for hacking and games for playing written in Assembly language, and a lot of my source code is stored on Amstrad 3″ Hard Plastic discs. That’s right, it’s not a typo, these are 3″ disks that were predominantly found in Amstrad and Spectrum computers, including the PCW range of word processors etc.

Amstrad CPC 3″ Floppy Disk

I’ve been transferring my data originally using a USB Floppy Emulator from Zaxon (which I will cover in a separate blog entry because this gadget covers a much different use case scenario).

There are some disks that I encoded using a Disk Protection system I created in the 80’s and 90’s which meant that standard hardware was unable to accurately duplicate the disk and therefore fail the anti-piracy checks. This worked well as a proof of concept and made it’s way onto commercial educational titles.

It also meant that 30+ years later I was unable to preserve accurately the data on the disks due to the protection system still being valid today!

Via the Retro community I learned of the GreaseWeazle, and at a fundamental level it works by recording the magnetic fluctuations on the disk surface and therefore doesn’t rely on a specific disk interface to decode those signals. As such it makes it perfect for making digital forensic copies of disks in the past.

The Retro community are friendly, vibrant, knowledgeable and helpful, I find that those who develop projects such as this also provide amazing support and I have to acknowledge thank you to the following :-

Keir Fraser, Ant Goffart for producing the GreaseWeazle
Andrew Philips-Martin, Tom Dalby, Krasimir Hristov, Vasyl Samoilov, Denis Lechevalier
Markus Hohmann, George Bachaelor, Piotr Bugaj
and those of you in the CPC retro scene that have pointed me to the many projects that are still ongoing today to keep the retro dream alive!

Facebook Grouphttps://www.facebook.com/groups/greaseweazle
Keir Fraser Git Repohttps://github.com/keirf/Greaseweazle/wiki
Ant Goffart Repositorieshttps://github.com/aerobaticant?tab=repositories
Sell My Retrohttps://www.sellmyretro.com/user/profile/aerobaticant
JavaCPChttps://sourceforge.net/projects/javacpc/
Useful Links

Enough of the pre-amble, this article will show you how to configure a GreaseWeazle to work on macOS, connecting an Amstrad CPC 3″ External Disk Drive, reading, converting and using your encoded disks in an Emulator (I prefer to use JavaCPC).

What do I need?

Grease Weazlehttps://www.sellmyretro.com/offer/details/greaseweazle-f7-plus-usb-floppy-interface-flux-tool-usb-_b-43881
USB-B Cablehttps://smile.amazon.co.uk/AmazonBasics-USB-2-0-Cable-Male/dp/B00NH11KIK/
Grease Weazle Softwarehttps://github.com/keirf/Greaseweazle/wiki
HxC2001https://hxc2001.com/download/floppy_drive_emulator/index.html

At the time of writing, you will need the latest beta/nightly build.
Floppy Drive and Power SupplyDepends on the target system, I happen to have an Amstrad DDI-1 External Disk Drive, but you can use 3.5″ drives, 5.25″ drives etc.

The GreaseWeazle board was originally designed by Keir Frazer, hower Ant Goffart has produced some lovely range of boards from the design and available pre-built or in kit form from his Sell My Retro page. The project is completely open source and therefore you’re able to download the schematics and build your own if you so wish. I chose the pre-built route as it was guaranteed to be working and my soldering skills aren’t quite what they were in my 20s.

Install the GreaseWeazle software into a folder you will remember the location, it’s straight forward and instructions are provided, you may need to install additional libraries using the following command:

python3 -m pip install --user crcmod pyserial bitarray

You will need XCode installed on your mac though as I understand it uses the command line to build the final tools.

In my case I received a warning that my version of PIP is out of date and needs patching which you can do from the command line as :

python3 -m pip install --upgrade pip --user

Important

Before testing your Grease Weazle Board you will need to open up your floppy drive and disconnect the 5V supply, otherwise you may cause damage to the GW board.

Disconnect the 5V Supply Plug
Drive Assembled and Ready to Read Disks

Now you can connect your drive to the power supply and attach the 34 pin IDC cable to the drive and GW board. Switch your drive on, and connect the Grease Weazle to the USB Port. If all is well you can issue the following command from the Grease Weazle folder to check everything is installed correctly. If you hear the drive running constantly then the cable is upside down on the drive, disconnect, turn the cable over and try again.

jason@Jasons-iMac GreaseWeazle % ./gw info
Host Tools: v0.20
Greaseweazle:
  Device:   /dev/cu.usbmodem4012401
  Model:    F7 Plus (Ant Goffart, version 2)
  Firmware: v0.20
  Serial:   GW002D00283438510B36383538
  USB Rate: Full Speed (12 Mbit/s)

With Amstrad CPC External Drives, the drive unit is hard soldered to be Drive B since it was intended for use on a CPC 6128 who’s A drive was already present. This tripped me up to begin with. To read a disk of 40 tracks use the following command :-

./gw read --revs=5 --drive B --ecyl=39 --single-sided diskfilename.scp

This will read 40 tracks (0-39) to a file of format SCP using 5 revolutions per track.

In practice I’ve found a single pass works well, however for accuracy more revolutions of the disk are required, especially for some of the copy protected disks that you will find.

What can you do with an SCP file? Other than write the file back to a blank disk giving you an identical copy, you will need to convert the data using HxC. For the purposes of this demonstration I’m using the GUI, but will use command line later on.

Fire up HXC

Click Load
Select an SCP File
Click Export and Choose Amstrad CPC

This will convert the disk to Amstrad CPC .DSK format that you can use in emulators or using Zaxon’s USB Drive Emulator. Within HXC are tools to visually identify tracks and sectors, and is especially useful when looking at disk contents and other data for protected formats etc, but that’s a story for another day.

However, at the start of the article, I explained I have quite a few disks to convert and doing this manually for all disks is time consuming… If only there’s a better way….

It just so happens there is, since HXC also offers a command line utility. I installed this (from the same DMG Download) to the same root folder to GreaseWeazle, however you will need to remove the quarantine attribute on the files using the following :-

xattr -r -d com.apple.quarantine *

Otherwise you will get a system alert when trying to run the command line. Use this command sparingly, since macOS is designed to protect itself from unknown downloads.

It took a while to work out the correct command sequence to translate SCP files to Amstrad DSK however the following will do the trick :-

./hxcfe_cmdline/App/hxcfe -finput:diskfilename.scp -conv:AMSTRADCPC_DSK -foutput:diskfilename.dsk

Who wants to be typing all that out for each disk? In a world of automation I present to you a very crude BASH Script that will take care of the admin for you. You will need to create a folder structure like this, unless you modify the script to suit your own set up.

Remember folders are case sensitive

The latest Amstradify.sh script can be found on my GitHub Repository https://github.com/muckypaws/AmstradCPC/tree/master/GreaseWeazle it’s not operational strong but will get the job done for you, however if you want to contribute to the project and improve the script, then that’s what github is for!

To execute the script, make sure you have execute permissions. Examples are provided below.

chmod +x Amstradify.sh

./Amstradify.sh
Welcome To Amstradify Script V1.0


Ensure your GreaseWeazle is connected and powered on


Enter Disk Filename to Use: ChoiceCheats7


Which Side: A or B: (return for none): A
Using: ./scp/ChoiceCheats7_SideA.scp to write to ./cpc/ChoiceCheats7_SideA.dsk

Seek to Track 0

Attempting to Read Disk: ChoiceCheats7

** Greaseweazle v0.20 [F7], Host Tools v0.20
Reading Track 41.0...

Seek to Track 0

Running HXCFE Command to Convert data to DSK Format
Input file : ./scp/ChoiceCheats7_SideA.scp
Output file : ./cpc/ChoiceCheats7_SideA.dsk
Checking ./scp/ChoiceCheats7_SideA.scp
File loader found : SCP_FLUX_STREAM (SCP Stream Loader)
file loader found!
Loading ./scp/ChoiceCheats7_SideA.scp
Loading SCP file...
Write CPCDSK file ./cpc/ChoiceCheats7_SideA.dsk...


Tracks and Sectors Read
====== === ======= ====

track : 00 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 01 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 02 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 03 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 04 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 05 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 06 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 07 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 08 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 09 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 10 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 11 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 12 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 13 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 14 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 15 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 16 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 17 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 18 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 19 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 20 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 21 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 22 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 23 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 24 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 25 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 26 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 27 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 28 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 29 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 30 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 31 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 32 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 33 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 34 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 35 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 36 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 37 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 38 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 39 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 40 :  193 198 194 199 195 200 196 201 197 ,512B/s
track : 41 :  193 198 194 199 195 200 196 201 197 ,512B/s

Converted to File: ./cpc/ChoiceCheats7_SideA.dsk

Convert Another Disk? (y/n) : 

The script will show you sector information on each track that was identified, filtering out much of the noise from the HXC Logs.

Now you have a .DSK file, you can now fire up your favourite emulator and load it in

And there you have it, from physical disk to macOS and translated to work in an emulator or USB Drive Emulator on real hardware.

If you have any questions on this project, please let me know in the comments below.

1 Comment »

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: