Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Composing > problematic playback od GT multispeeds
2014-07-21 11:45
Jammer

Registered: Nov 2002
Posts: 1292
problematic playback od GT multispeeds

I'm not sure how problems and hickups are common for playback on real machine but considerable number of my works usually sounds broken, especially those ones composed with the latest GT release. What's the culprit here? Are GT compilations that cycle sensitive or what? :) During the release of Club Stylier and a few other multis I was forced to create false SID address working as a buffer and then copy values to proper registers but it's really unwanted workaround. Any clues?
2014-07-21 11:54
algorithm

Registered: May 2002
Posts: 702
I had a similar issue with some of the tracks that i composed for the Eclectic Demo. There was a noticeable difference between goattracker and Winvice/Real c64. Perhaps they are based on different resid revisions/filter curves? Or that the method of writing to sid registers are different for the realtime playback in the editor in comparison to the compiled sid data?
2014-07-21 11:59
Jammer

Registered: Nov 2002
Posts: 1292
I don't mean filters or wave sounds. Mostly problems with hardrestart time, wrong attacks, wrong gate etc. Sounds like problems with buffering or so.
2014-07-21 12:26
algorithm

Registered: May 2002
Posts: 702
This was also another difference (Hard restart and adsr) Which i believe may be perhaps due to writes to emulated sid differing in editor in comparison with compiled sid tune or/and resid version difference
2014-07-21 12:33
iAN CooG

Registered: May 2002
Posts: 3137
writing sid regs in different order give different results.
goattracker at every $1003 call executes this code 3 times, with X=0/7/E
13AA  9D E4 13  STA $13E4,X
13AD  BD FA 13  LDA $13FA,X
13B0  3D 11 14  AND $1411,X
13B3  9D 04 80  STA $D404,X
13B6  BD 23 14  LDA $1423,X
13B9  9D 00 80  STA $D400,X
13BC  BD 24 14  LDA $1424,X
13BF  9D 01 80  STA $D401,X
13C2  BD 25 14  LDA $1425,X
13C5  9D 02 80  STA $D402,X
13C8  BD 26 14  LDA $1426,X
13CB  9D 03 80  STA $D403,X
13CE  BD 35 14  LDA $1435,X
13D1  9D 05 80  STA $D405,X
13D4  BD 36 14  LDA $1436,X
13D7  9D 06 80  STA $D406,X
13DA  60        RTS 

not counting $d415/16/17/18 set at different times;
While a buffered sid write copies backward the buffer to sidregs.
08A2  A2 18     LDX #$18
08A4  BD 00 80  LDA $8000,X
08A7  9D 00 D4  STA $D400,X
08AA  CA        DEX 
08AB  10 F7     BPL $08A4

If GoatTracker editor always uses buffered playback then ALL GT tunes should play wrong/different.
2014-07-21 14:21
chatGPZ

Registered: Dec 2001
Posts: 11147
its even mentioned in the docs iirc =P
2014-07-21 15:14
Jammer

Registered: Nov 2002
Posts: 1292
Well, I have no intention in reading code part of docs and prefer leave it for coders :P The more interesting part is - can this unpredictable behaviour be fixed and will Lasse do this? ;)
2014-07-21 17:20
chatGPZ

Registered: Dec 2001
Posts: 11147
the solution is to always use buffered writes. i am sure one of your groupmates can knock up the code for it :=P
2014-07-21 20:00
Jammer

Registered: Nov 2002
Posts: 1292
I always do but the results are as I've described nonetheless :/
2014-07-22 03:43
Soren

Registered: Dec 2001
Posts: 547
d406,d405,d404 (and for the other voices aswell)
Use that order and things ought to be as good as they can get.
Furthermore it's a good idea to empty the sid buffer into sid registers as the FIRST thing in music/sound routines.
2014-07-22 05:20
Hein

Registered: Apr 2004
Posts: 933
I suppose the C64 playback should also be using stable rasters and without badlines, so no accidental delays occur during playback.
2014-07-22 08:21
Conrad

Registered: Nov 2006
Posts: 837
It may not matter that much to you, but I took a bit of time to make recordings from real C64 to provide comparisons. (Recorded on a Tascam DR-60 recorder)
Sorry that they're .wav files, I don't have time to encode them.

----------------------------------------------------
https://www.dropbox.com/s/civxe3fwejcy2o9/Club%20Sylier_Compo%2..
This is recorded from the compo entry at Forever 2010 (Club Stylier)

