| |
Martin Piper
Registered: Nov 2007 Posts: 697 |
Sample streaming from tape
Has anyone done four bit sample streaming from tape before? I'm thinking the time between pulses can be directly translated to four bit volume values as they are read from tape.
Practically useless, except for pure geekyness. But I wanted to know if it's been done, before I do it myself. |
|
... 36 posts hidden. Click here to view all posts.... |
| |
tlr
Registered: Sep 2003 Posts: 1762 |
Quote: You can't have less than 2 cycles of jitter, so a long column of INX can do the counting instead. Just add a Jmp * at the end.
very clever, then you can just interweave nop's and inx's to acheive the counting rate you desire. Also, if you have decided on an acceptable range for each transition, the inx/nop chain need not be repeated, you can add a branch where there is supposed to be no transition. |
| |
Martin Piper
Registered: Nov 2007 Posts: 697 |
Quote: You can't have less than 2 cycles of jitter, so a long column of INX can do the counting instead. Just add a Jmp * at the end.
Could do. But I actually want to use the mainline for other code. :) Perhaps even enable the screen with some scroller... |
| |
Martin Piper
Registered: Nov 2007 Posts: 697 |
Interesting. If you're using vice, in the monitor do "> d011 1b" and the sample quality with the screen on can be heard.
Not too bad. Time for a scroller? :) |
| |
Martin Piper
Registered: Nov 2007 Posts: 697 |
Links updated with 6.3KHz sample rate now.
Timer A and B are used, which means the CIA can do the underflow and overflow check for free. So the IRQ sample play is much simpler. |
| |
ws
Registered: Apr 2012 Posts: 248 |
Nice Megablast! I'm really curious, where this will lead to, quality wise.
I had a thought, that surely is sort of defeating the actual streaming idea, but i'd like to ask it anyways:
If the recording was recorded slowed down, the loading of the sample buffered and then replayed faster, could that improve overall quality in any significant way?
yeah i know, "why not load actual sampled data, then", but i just had to ask. i was thinking maybe this way perhaps one and a half RAM fillings could be played without having to pre-buffer again, like a Shortplay Mode.
[@ scroller: maybe a screen-off-with sprites scroller would be keeping the quality at max?] |
| |
Martin Piper
Registered: Nov 2007 Posts: 697 |
Instead of using 16 cycles as a multiplier for each volume level, I tried 8 cycles. The sound quality is better due to being able to play back at a higher frequency. However it only sounds better in Vice with zero tape wobble. The default Vice tape wobble of 10 cycles will cause an overall drop in audio quality.
This is a side effect of using frequency modulation to encode the volume on a device prone to frequency shifts. :)
A multiplier of 16 cycles, whilst being easy to encode in the TAP file, also seems to be a sweet spot for "accurate enough" reading of sample volumes at a high enough speed for quality purposes.
Turning on the screen causes high frequency noise, due to the bad lines introducing a regular spike in the volume read from the tape.
WangFM Megablast |
| |
MagerValp
Registered: Dec 2001 Posts: 1065 |
Starting to sound pretty nice!
Would be interesting to hear if delta coding with three or five pulses sounds better. Both would at least double the frequency. |
| |
Krill
Registered: Apr 2002 Posts: 2940 |
Pretty sure that proper resampling of the input wave to suit the encoding would make for a tremendous improvement in quality, much more than tinkering with C-64 side code details. |
| |
tlr
Registered: Sep 2003 Posts: 1762 |
Quote: I think ”Pulse” by pixel for the vic-20 uses this technique for music playback somewhere in the loading sequence.
for the record, this can be found here: https://eyes-uk.itch.io/pulse
srcs:
- https://github.com/SvenMichaelKlose/nipkow
- https://github.com/SvenMichaelKlose/pulse |
| |
soci
Registered: Sep 2003 Posts: 478 |
I'm wondering, did anyone tried this with an actual datassette yet? |
Previous - 1 | 2 | 3 | 4 | 5 - Next |