Author Topic: CSW2CDT, new tool suite for tape encoding  (Read 3342 times)

0 Members and 1 Guest are viewing this topic.

Offline cngsoft

  • CPC6128
  • ****
  • Posts: 188
  • Country: es
    • Awards
CSW2CDT, new tool suite for tape encoding
« on: 20:27, 01 April 17 »
At last, after too many months, the first version of the CSW2CDT tool suite is publicly available. Dlfrsilver, loyal alphatester and main inspiration, wrote the French and English handbooks.

http://cngsoft.no-ip.org/csw2cdt.htm

The source code won't be released yet because it's extremely messy :-( Feel free to warn me of every incident that may happen when using CSW2CDT, and please ask me everything you may need to know.
like
0
No reactions
(if you can't see the banner right now my server is currently offline)

Offline ||C|-|E||

  • Administrator
  • 6128 Plus
  • *****
  • Posts: 1.870
  • Country: gb
    • index.php?action=treasury
    • Mundo CPC
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #1 on: 02:01, 02 April 17 »
Thank you for this! I actually do not have any tape I would like to transfer around (somebody made the CDTs already!) but this is a very nice and useful tool  :)

Offline VincentGR

  • 6128 Plus
  • ******
  • Posts: 1.407
  • Country: gr
    • Parts from the past.
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #2 on: 10:52, 02 April 17 »
Fantastic!!!
like
0
No reactions
Visit my BBS (Telnet) : flashbackbbs.sytes.net:6502
http://loaderror.eu/
Amiga 1200 Black Project

Online Maniac

  • Supporter
  • CPC6128
  • *
  • Posts: 261
  • Country: gb
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #3 on: 12:38, 02 April 17 »
Great stuff. Look forward to trying it out.
like
0
No reactions

Offline cpcitor

  • The user previously known as FindYWay
  • 464 Plus
  • *****
  • Posts: 386
  • Country: fr
  • My heart still runs on traditional CPC.
    • My code for the CPC.
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #4 on: 20:02, 11 September 21 »
At last, after too many months, the first version of the CSW2CDT tool suite is publicly available. Dlfrsilver, loyal alphatester and main inspiration, wrote the French and English handbooks.

http://cngsoft.no-ip.org/csw2cdt.htm

Hi Cngsoft! You really achieve wonderful things!

I found old tapes that I'd like to convert to cdt. Looks like csw2cdt is the perfect tool!

I see a version at http://cngsoft.no-ip.org/csw2cdt.htm dated csw2cdt-20191102.zip

The source code won't be released yet because it's extremely messy :-(

Messy source code is not a problem. Messy source code that works is always better than no source code at all, right?

Feel free to warn me of every incident that may happen when using CSW2CDT, and please ask me everything you may need to know.

Well, I have a major "incident", actually a showstopper. Windows-only executables are a problem as none of my PCs run Windows. Anyway I like fiddling with source code and sometimes offering improvements.

Solution: can you offer source code for CSW2CDT? Even privately for a start, if you prefer.
I'm willing to adjust it to compile CSW2CDT for Linux and send you back whatever changes needed. I would focus on command line tools first.
like
0
No reactions
Had a CPC since 1985, currently software dev professional, including embedded systems.

I made in 2013 the first CPC cross-dev environment that auto-installs C compiler and tools: cpc-dev-tool-chain: a portable toolchain for C/ASM development targetting CPC, later forked into CPCTelera.

Offline robcfg

  • Supporter
  • 6128 Plus
  • *
  • Posts: 2.437
  • Country: se
  • 8-Bit Technomancer
    • index.php?action=treasury
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #5 on: 20:48, 11 September 21 »
I'd like also to be available to compile it on MacOS, as it's been 7 years since I don't have any Windows machine at hand.


Also, releasing the source code will allow for improvements and contributions.
like
0
No reactions

Online breiztiger

  • CPC464
  • **
  • Posts: 35
    • Awards
like
0
No reactions

Offline robcfg

  • Supporter
  • 6128 Plus
  • *
  • Posts: 2.437
  • Country: se
  • 8-Bit Technomancer
    • index.php?action=treasury
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #7 on: 15:19, 12 September 21 »
Nice!


Let's see if I can make it work on MacOS.
like
0
No reactions

Offline robcfg

  • Supporter
  • 6128 Plus
  • *
  • Posts: 2.437
  • Country: se
  • 8-Bit Technomancer
    • index.php?action=treasury
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #8 on: 16:08, 12 September 21 »
I managed to compile the programs on MacOS and Linux.


Here are my modifications to the CSW2CDT.C file.
like
0
No reactions

Offline cpcitor

  • The user previously known as FindYWay
  • 464 Plus
  • *****
  • Posts: 386
  • Country: fr
  • My heart still runs on traditional CPC.
    • My code for the CPC.
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #9 on: 17:35, 12 September 21 »
http://cngsoft.no-ip.org/csw2cdt-20210329-2555.zip

Thanks! This compiles on Linux, there are warnings but since later steps work, for a quick check I'd assume it just works well enough.

I tested it with a wav generated by playtzx (then sox to turn voc into wav). csw0 then csw2cdt produced a working cdt (tested with RetroVirtualMachine, hearing the actual signal while loading, and with cpcec which shortcuts the load time).

I then used it on a real file recorded from tape, and it generated a 51-byte-long cdt file, therefore fail:

Code: [Select]
./csw0 block_from_tape.wav

38400 bytes.

./csw2cdt block_from_tape.csw

51 bytes.

In audacity, the curve is ugly and wavy.



I tried "filtering curve" tool in audacity, set to constant -30dB from 0 to 400Hz, then ramp to +6dB at 500Hz then constant.



Curve seems nicer, at least during the pilot tone.



Code: [Select]
./csw0 ../block_from_tape_filtered.wav

105284 bytes.

./csw2cdt ../block_from_tape_filtered.csw

71 bytes.

Success  not yet.


The other way round

I might switch in cpc-dev-tool-chain from using "playtzx" to running csw2cdt -f somesamplerate ; csw0 -t somevalue , because playtzx only generates voc and the timings seem off.

That said, output of csw0 exhibits some unusual extra frequencies which are probably due to interference between output sample rate and times of square wave transitions (confirmed by hearing them less at 48000Hz than at 44100Hz), which does not happen in playtzx output. Might be investigated later.



like
0
No reactions
Had a CPC since 1985, currently software dev professional, including embedded systems.

I made in 2013 the first CPC cross-dev environment that auto-installs C compiler and tools: cpc-dev-tool-chain: a portable toolchain for C/ASM development targetting CPC, later forked into CPCTelera.

Offline cpcitor

  • The user previously known as FindYWay
  • 464 Plus
  • *****
  • Posts: 386
  • Country: fr
  • My heart still runs on traditional CPC.
    • My code for the CPC.
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #10 on: 17:40, 12 September 21 »
I also tried things like the integrated band-pass filter in csw0, but no more success.

Code: [Select]
./csw0 -f 500 2000 block_from_tape.wav && ./csw2cdt block_from_tape.csw

43535 bytes.
51 bytes.

./csw0 -f 500 4000 block_from_tape.wav && ./csw2cdt block_from_tape.csw

46282 bytes.
51 bytes.

Any hints appreciated, @cngsoft and everyone. Thanks!
like
0
No reactions
Had a CPC since 1985, currently software dev professional, including embedded systems.

I made in 2013 the first CPC cross-dev environment that auto-installs C compiler and tools: cpc-dev-tool-chain: a portable toolchain for C/ASM development targetting CPC, later forked into CPCTelera.

Offline dlfrsilver

  • CPC6128
  • ****
  • Posts: 254
    • Awards
Re: CSW2CDT, new tool suite for tape encoding
« Reply #11 on: 23:15, 28 September 21 »
Hi, i know for a fact that Playtzx (like the old tools to make CDT or TZX) have the timings out of specs.


This translates by loading errors when reverted back from TZX to WAV.


I let Cesar answers if he wants to.
like
0
No reactions