----------------------------------------------------
https://www.dropbox.com/s/r7412oyxeuiwgra/Club%20Stylier_My%20p..
This is a recording of my own player code, where the GT music routine writes to ghost registers (I hacked it ;)) and then at each call, the contents of the ghost registers are written to the SID registers FIRST before it JSR's $1003. The SID register writing order is done this way:
PULSE LO 1,
PULSE HI 1,
SUSTAIN/RELEASE 1,
ATTACK/DECAY 1,
FREQ LO 1,
FREQ HI 1,
WAVE CONTROL 1,
PULSE LO 2,
PULSE HI 2,
SUSTAIN/RELEASE 2,
ATTACK/DECAY 2,
FREQ LO 2,
FREQ HI 2,
WAVE CONTROL 2,
PULSE LO 3,
PULSE HI 3,
SUSTAIN/RELEASE 3,
ATTACK/DECAY 3,
FREQ LO 3,
FREQ HI 3,
WAVE CONTROL 3,
$d416,
$d417,
$d418

On a PAL machine there are 312 raster lines, which I assume is how GoatTracker divides the positions for calling the play routine, therefore I did the same... Raster positions in my player are: $10, $5e, $ac, $fa Screen is also turned off and black , so no bad lines and minimal background noise.

----------------------------------------------------
and finally...
https://www.dropbox.com/s/zsvm0wmlzkx55w6/Club%20Sylier_1541u%2..
This is a recording from the tune played from my HVSC directory in the 1541 ultimate SID player


As far as HR bugs is concerned, I couldn't hear any big differences between my player and the player used for the original compo entry, but the one played in the 1541u SID player does sound bad indeed. Didn't bother recording the Riverwash 6 invite code. ;)
2014-07-22 08:37
iAN CooG

Registered: May 2002
Posts: 3137
https://www.dropbox.com/s/siobwu4dpjv67z7/Club_Stylier_buffered..
now i've ripped it with buffered writes, the sid in HVSC was added as it was and it's not using buffered writes.
try if this is better and if so will be replaced in next update.
2014-07-22 09:32
Jammer

Registered: Nov 2002
Posts: 1292
Thanks guys a lot!

Conrad, compo entry used my additional routine with buffer and playback was correct. Original buffered writes from GT's compiler didn't work (at least in Vice). But its a heck of unnecessary work as I had to use false sid address in GT and copy registers in compo player routine and everyone would have to do the same in his prod. Version with your player cuts stabs to early thus I guess hardrestart is too long or sth.

It's almost a general rule that my tunes play correctly in SidPlay but have problems in prods - singlespeeds as well (VN#55 intro).

I guess it's mostly up to Cadaver to correct things suggested here in his compiler. Hopefuly, he will as everything's just been given on a silver platter. You guys are really helpful.
2014-07-22 10:48
cadaver

Registered: Feb 2002
Posts: 1154
The buffering in GT has historically been per-channel (at the end of channel execution) to work better with sound effect playback. Obviously it's not enough for demanding tunes like multispeeds, as channel execution will take varying time.

Maybe I'll do a final update where the buffering happens right at the beginning of the play call, in a simple loop.

Which way you do run your copy loop from the fake regs?
2014-07-22 11:55
Jammer

Registered: Nov 2002
Posts: 1292
irq1:  	
			asl $d019
			lda #0
			sta $d020
			ldx #$18
loop1: 
			lda virtual_sid,x
			sta $d400,x
			dex
			bpl loop1
			jsr $1003 // play music
			lda #<irq2
			sta $0314
			lda #>irq2
			sta $0315
			lda #$6c
			sta $d012
			pla
			tay
			pla
			tax
			pla
			rti


That was my routine in each call but I'm not a coder and it was real hit/miss ;)
2014-07-22 12:18
cadaver

Registered: Feb 2002
Posts: 1154
Thanks. I figured it'd be reverse so that it gets the wave/ADSR write timing mostly similar.
2014-07-22 13:13
cadaver

Registered: Feb 2002
Posts: 1154
Here's a preview version of the updated GT, I'd appreciate testing. There's a new relocator option (at the bottom) that will enable the full buffering mode.

http://cadaver.homeftp.net/tools/gt273preview.zip
2014-07-22 13:26
Jammer

Registered: Nov 2002
Posts: 1292
libwinpthread-1.dll is missing ;)
2014-07-22 13:29
cadaver

Registered: Feb 2002
Posts: 1154
Seems I have to update the makefile to link everything statically. Hold on, new version should appear shortly..
2014-07-22 13:34
Jammer

Registered: Nov 2002
Posts: 1292
Ok, I've just downloaded dll myself ;) Testing with 16x multispeeds :D
2014-07-22 13:37
cadaver

Registered: Feb 2002
Posts: 1154
I recommend to redownload the zip now, as it contains also slightly updated editor code: the editor is now permanently locked to the "full buffered" mode SID write timing, as that's basically the only timing it can emulate 100% exactly without running a C64 CPU :)
2014-07-22 13:55
Jammer

