Login
Back to forumReply to this topicGo to last reply

Posted By

Stinaris
on 2018-03-14
19:07:47
 4 bit samples

Anyone know the rate at which the typical 4 bit samples are played?
I seem to remember 1khz but it seems a bit low.

I guess this is entirely possible on the plus 4 using the same volume trick as the C64.

I plan to build a 4 bit sampler using an arduino and transfer the assembler Byte list into CBMPrgStudio as my original method on the C64 is not possible without POTs on the joystick ports.

Posted By

Csabo
on 2018-03-14
22:09:43
 Re: 4 bit samples

I don't know if there's such a thing as "typical" playback speed, every program can have different speeds. You can search for "Playback speed" and you'll find many programs where we added the speed (and bits) to the notes. Obviously the higher the playback speed, the better the quality.

You can take a look at Csabo's Wave Converter, and check out the "Replay speed" variable. This is the "timer speed" ($FF00/$FF01 value), and entering a decimal number there will tell you the actual speed in Hz. E.g. $80 -> about 6.9 KHz. If it's that the playback speed you choose, you would resample your stuff to that rate in your favourite sound editor (e.g. Audacity).

Posted By

gerliczer
on 2018-03-15
03:19:43
 Re: 4 bit samples

@Stinaris: I don't know what your goal is with that Arduino project, but I think it is not really necessary. I did something similar with Windows sound recorder, Audacity, Libre Office Calc and Notepad++. And, maybe, I could've skipped LO Calc if I knew Audacity better.

@Csabo: You should also add, that the timer frequency depends on the machine being PAL, NTSC or PAL-N, and (for the first two) the actually selected video mode.

Posted By

Stinaris
on 2018-03-18
11:06:13
 Re: 4 bit samples

Gerliczer - Windows sound recorder, libra office calc, audacity and notepad++ are 3 more things than I want to use.
I'm after an all in one solution. I'd also like it to be in 19" rack format.

I did write a 4 bit converter from wav for the gameboy but I lost the source code (Visual Basic)

Posted By

gerliczer
on 2018-03-18
12:17:39
 Re: 4 bit samples

That's why I wrote, that I don't know what your goal is with that project, Stinaris. My goal was to do it without reinventing any wheels as much as possible. That doesn't mean everyone should take the same road that I took. And, of course, I could suggest you 19" rack format PCs if you like. wink

Posted By

Stinaris
on 2018-03-18
14:45:49
 Re: 4 bit samples

I've got to use my abundance of arduino's. I have a lot happy

I could use my 1 bit sampler on the C64 and write a player routine for the plus4.
Although the quality isn't the clearest.

Posted By

Hypex
on 2018-03-25
08:51:17
 Re: 4 bit samples

Would this use the D/A feature of the TED sound output? And does this support 4-bit samples?

Briefly mentioned here:
http://mclauchlan.site.net.au/scott/C=Hacking/C-Hacking12/gfx.html

Posted By

gerliczer
on 2018-03-25
09:02:53
 Re: 4 bit samples

The D/A capability of TED isn't exactly 4 bit. Without tricks, one can get around 13 different output levels, IIRC. However, with a simple trick, it can be made to produce around 30 levels, which could be enough.

Posted By

Hypex
on 2018-03-26
04:01:08
 Re: 4 bit samples

The usual volume is 3-bits in a 4-bit space. So if the full 4-bits can be used for samples, even if slightly crippled, that's still good. That simple trick would increase it to 5-bits, within limits.

By comparison I wonder how the C64 compares? Sure as a synthesizer it beats the TED hands down, but what about with digitised samples and doing D/A? I should look it up.

Posted By

gerliczer
on 2018-03-26
05:29:29
 Re: 4 bit samples

The TED volume control defines 9 levels, including off. Setting the TED into D/A mode and turning on one or two channels resulting in multiplying the volume by one or two will give the less than 4 bit resolution.

Set one channel to ultrasonic output (register value $3FD) and lock the other (register value $3FE) and write the $FF11 register to produce levels. This results in 4+ bits resolution. There's a detailed description about this in one of TLC's messages sent to a mailing list ages ago.

Nowadays, C64 has a so called "waveform digi" method. You can play 8 bit digis with that, and there are examples of playback sample rates exceeding 15kHz.

Posted By

MMS
on 2018-03-26
09:43:57
 Re: 4 bit samples

