• Stars
    star
    352
  • Rank 120,622 (Top 3 %)
  • Language
    C++
  • License
    MIT License
  • Created about 6 years ago
  • Updated 2 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

PSOC5 floppy disk imaging interface

FluxEngine

(If you're reading this on GitHub, the formatting's a bit messed up. Try the version on cowlark.com instead.)

Breaking news! As of 2022-09-09, there's new filesystem support. Read (and sometimes write) files directly from (and to) your disks, with eight different file systems! It works in the GUI, too, which is available for Linux (and other Unix clones), Windows and OSX. See the details below.

screenshot of the GUI in action

What?

The FluxEngine is a very cheap USB floppy disk interface capable of reading and writing exotic non-PC floppy disk formats. It allows you to use a conventional PC drive to accept Amiga disks, CLV Macintosh disks, bizarre 128-sector CP/M disks, and other weird and bizarre formats. (Although not all of these are supported yet. I could really use samples.)

The hardware consists of a single, commodity part with a floppy drive connector soldered onto it. No ordering custom boards, no fiddly surface mount assembly, and no fuss: nineteen simpler solder joints and you're done. You can make one for $15 (plus shipping).

Don't believe me? Watch the demo reel!

<iframe width="373" height="210" src="https://www.youtube.com/embed/m_s1iw8eW7o" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

New! The FluxEngine client software now works with Greaseweazle hardware. So, if you can't find a PSoC5 development kit, or don't want to use the Cypress Windows tools for programming it, you can use one of these instead. Very nearly all FluxEngine features are available with the Greaseweazle and it works out-of-the box. See the dedicated Greaseweazle documentation page for more information.

Where?

It's open source on GitHub!

How?

This page was getting kinda unwieldy so I've broken it up. Please consult the following friendly articles:

  • Frequently asked questions ∾ but why...? ∾ does it...? ∾ can it...?

  • How the FluxEngine works ∾ nitty gritty of the sampler/sequencer hardware ∾ useful links on floppy drives ∾ why I'm not using an Arduino/STM32/ESP32/Raspberry Pi

  • Making a FluxEngine ∾ what parts you need ∾ building it ∾ setting up the toolchain ∾ compiling the firmware ∾ programming the board

  • Using a FluxEngine ∾ what to do with your new hardware ∾ flux files and image files ∾ knowing what you're doing

  • Using Greaseweazle hardware with the FluxEngine client software ∾ what works ∾ what doesn't work ∾ where to go for help

  • Configuring for your drive ∾ but I don't have a 80 track drive! ∾ reading and writing 40 track disks ∾ Shugart and Apple II

  • Direct filesystem access ∾ imaging files is a pain ∾ accessing files directly ∾ features and limitation ∾ it works on disk images too, you say?

  • Troubleshooting dubious disks ∾ it's not an exact science ∾ the sector map ∾ clock detection and the histogram

  • Disk densities ∾ what's the difference between an HD and DD disk? ∾ you can't do that with that ∾ measuring your drive's ability to work with exotic formats ∾ I think my drive is broken

Which?

The current support state is as follows.

Dinosaurs (🦖) have yet to be observed in real life --- I've written the encoder and/or decoder based on Kryoflux (or other) dumps I've found. I don't (yet) have real, physical disks in my hand to test the capture process, or hardware to verify that written disks work.

Unicorns (🦄) are completely real --- this means that I've read actual, physical disks with these formats and/or written real, physical disks and then used them on real hardware, and so know they work (or had reports from people who've had it work).

If a filesystem is listed, this means that FluxEngine natively supports that particular filesystem and can read (and sometimes write, support varies) files directly from disks, flux files or disk images. Some formats have multiple choices because they can store multiple types of file system.