Registered: Nov 2002
Posts: 1292
One more thing. Is this 'vinyl crack' in editor normal? The higher speed the more audible it appears. Right after this update cracks become really frequent ;)

edit: I see that GT has really hard time with buffer under 50s, hence the cracks ;)

Right. After the update, GT now behaves more like SidPlay - sometimes strange gates occur between sounds in 16x tunes like in the compiled ones. No problems with 4x.

Couple of tests:

- Dancing Girls 4x SNG
- Dancing Girls 4x SID
- First 16x SNG
- First 16x SID
- Second 16x SNG
- Second 16x SID

Two 16x are problematic by definition seemingly, the 4x tune was one of the most troublesome before the update and sounded really random in SidPlay.
2014-07-22 16:12
cadaver

Registered: Feb 2002
Posts: 1154
Now the editor & compiled playback (with full buffering) should be as close to each other as possible, so if something doesn't work at a particular speed, then the only advice remaining is: don't do it, or use different ADSR settings etc.
2014-07-22 17:16
Linus

Registered: Jun 2004
Posts: 639
OSX port where are thou?
2014-07-22 18:50
Conrad

Registered: Nov 2006
Posts: 837
@cadaver, thanks for adding the buffer option. Will be quite useful. :)

@Jammer, Dancing Girls... Very nice cover! :D
2014-07-22 19:19
Mr. SID

Registered: Jan 2003
Posts: 422
Quote: OSX port where are thou?

I'll have a go at it when I get back home from vacation... No promises though...
2014-07-23 10:45
Linus

Registered: Jun 2004
Posts: 639
Great, thank you!
2014-07-23 13:56
Linus

Registered: Jun 2004
Posts: 639
@Jammer:

Dancing Girls is _very_ nice indeed!

Going beyond 8x in GT doesn't make much sense for me tho as I usually encounter more disadvantages than advantages (wavetable lenght, slow pulse- and filtersweeps and what not). I certainly do love the snare in your second attempt, nontheless.
2014-07-23 21:24
cadaver

Registered: Feb 2002
Posts: 1154
GT2.73 has been released at http://cadaver.homeftp.net/tools/goattrk2.zip and SourceForge; the preview version above has been removed.
2014-07-23 22:22
Jammer

Registered: Nov 2002
Posts: 1292
Hey, 16x tunes have more regular playback. How did you pull that off? ;)

I'm experimenting with hardrestart set to F000/FF00. Sounds promising.
2014-07-23 23:08
Jammer

Registered: Nov 2002
Posts: 1292
- HR Test SNG
- HR Test SID

A little test in single speed with high tempo. Instrument Attack 01 is useful for the first time I suppose, also in multispeeds ;) Try to experiment with editor hardrestart Attack and Decay for the best results. I stick to FF00 at the moment and instruments gained more pleasant and less gated restart. Thanks to this, instrument HR time can be shortened at least one frame in many cases which results in better clicks. I've managed to cut it to 07 in 4x and from 20 to 1C in 16x. Mind that short instrument Release makes fast, non legato passages broken.

I strongly recommend redownloading my tests in order to catch the difference - playback became almost error-free and clicky in a good way. One thing that bothers me is little slowdown in First 16x test - too CPU extensive due to full SID buffer in each call?

Another 16x test also revealed slowdowns in compiled sid:

- Clicky Drums 16x SNG
- Clicky Drums 16x SID
2014-07-24 03:36
Soren

Registered: Dec 2001
Posts: 547
Hard restart! Oh Noes! /o\
:D
I keep moving further and further away from using HR. I just find that in many cases it cuts too much sound between notes and gets to sound a bit too stiff.
Ofcourse it's good for some things... I know..
:)
2014-07-24 10:13
Linus

Registered: Jun 2004
Posts: 639
http://www.zeidnetz.de/ExtraDrums_16x-3.sid

@Jammer: I added some base ;) In for a coop?
2014-07-24 10:29
Jammer

Registered: Nov 2002
Posts: 1292
Linus, my pleasure - it's splendid! :D

Soren: GT used to have no restart once and it was a big nono ;) You can disable HR in instrument anyway :P
2014-07-24 13:30
McMeatLoaf

Registered: Jan 2005
Posts: 106
Linus: Did you use the -g command to change the center pitch? The tuning sounds a bit higher than the usual 440 hz.
2014-07-24 14:40
Jammer