Recently I saw a C64 demo where the quality of digitized Prodigy music was clearly higher than 4bit resolution.
It was made with the waveform digi method, and the result was shocking good. So SID has an advantage there too, not only at FM synth... (only BSZ board used for Evo Lution with Compactflash "DMA" and 18bit DA could give us some safe margin, if ever be released for the peasants like me

Posted By

MIK
on 2018-03-26
14:17:46
 Re: 4 bit samples

Csabo's Drum Mix 3 I always thought was quality and better than any samples to come out of a C64 during the commercial era...


Something else from back in the day you can mess about with thanks to the official reset button. wink
I can't remember what I used to do but you can change the speed of the speech at the loading screen of Terra Nova, that "Welcome to Terra Nova a journey through the unknown" is around $1800 if I remember correct.

Posted By

MMS
on 2018-03-26
16:32:49
 Re: 4 bit samples

OFF Yepp, this Drum Mix 3 was unknown to me, it was after I sold my C16, but before started to check stuffs again happy

ON: DM3 sounds really great and clean. The upper frequencies noise still show the limits.
I am just curious: would it make any better, if the TED display would be completely off to speed up the CPU?

IstvanV made some magical SID 3-channel emulation few months back, and switching on the screen made the higher frequencies evidently distorted. I suppose it should be the same here, right?.

Posted By

Stinaris
on 2018-03-27
15:48:12
 Re: 4 bit samples

The C64 can now manage 48khz 8 bit samples!!!!!!

Also thanks Csabo, when my samples sounded really grainy I gave your tool a go and it's sounds great now.
The 4 bit audio doesn't work the same as the Gameboy or how I remember the C64 working.

My little game now has 2 samples and I've still got 2.5kb left of the C16
https://vimeo.com/261737155
:-)


Posted By

MIK
on 2018-03-27
17:57:30
 Re: 4 bit samples

I recognize that first sample, Space Harrier. happy

That Game Over sample is cool, not sure what it's from.

Posted By

Csabo
on 2018-03-27
18:17:24
 Re: 4 bit samples

The Game Over same reminds me of this:
https://www.youtube.com/watch?v=aKG64BRd5Rg&feature=youtu.be&t=216

Posted By

MMS
on 2018-03-28
19:02:10
 Re: 4 bit samples

It is a kind of surrealistic to have 16K game with digitized speech...

I remember there was a C64 Commodore hardware could be connected to the joystick ports, and via the D/A port you could digitize speech or other samples. (I do not remember the name)
It was concluded it is useless, as it could store only 2.5 seconds long samples (on a 64K machine!)

(it came in the exactly same cartride box, as the SFX Sound Expander 11-channel sound Yamaha sound chip add-on for C64 (it should have been released for Plus/4, right? happy pretty nice sound, though very complicated to program them )
https://www.youtube.com/watch?v=w2DpLW374Sg&t=490s

Posted By

MIK
on 2018-03-29
00:37:10
 Re: 4 bit samples

OFF TOPIC: I recall a PC Sound Blaster video that guy did and he placed the card around 1987, the first card came out in 1990. I'm sure he said something like a Yamaha PSS470 had a Sound Blaster inside it when in fact it was the other way around. The PSS460 which is the same keyboard as the PSS470 just different styling was released in 1986! wink

Posted By

MMS
on 2018-03-29
01:43:25
 Re: 4 bit samples

OFF: I have a PSS-102 as a toy for my kids. Very "basic" sound, and I had to produce the cards myself happy
http://www.nurykabe.com/dump/docs/PSS/

Posted By

Hypex
on 2018-03-29
06:31:56
 Re: 4 bit samples

@Stinaris

Oh great. The thread is already called "4 bit samples" and now you come out with this 8-bits at 48Khz! Talk about kicking a man when he's down. Has not the 264's suffered enough? :-x

It's time to retaliate. We must plot our revenge. There may be a V8 next to our 4 but that doesn't mean we just let them roll over us.

We need some strategy. Okay digital sample to TED analogue synthesizer pattern converter needed. We need to hit them back with a beat and hit them loud!

Posted By

Csabo
on 2018-03-29
10:19:45
 Re: 4 bit samples

I wanted to add something else; expand on what gerliczer mentioned above.

TLC's research is here: /ma/1550. The digi table he came up with has 30 distinct values, which is definitely better than the traditional 13 value table. The first (and I think only) time this has been used on Plus/4 is in Vancouver 2010, listen online here.

Posted By

gerliczer
on 2018-03-29
12:14:16
 Re: 4 bit samples

I never checked it, but maybe IstvanV's digital SID player that was built last year uses similar resolution. Various sources and built programs can be found in some later posts of this topic:https://enterpriseforever.com/sound/sid-lejatszo/msg62796/#msg62796.

Posted By

Luca
on 2018-03-29
13:46:44
 Re: 4 bit samples

I intended to save this thread to be read in a spare time after Easter, due its interesting branches growing up day by day, but this last link seems to include some new and complex wave converter by the author of plus4emu, with source, examples and so on. Hope that somebody who can read the Hungarian language could please sort out all the most updates useful stuff from there to be archived here too.



Back to topReply to this topic


Copyright © Plus/4 World Team, 2001-2024