Profile Format Read? Write? Filesystem?
acornadfs Acorn ADFS: BBC Micro, Archimedes 🦖
acorndfs Acorn DFS: Acorn Atom, BBC Micro series 🦄 ACORNDFS
aeslanier AES Lanier "No Problem": 616kB 5.25" 77-track SSDD hard sectored 🦖
agat Agat: 840kB 5.25" 80-track DS 🦖 🦖
amiga Amiga: 880kB 3.5" DSDD 🦄 🦄 AMIGAFFS
ampro Ampro Little Board: CP/M 🦖 CPMFS
apple2 Apple II: Prodos, Appledos, and CP/M 🦄 🦄 APPLEDOS CPMFS PRODOS
atarist Atari ST: Almost PC compatible 🦄 🦄
bk BK: 800kB 5.25"/3.5" 80-track 10-sector DSDD 🦖 🦖
brother Brother word processors: GCR family 🦄 🦄 BROTHER120 FATFS
commodore Commodore: 1541, 1581, 8050 and variations 🦄 🦄 CBMFS
eco1 VDS Eco1: CP/M; 1210kB 77-track mixed format DSHD 🦖 CPMFS
epsonpf10 Epson PF-10: CP/M; 3.5" 40-track DSDD 🦖 CPMFS
f85 Durango F85: 461kB 5.25" 77-track SS 🦖
fb100 Brother FB-100: 100kB 3.5" 40-track SSSD 🦖
hplif Hewlett-Packard LIF: a variety of disk formats used by HP 🦄 🦄 LIF
ibm IBM PC: Generic PC 3.5"/5.25" disks 🦄 🦄 FATFS
icl30 ICL Model 30: CP/M; 263kB 35-track DSSD 🦖 CPMFS
mac Macintosh: 400kB/800kB 3.5" GCR 🦄 🦄 MACHFS
micropolis Micropolis: 100tpi MetaFloppy disks 🦄 🦄
mx DVK MX: Soviet-era PDP-11 clone 🦖
n88basic N88-BASIC: PC8800/PC98 5.25" 77-track 26-sector DSHD 🦄 🦄
northstar Northstar: 5.25" hard sectored 🦄 🦄
psos pSOS: 800kB DSDD with PHILE 🦄 🦄 PHILE
rolandd20 Roland D20: 3.5" electronic synthesiser disks 🦖
rx50 Digital RX50: 400kB 5.25" 80-track 10-sector SSDD 🦖 🦖
smaky6 Smaky 6: 308kB 5.25" 77-track 16-sector SSDD, hard sectored 🦖 SMAKY6
tids990 Texas Instruments DS990: 1126kB 8" DSSD 🦖 🦖
tiki Tiki 100: CP/M CPMFS
victor9k Victor 9000 / Sirius One: 1224kB 5.25" DSDD GCR 🦖 🦖
zilogmcz Zilog MCZ: 320kB 8" 77-track SSSD hard-sectored 🦖
{: .datatable }

Notes

  • IBM PC disks are the lowest-common-denominator standard. A number of other systems use this format in disguise (the Atari ST, late-era Apple machines, Acorn). FluxEngine supports both FM and MFM disks, although you have to tell it which one. If you have an unknown disk, try this; you may get something. Then tell me about it.

  • Not many formats support writing yet. That's because I need actual, physical hardware to test with in order to verify it works, and I only have a limited selection. (Plus a lot of the write code needs work.) There hasn't been a lot of demand for this yet; if you have a pressing need to write weird disks, please ask. I haven't implemented write support for PC disks because they're boring and I'm lazy, and also because they vary so much that figuring out how to specify them is hard.

If you have samples of weird disks, and want to send them to me --- either FluxEngine, Kryoflux or Catweasel dumps, or (even better) actually physically --- I can identify them and add support.

Please note that at this point I am not interested in copy protected disks. It's not out of principle. It's just they'll drive me insane. FluxEngine will most likely be able to read the data fine, unless they're doing bizarre things like spiral tracks or partially encoded data, but let's stick with normal conventionally formatted disks for the time being!

But!

That said, I need to post a warning.

********** BIG DISCLAIMERY WARNING WITH ASTERISKS **********

Floppy disks are old, unreliable, and frequently damaged and/or filthy. I expect you to know what you're doing and be responsible for your own actions. It's entirely possible for a damaged disk, when read, to scrape the magnetic coating off the disk and pack it into the drive's disk head, not only permanently damaging the drive, but also irrecoverably destroying any data on the disk.

If this happens and you complain to me, I will be sympathetic but fundamentally unhelpful. Proceed at your own risk.

Remember: FluxEngine is not a substitute for a real data recovery service. Is your data worth money to you? If so, don't try to read it using an open source project hacked together by some person you've never met on the internet.

Also, remember to clean your disk heads.

********** END OF WARNING **********

Who?

The FluxEngine was designed, built and written by me, David Given. You may contact me at [email protected], or visit my website at http://www.cowlark.com. There may or may not be anything interesting there.

License

Everything here except the contents of the dep directory is © 2022 The FluxEngine Authors (mostly me, David Given; see the VCS history for the other people) and is licensed under the MIT open source license. Please see COPYING for the full text. The tl;dr is: you can do what you like with it provided you don't claim you wrote it.

As an exception, dep/emu contains parts of the OpenBSD C library code, maintained by Todd Miller and William A. Rowe (and probably others). It is licensed under the terms of the 3-clause BSD license. Please see the contents of the directory for the full text. It's been lightly modified by me.

As an exception, dep/agg contains parts of the Anti-Grain Antialiasing library, written by Maxim Semanarev (and others). It is licensed under the terms of the 3-clause BSD license. Please see the contents of the directory for the full text. It's been lightly modified by me.

As an exception, dep/stb contains parts of the libstb utility library, written by Sean T Barett (and others). It is public domain/Unlicense/MIT licensed, at your choice. Please see the contents of the directory for the full text.

As an exception, dep/snowhouse contains the snowhouse assertion library, taken from https://github.com/banditcpp/snowhouse. It is Boost Standard License 1.0 licensed. Please see the contents of the directory for the full text. Note that this is only used during the build and no code ends up in the output binaries.

As an exception, dep/libusbp contains the libusbp library, taken from https://github.com/pololu/libusbp. It is MIT licensed. Please see the contents of the directory for the full text.