Registered: Nov 2002
Posts: 1292
McMeatLoaf: I don't think so. In 16x multispeeds arpeggios can work so quickly that you get a one welded tone together with aliquotes. That's one of the tricks for multispeed instruments - in wavetable you put e.g. base pitch and two semitones up in loop, you get one semitone up as a result but its perceived finetune relies also on waveform, pulse width, filtering etc.
2014-07-24 18:19
Linus

Registered: Jun 2004
Posts: 639
What Jammer said :)
2014-07-24 19:19
Soren

Registered: Dec 2001
Posts: 547
Jammer: Either something was not good enough in no-hardrestart GT, OR it was the people using it. :D
When using sid buffers, and doing that well, no hard restart is quite neat. But ofcourse still tricky to play with.
2014-07-24 19:39
Linus

Registered: Jun 2004
Posts: 639
Thanks to Soren I started abandoning HR from my lead instruments a while ago and they really benefit from it.
2014-07-24 20:43
Jammer

Registered: Nov 2002
Posts: 1292
Well, I prefer setting Attack to 1 or 2. The same effect in GT, no messing with HR ;)
2014-07-24 21:23
cadaver

Registered: Feb 2002
Posts: 1154
By using low but non-zero attack you're basically asking for maximum trouble :) At low values the SID's internal ADSR counter is wrapping around in a fast loop (10-20 cycles if I remember right) and in that case, if the SID writes to trigger the note come late, the attack is messed up & delayed.
2014-07-24 21:29
Jammer

Registered: Nov 2002
Posts: 1292
Well, that is basis for my multispeed instruments ;)

I've just tried changing instruments in Dancing Girls to Attack 0 and no HR but it's one utter mess. Are you really sure about it? ;)
2014-07-24 21:47
FATFrost
Account closed

Registered: Sep 2003
Posts: 211
I had this problem too... In the editor the time sounds like jeff/jammer/Linus/Hubbard,, when I export... Sounds like shizz... Oh... That's my skills?! :/
2014-07-24 21:48
FATFrost
Account closed

Registered: Sep 2003
Posts: 211
Forgot I'm just a scabby old pixel tramp.. :)
2014-07-25 09:21
Linus

Registered: Jun 2004
Posts: 639
Quote: Well, I prefer setting Attack to 1 or 2. The same effect in GT, no messing with HR ;)

That is _far_ from the same effect, dude! :)

Anyway, regarding low non-zero attack values in multispeed tunes, I can only agree with Cadaver - the attack gets unpredictable.

You could try changing the attack settings in your "Dancing Girls" track to '0' and add an '$E9' at the beginning of your wavetable instead. That was the basis for my multispeed instruments a couple of years ago.
2014-07-25 10:42
Jammer

Registered: Nov 2002
Posts: 1292
Interesting. What's your current basis, then? :)

I've just tried this way and it sounds like shit. Instrument beginnings are being eaten. Maybe some SNG? I'm too dumb for this, apparently :D
2014-07-25 15:34
Linus

Registered: Jun 2004
Posts: 639
My current basis is "50hz is enough for everybody" :)
2014-07-25 17:14
Jammer

Registered: Nov 2002
Posts: 1292
Somehow, I expected that :P
2014-07-25 19:19
Mixer

Registered: Apr 2008
Posts: 422
Quote: My current basis is "50hz is enough for everybody" :)

Applause, if the pun is intended :D
2014-07-26 06:55
Linus

Registered: Jun 2004
Posts: 639
Yours truly takes a bow!
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Ninja/The Dreams
Hani
Operator Teleksu
Sentinel/Excess/TREX
Hagar/The Supply Team
mutetus/Ald ^ Ons
tlr
Didi/Laxity
Mythus/Delysid
Mihai
Linus/MSL
Jetboy/Elysium
Guests online: 115
Top Demos
1 Next Level  (9.8)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.7)
5 Edge of Disgrace  (9.6)
6 Comaland 100%  (9.6)
7 Uncensored  (9.6)
8 No Bounds  (9.6)
9 50 Years of Flex  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 Layers  (9.6)
2 It's More Fun to Com..  (9.6)
3 Cubic Dream  (9.6)
4 Party Elk 2  (9.6)
5 Copper Booze  (9.6)
6 TRSAC, Gabber & Pebe..  (9.5)
7 Rainbow Connection  (9.5)
8 Dawnfall V1.1  (9.5)
9 Quadrants  (9.5)
10 Daah, Those Acid Pil..  (9.5)
Top Groups
1 Oxyron  (9.3)
2 Booze Design  (9.3)
3 Censor Design  (9.3)
4 Crest  (9.3)
5 Performers  (9.3)
Top NTSC-Fixers
1 Pudwerx  (10)
2 Booze  (9.7)
3 Stormbringer  (9.7)
4 Fungus  (9.6)
5 Grim Reaper  (9.3)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.099 sec.