| | Flavioweb
Registered: Nov 2011 Posts: 463 |
Vice 3.8 r45312 tape emulation problem?
I was experimenting with writing tapes on rh and Vice when I realized that the exact same program (a small basic code of two lines) produced two different signals.
The signal produced on rh was slightly longer than the signal produced by writing the TAP generated by Vice using a U2+.
I then tried to sample the signal on the C64 using a U2+ through the "capture save" function, therefore working directly on the signal produced by the C64 and not by the Datassette.
I immediately noticed a difference.
The "pilot CBM" generated by the C64 is:
$2F, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30 , $2F, $30, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F, $30, $2F, $30, $2F, $30, $2F, $2F , $30, $2F, $30, $30, $2F, $2F while the one produced by Vice is a simple sequence of $2F. I don't know if there are other differences in the signals afterwards.
On Vice I have "Tape Speed Tuning", "Wobble Frequency" and "Wobble amplitude" all at zero.
Since in all the dumps I've seen the pilot is similar to the one found on my rh, I think Vice has a problem with TAP management.
Is it just my problem/am I doing something wrong, or should I fire a bug report? |
|
... 20 posts hidden. Click here to view all posts.... |
| | chatGPZ
Registered: Dec 2001 Posts: 11386 |
here is a quick test - there indeed was some subtle rounding error:
hitmen.c02.at/temp/gurken.tap
is that one more like what you expect?
<s>PS: where is that test program? cant find it on csdb</s>
ok found. the value seems to be really unstable though |
| | Flavioweb
Registered: Nov 2011 Posts: 463 |
These are the results obtained with the U2+ using the "capture save" function:
https://www.flavioweb.it/DaCondividere/204060.zip
From what I see they are as they should be.
If i check your "gurken test" i can see a frequency of 2596hz which is slightly higher than the 2575/2578hz I get from my files on RH.
Maybe it's this little difference that you identify as "rounding errors". |
| | chatGPZ
Registered: Dec 2001 Posts: 11386 |
I cant even make out a proper value, it changes so often and never is stable before the pilot is over. As said before, it makes more sense to compare the actual tap files... could you share yours too? |
| | chatGPZ
Registered: Dec 2001 Posts: 11386 |
The results of the 204060 program show that the timing is spot-on for values dividable by 8, so yes, remaining differences should be purely related to rounding errors (better: quantization errors) |
| | Flavioweb
Registered: Nov 2011 Posts: 463 |
Okay.
But my initial question remains:
why do I see results with U2+ and using real hardware while Vice gives others?
Are U2+ and Real Hardware wrong? |
| | chatGPZ
Registered: Dec 2001 Posts: 11386 |
Quantization errors. You might see a different result with another C64 or with another U2 for the same reason. What VICE produces is "too perfect" in a way, the quantization errors produced by sampling the signal do not exist there. Also the .tap spec do not really tell what to do with values that are not dividable by 8, should the values be truncated (that is what VICE does) or rounded (and if so, how?)? All of it is correct, but will produce different values in the .tap.
Plus using the pilot tone and that program isn't really a well working test setup. The value is so unstable and jumps around so much, i wouldn't interpret much into it. We'd need another test signal that is much longer, so the program would display a stable value. Or a better test program to begin with :)
I'd still like to see the tap you captured for that matter, is it really all that different? Or is the difference purely in the quantization noise now? That's what i would expect at least. |
| | Flavioweb
Registered: Nov 2011 Posts: 463 |
Quoting chatGPZI'd still like to see the tap you captured for that matter, is it really all that different? Or is the difference purely in the quantization noise now? That's what i would expect at least.
The 2 programs i've captured are waveforms saved to tape directly from the C64. No TAP file was used for those two programs.
The only TAP file is the first waveform which was created by Vice and written with the U2+ to tape.
But I can also see the difference when sampling the C64 directly with the U2+.
U2+ is similar to C64 + Datasette. Vice is the worst (farthest from what I see using only RH, i.e. C64 + Datasette). |
| | chatGPZ
Registered: Dec 2001 Posts: 11386 |
WTF that contradicts what you posted before? You didn't actually save that basic prog on the C64 and captured that using U2? What is #8 about then? |
| | Flavioweb
Registered: Nov 2011 Posts: 463 |
#8 concerns the fact that it has been said that "who knows what it does exactly, what error margin does it have, how does it quantize the values, etc." in #7 alluding to the fact that it was U2 that had problems writing the file on Datasette (file which then generated the first waveform of the three posted in the Audacity screenshot).
I am saying from #1 that A TAP GENERATED BY VICE appears to use different frequencies than the signal CREATED ON RH BY THE C64 which I have measured by comparing waveforms, checking the TAP data extracted with the U2 and using the Derogee program.
Okay?
Vice -> tap -> datasette (even just Vice -> tap report different frequencies than C64 -> Datasette really...)
C64 -> datasette
Different frequencies. |
| | chatGPZ
Registered: Dec 2001 Posts: 11386 |
#3 literally states you compared the .tap saved on VICE and that saved on C64. Please provide it.
The only thing that will allow to actually find out what the problem is - or if there even is one (after my local fix) - is the captured .tap from the C64. (And not a random one, but using the provided example, so it can be compared exactly).
Speculating and repeating how VICE is wrong does not help at all.
I am getting strong Zibri vibes by now.
PS: "the frequencies" are pretty much right now in the tap produced by my local fix, the pilot is a 2F/30 soup just like you'd expect
PPS: did you even look at the tap i posted before? the pilot is *byte identical* to yours
committed my fix, build coming up soonish here: https://github.com/VICE-Team/svn-mirror/releases |
Previous - 1 | 2 | 3 - Next | |