Physically byte-swapped IDE [AKA twisted cable]

General discussions or ideas about hardware.
User avatar
Badwolf
Site sponsor
Site sponsor
Posts: 3043
Joined: 19 Nov 2019 12:09

Re: Physically byte-swapped IDE

Post by Badwolf »

mfro wrote: 21 Mar 2023 17:02
Badwolf wrote: 21 Mar 2023 12:32 I assume this is because not only is the data byte-swapped, but all the IDE control channels too.
Sure ... if you twist the cables, you also swap hardware registers and software that isn't designed for that will not be able to do anything meaningful to them anymore.
Cool. Perfect. Thanks, guys. Armed with the above confirmation, a debug build of EmuTOS and Alex's link to PP's twisted driver I was able to prove it's doing what I thought it was doing and access an SD card written on my Mac and transplanted.

It autoboots well under ET, TOS locks it up trying to boot from it (presumably a command that isn't getting a response, leaving it in an inconsistent state) then running PP's driver twice (first time to unlock it) works.

I'm not sure where I want to go with this next, but it's nice to see it working.

Cheers,

BW
DFB1 Open source 50MHz 030 and TT-RAM accelerator for the Falcon
Smalliermouse ST-optimised USB mouse adapter based on SmallyMouse2
FrontBench The Frontier: Elite 2 intro as a benchmark
User avatar
alexh
Site sponsor
Site sponsor
Posts: 1341
Joined: 17 Oct 2017 16:51
Location: Oxfordshire

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by alexh »

Is HW byte swap noticeably faster?

HDD performance on retro systems is always a thorn in my side so anything that can be done to improve responsiveness is good.

I'm not an expert in TOS but in AmigaDOS you can get significantly better performance by adding a configurable size cache (addbuffers). Is that something you can tweak in TOS?

I'm also interested in what volume size limits and partition size limits there are with the various TOS versions / filesystems/ drivers and how best to overcome them. I've not seen it written down anywhere in one place.
Senior Principal ASIC Engineer - SystemVerilog, VHDL
Thalion Webshrine - http://thalion.atari.org
ST,STf,STfm,STe,MegaST,MegaSTe,Falcon060
A500+,A600,A4000/060,CD32,CDTV
User avatar
Badwolf
Site sponsor
Site sponsor
Posts: 3043
Joined: 19 Nov 2019 12:09

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by Badwolf »

alexh wrote: 22 Mar 2023 09:58 Is HW byte swap noticeably faster?
I need to dig out the transferrate program (again from PP, IIRC) & clock them. Only really had time to verify behaviour yesterday.

I'm trying a couple of different approaches. I've got an adapter board that allows master/slave configuration and also byte swapped/non-byteswapped connection to the host.

Option one is to have a master, partitioned for Atari to boot from and a removable slave to ferry between the Falcon and modern hardware, employing software byte-swap.

Option two is to byte swap the whole shebang and only need one device that can be removed and plugged into the Mac/PC. This will auto-boot under EmuTOS, but nothing else yet.

Option zero, I should mention, is to not byteswap anything and just use EmuTOS (or PP's driver) and a PC formatted device. This will work fine, but will have to logically swap everything, so will be slower.

Two is nice because of speed and also you can fire up Hatari with your normal configuration easy as you like, but the complications around getting it to autostart exist. Like I say, normal TOS actually blocks the drive when trying to boot (the activity light stays on).

All a bit of fun, though. :)

BW
DFB1 Open source 50MHz 030 and TT-RAM accelerator for the Falcon
Smalliermouse ST-optimised USB mouse adapter based on SmallyMouse2
FrontBench The Frontier: Elite 2 intro as a benchmark
User avatar
Cyprian
Posts: 543
Joined: 22 Dec 2017 09:16
Location: Warszawa, Poland

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by Cyprian »

alexh wrote: 22 Mar 2023 09:58 Is HW byte swap noticeably faster?
on the ST yes, because shifting instructions are rather slow on 68000 processor. In case of Falcon - I have no idea - 68030 has cost less shifting due to a barrel-shift .
alexh wrote: 22 Mar 2023 09:58 I'm not an expert in TOS but in AmigaDOS you can get significantly better performance by adding a configurable size cache (addbuffers). Is that something you can tweak in TOS?
Disk drivers (e.g.HD Driver/ICD/HUSHI) reserve memory buffer for the cache (it size can be changed) and it is active by the default.
alexh wrote: 22 Mar 2023 09:58 I'm also interested in what volume size limits and partition size limits there are with the various TOS versions / filesystems/ drivers and how best to overcome them. I've not seen it written down anywhere in one place.
Max partition size depends on the TOS version:
1.00-1.02: 256 MB
1.04-3.xx : 512 MB
4.0x: 1024 MB (but I tested 2GB on my Falcon and it worked fine for me)

In case of MiNT - I have no idea, it has its own drivers, therefore my guess is that its partitions can be really big.
ATW800/2 / V4sa / Lynx I / Mega ST 1 / 7800 / Portfolio / Lynx II / Jaguar / TT030 / Mega STe / 800 XL / 1040 STe / Falcon030 / 65 XE / 520 STm / SM124 / SC1435
DDD HDD / AT Speed C16 / TF536 / SDrive / PAK68/3 / Lynx Multi Card / LDW Super 2000 / XCA12 / SkunkBoard / CosmosEx / SatanDisk / UltraSatan / USB Floppy Drive Emulator / Eiffel / SIO2PC / Crazy Dots / PAM Net
http://260ste.atari.org
User avatar
JezC
Posts: 2785
Joined: 28 Aug 2017 23:44

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by JezC »

@Badwolf I've taken a simple route for now...an IDE cable with one SD to IDE plus one CF adapter fitted at the same time. The SD is formatted for the Falcon to boot from while the CF card is formatted to work with the PC as well as the Falcon.

So, I can move files between PC & Falcon via the first partition of the CF card and copy them onto the SD card.

My next plan was to get the Falcon connected via Ethernet (or WIFI) but it can't use the cart port as that has dongles for my music s/w permanently plugged in.

I'll be following this with great interest - and any suggestions for suitable Ethernet/WIFI solutions would be most welcome too!

:thumbup:
User avatar
Cyprian
Posts: 543
Joined: 22 Dec 2017 09:16
Location: Warszawa, Poland

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by Cyprian »

JezC wrote: 22 Mar 2023 12:47 I'll be following this with great interest - and any suggestions for suitable Ethernet/WIFI solutions would be most welcome too!
https://github.com/PiSCSI/piscsi
https://www.piscsi.de/
I read somewhere there is a support for DaynaPort network card for Atari
ATW800/2 / V4sa / Lynx I / Mega ST 1 / 7800 / Portfolio / Lynx II / Jaguar / TT030 / Mega STe / 800 XL / 1040 STe / Falcon030 / 65 XE / 520 STm / SM124 / SC1435
DDD HDD / AT Speed C16 / TF536 / SDrive / PAK68/3 / Lynx Multi Card / LDW Super 2000 / XCA12 / SkunkBoard / CosmosEx / SatanDisk / UltraSatan / USB Floppy Drive Emulator / Eiffel / SIO2PC / Crazy Dots / PAM Net
http://260ste.atari.org
czietz
Posts: 586
Joined: 14 Jan 2018 13:02

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by czietz »

Fwiw, I once made a prototype of a standalone adapter that adds the Smartswap* feature to any Atari. However interest was too little to make a Falcon (i.e. 44-pin) version. :(

https://forum.atari-home.de/index.php/t ... #msg247565

* Smartswap -- known from our Thunder and Lightning ST -- is hardware byteswap just for the data, and brings the corresponding speed increase while keeping the compatibility with any driver.
User avatar
Badwolf
Site sponsor
Site sponsor
Posts: 3043
Joined: 19 Nov 2019 12:09

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by Badwolf »

czietz wrote: 22 Mar 2023 14:34 Fwiw, I once made a prototype of a standalone adapter that adds the Smartswap* feature to any Atari. However interest was too little to make a Falcon (i.e. 44-pin) version. :(

https://forum.atari-home.de/index.php/t ... #msg247565

* Smartswap -- known from our Thunder and Lightning ST -- is hardware byteswap just for the data, and brings the corresponding speed increase while keeping the compatibility with any driver.
Very cool! :)

This is something I pondered playing with too, once I understand the IDE protocol better (for now I wouldn't know how to identify data versus register accesses). Now that CPLDs are starting to come back into availability again it could be a one-chip board.

BW
DFB1 Open source 50MHz 030 and TT-RAM accelerator for the Falcon
Smalliermouse ST-optimised USB mouse adapter based on SmallyMouse2
FrontBench The Frontier: Elite 2 intro as a benchmark
User avatar
Cyprian
Posts: 543
Joined: 22 Dec 2017 09:16
Location: Warszawa, Poland

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by Cyprian »

czietz wrote: 22 Mar 2023 14:34 Fwiw, I once made a prototype of a standalone adapter that adds the Smartswap* feature to any Atari. However interest was too little to make a Falcon (i.e. 44-pin) version. :(

https://forum.atari-home.de/index.php/t ... #msg247565

* Smartswap -- known from our Thunder and Lightning ST -- is hardware byteswap just for the data, and brings the corresponding speed increase while keeping the compatibility with any driver.
nice addon,
whats is a difference between that and a twisted cable?
ATW800/2 / V4sa / Lynx I / Mega ST 1 / 7800 / Portfolio / Lynx II / Jaguar / TT030 / Mega STe / 800 XL / 1040 STe / Falcon030 / 65 XE / 520 STm / SM124 / SC1435
DDD HDD / AT Speed C16 / TF536 / SDrive / PAK68/3 / Lynx Multi Card / LDW Super 2000 / XCA12 / SkunkBoard / CosmosEx / SatanDisk / UltraSatan / USB Floppy Drive Emulator / Eiffel / SIO2PC / Crazy Dots / PAM Net
http://260ste.atari.org
czietz
Posts: 586
Joined: 14 Jan 2018 13:02

Re: Physically byte-swapped IDE [AKA twisted cable]

Post by czietz »

Cyprian wrote: 22 Mar 2023 14:45 nice addon,
whats is a difference between that and a twisted cable?
As I wrote. Smartswap only swaps the data bytes, in contrast to a twisted cable that swaps everything and hence needs a specific driver.

Return to “HARDWARE DISCUSSIONS”

Who is online

Users browsing this forum: ClaudeBot, DuckAssistBot, petal [bot] and 29 guests