As an exception, dep/fatfs contains the fatfs library, taken from http://elm-chan.org/fsw/ff/00index_e.html. It is single-clause BSD licensed. Please see the contents of the directory for the full text.

As an exception, dep/adflib contains the adflib library, written by Laurent Clevy et al, taken from https://github.com/lclevy/ADFlib. It is GPL 2.0 licensed. Please see the contents of the directory for the full text.

As an exception, dep/hfsutils contains a partial copy of the hfsutils package, written by Robert Leslie et al, taken from https://www.mars.org/home/rob/proj/hfs. It is GPL 2.0 licensed. Please see the contents of the directory for the full text.

Important: Because of all these exceptions, if you distribute the FluxEngine package as a whole, you must comply with the terms of all of the licensing terms. This means that effectively the FluxEngine package is distributable under the terms of the GPL 2.0.

More Repositories

1

wordgrinder

A word processor which gets the hell out of your way and lets you get some work done.
Lua
943
star
2

ack

The Amsterdam Compiler Kit
C
420
star
3

cpmish

An open source sort-of CP/M 2.2 distribution.
Assembly
346
star
4

cpm65

CP/M for the 6502
Assembly
266
star
5

cowgol

A self-hosted Ada-inspired programming language for very small systems.
C
238
star
6

clue

An experimental C to Javascript/Lua/Perl5/Lisp/Java compiler
C
144
star
7

minix2

Minix 1 and 2, Quick and Dirty editions
C
117
star
8

typetalk

A SmallTalk like live coding system running in the browser, based on TypeScript.
TypeScript
65
star
9

luje

a Java virtual machine written in pure Lua
Java
61
star
10

fforth

A small, portable Forth written in Posix C
C
44
star
11

LBW

Experimental tool for running Linux binaries on Windows
C++
39
star
12

telinkdebugger

A Raspberry Pi Pico-based debugger bridge for the Telink SWS debug protocol.
C++
22
star
13

pcemu

A software 8086 PC emulator.
PostScript
19
star
14

polf

A toy
Assembly
17
star
15

piface

Bare metal boot loader for the Raspberry Pi's VideoCore processor (no ARM!)
C
12
star
16

narcissus

A chording keyboard tool for X
C
11
star
17

cowjac

An experimental Java bytecode to C++ transpiler
Java
10
star
18

jpegfinder

A simple tool for scraping jpeg frames from files. Suitable for recovering corrupted MJPEG files. I'm looking at you, Hubsan.
C
10
star
19

glueesp

A port of the Geoworks Glue DOS linker.
C
10
star
20

ibm6770keyboard

A USB interface for the IBM 6770/6780 keyboard.
C++
9
star
21

cowbel

An experimental programming language
xBase
8
star
22

btracker

A chiptracker editor and player for the BBC Micro.
Assembly
8
star
23

calculon

A very small, fast shader language using LLVM.
C++
8
star
24

bogomandel

A silly toy Mandelbrot program for the BBC Micro.
Assembly
7
star
25

dso152-breakout

Breakout for the Fnirsi DSO152
C++
7
star
26

plmc

A compiler for PL/M targeting LLVM bitcode.
Yacc
6
star
27

dbztool

A command line tool for accessing the bootstrap protocol on Dragonball CPUs.
C++
5
star
28

gcc-vc4

An experimental port of gcc 4.8.1 to the VideoCore IV.
C
5
star
29

gruntle

A text-based CYO MMORPG engine
HTML
4
star
30

cshell

A very simple command line shell for the Commodore 64.
Assembly
4
star
31

qemu-z80

Z80 support for qemu
C
4
star
32

bterm

Firmware/hardware to use a Brother WP-1 word processor as a serial terminal
Assembly
4
star
33

vtech6502

A collection of data about the internals of various VTech 6502-based toys.
4
star
34

cparser

C
4
star
35

maxii-keyboard

PSoC5 firmware to for an ancient MAX-II industrial keyboard
C
4
star
36

libfirm

C
3
star
37

spey

A spam-filtering SMTP proxy using greylisting
Shell
3
star
38

comal65

A Comal interpreter for the 6502
Assembly
3
star
39

stellation

A web based real time space warfare RTS.
Shell
2
star
40

vimutti

Tool for decrypting Buddha Machine flash images.
C
2
star
41

pblq

Amstrad eMailer PBL boot loader client
Shell
2
star
42

objective-lua

A dialect of Lua extended with syntax borrowed from Objective C to add object orientation support.
Lua
1
star
43

ebooksyncer

A tiny tool for syncing (and decrypting) eink Kindle books from the device to a directory for backup.
1
star
44

flooded-moon

The moon, like you've never seen it before.
POV-Ray SDL
1
star
45

uboot-pw1

Customised uboot for Kindle Paperwhite gen 1 devices.
C
1
star
46

bmdkey

Python
1
star
47

sdcc

Patched sdcc for Fuzix
C
1
star
48

fluxengine-testdata

Test data for the FluxEngine project.
1
star
49

ab

Yet Another Build Generator
Python
1
star
50

fgit

Tools for using Fossil as a git client.
Shell
1
star