What is Arkos Tracker? › Forums › Arkos Tracker forum › Bug reports › [Doc updated] Weird noise artefacts appearing
- This topic has 14 replies, 2 voices, and was last updated 5 years, 2 months ago by Targhan.
-
AuthorPosts
-
September 12, 2019 at 8:57 pm #29864robpearmainParticipant
It could be one of a hundred things, but I have a simple two channel song playing in my game which loops.
I am using a ZX spectrum 128k both emulated and real. On the third channel I play sound effects.
After a while when the music has looped 10 or so times, I start to get weird noise artefacts appearing on the sound channel.
Do I need to stop the sound on a channel before playing a new one, or is there anything else you could recommend.
As I say, it could be one of a hundred things, but it seems like the song, or channel is getting corrupted over time.
I am using the minimal player
September 13, 2019 at 7:32 am #29865TarghanKeymasterNo idea what the problem could be. There is no need to stop a sfx before playing a new one. To eliminate all possible side-effects, could you first make a try with only the test sample of the package? If the problem still occurs I can investigate if you send me the music and sound effects.
September 13, 2019 at 3:50 pm #29866robpearmainParticipantHi
I have created a video of the issue (Starts about 3 minutes in to it)
I will send you the source code once I find somewhere to share it (I will edit this post)
Essentially, the demo program plays a simple 2 channel tune. Pressing the ‘1’ key fires off 6 FX (Channel 3) in rotation. After a while, a background click starts to appear.
I have tested again in my game, and if you do not play an FX the music repeats with no issue. However, if you play an FX, after the same time, approx 3 mins the background noise appears.
I wonder if it is due to no music playing on the 3rd channel or if the FX is corrupt somehow.
It seems to be after the music has repeated 16 times or more
Here is a video of my game and the error (About 2 mins 40 in to the video)
In Game Sound IssuesSeptember 13, 2019 at 3:58 pm #29867robpearmainParticipantHi
Link to the source code is here (And a tap file)
To compile to TAP
pasmo –tapbas musictst.asm musictst.tap
September 13, 2019 at 6:16 pm #29868TarghanKeymasterOk, received. I’ll check that as soon as I can. Thanks for all the info!
September 13, 2019 at 6:29 pm #29869robpearmainParticipantExcellent
Arkos Tracker is so good, and I really appreciate all the effort you put in to it! If you need any more information or testing, please ask
Rob
September 13, 2019 at 6:42 pm #29870TarghanKeymasterI don’t reproduce this on CPC… I suspect your Pasmo-generated code. You used Disark to generate your code, right?
September 13, 2019 at 6:55 pm #29871TarghanKeymasterDo you think it would be difficult to you NOT to use Pasmo, but only Rasm, only a test (so, no Disark)? If yes, don’t bother.
It’s just that it’s not easy for me to debug on other system than CPC, I don’t have the tools.September 13, 2019 at 8:59 pm #29872robpearmainParticipantYes, I used Disark to produce the pasmo code
I will test just using Rasm as you suggest and get back to you with my results ASAP
Thanks
Rob
September 13, 2019 at 10:52 pm #29873TarghanKeymasterOk, found the problem (didn’t find the reason, but it’s related to Disark). It’s late so I’m going to invest it tomorrow. But in pnpmusicpasmo.asm, line 228:
ld (PLY_AKM_TRACK1_PTINSTRUMENT),de
ld (1748),de
ld (1786),deThis is wrong of course. The PLY_AKM_TRACK2_PTINSTRUMENT and 3 are not well relocated (they are not declared). I’ll correct this as soon as possible. As a quick patch (I didn’t test it though!!)
ld (PLY_AKM_TRACK1_PTINSTRUMENT),de
ld (PLY_AKM_TRACK2_DATA + 10),de
ld (PLY_AKM_TRACK3_DATA + 10),deBasically, it has nothing to do with the sound effect. Or another even quicker patch, you could simply add a RST sound (or any silent instrument) on the 3 channel, and you’re done! 🙂
September 14, 2019 at 8:12 am #29876TarghanKeymasterOk, found the problem in the player. This is only a Disark problem. from the lines 228, simply add these two labels. Disark will know what to do with them :).
ld (PLY_AKM_Track1_PtInstrument),de
DisarkForceReferenceDuring3_PtInstrumentTrack2:
ld (PLY_AKM_Track2_PtInstrument),de
DisarkForceReferenceDuring3_PtInstrumentTrack3:
ld (PLY_AKM_Track3_PtInstrument),deI won’t make a new release for this though, unless I find other problems in the other players. My only gripe is that my test units should have found this kind of problem! I will have to check that.
Thanks a lot for the report!September 14, 2019 at 9:10 am #29879TarghanKeymasterOk, good news! It is not a bug :).
But the RASM command line is actually wrong:
rasm PlayerAndMusic.asm -o PlayerAndMusic -s -sl
It should be:
rasm PlayerAndMusic.asm -o PlayerAndMusic -s -sl -sq
Some labels were not exported. Which is why my test units couldn’t reproduce the bug, because the integrated version I use automatically export ALL the labels.
So don’t modify the .asm file like I told you before, simply update the RASM call. Tell me if it works for you!
I’ve updated the documentation accordingly.
September 14, 2019 at 10:38 am #29881robpearmainParticipantHi Julien
Tested, and all working
So the issue was rasm
-sq export also EQU symbol
Thanks for hunting this down,
Best Regards
Rob
September 14, 2019 at 10:41 am #29882robpearmainParticipantSeptember 14, 2019 at 10:51 am #29884TarghanKeymasterGood catch!! Updated. Thanks!
-
AuthorPosts
- You must be logged in to reply to this topic.