Shop OBEX P1 Docs P2 Docs Learn Events
SID´s adventure in P2 land - Page 3 — Parallax Forums

SID´s adventure in P2 land

13»

Comments

  • pik33pik33 Posts: 2,352
    edited 2021-02-07 16:00

    The difference is: counters counts 4x slower so you have to multiply frequency registers by 4 to get the same output. Filter coefficients have to be adjusted, too.

    The summary: you have less precise frequency setting and you have more aliases.

    At 250 kHz, where the Nyquist frequency is 125 kHz there should be very few aliases heard and the audio quality should be much better than P1 SIDCog. The output should be "near real thing"

    The best option is to run SIDCog at the frequency which is original SID frequency divided by power of 2: 2,4,8 etc; the computation are simpler. There is of course possibility to run SIDcog at any frequency (I did 44.1 kHz version for my P1V retromachine)

    Maybe some optimalization can enable SIDCog run at 480 kHz? Or... a full speed? 300 MHz P2 should be enough for this. I will try what I can as soon as I have the board. Maybe this week. The SIDcog is THE program which makes me to be interested in, and use, Propellers :)

    I have a SIDCog inspired SID emulator written for RPi in ARM asm: it runs at near full SID speed (960 kHz) and uses about 30% of RPi3 core. I tried this also at 480 kHz: the sound quality was, maybe, slightly lower, maybe not...

  • Ahle2Ahle2 Posts: 1,178

    @pik33,

    Thanks for the love! :smile: AND the excellent answer to hinvs question. This version of SIDcog was a hack to learn how to code P2 pasm and to begin my journey to learn the unique features of the P2. (what a wonderful thing Chip has made... I love it!) Just like you, I am also very excited about emulating SID chips on the P2 and will push that in the Crescendo project. As stated some posts ago, SIDcog, AYcog and SNEcog will not be made as single emulators on the P2 like they were on the P1. Crescendo will have them all (plus more) in a single core object. If you configure Crescendo to only emulate a single SID chip, it will perform equally well compared to an optimized SIDcog implementation on the P2. I have it all figured out in my head and have started coding on it. I do have more important things to do for Parallax first and my time is a little bit limited, but in the end you will have something to play with that will beat the heck out of SIDcog on the P1; There were shortcuts made on the P1 to make it have features that was hard to emulate with the instruction set, MIPS in a single cog and the hard limit to never go below 30,78125 kHz for okayish sound quality. The P2 is a totally different animal and I have not even begun to really optimize the SID emulator hard on the P2 yet. You can play around with this SIDcog hack for the time being to have something at all, but now that Crescendo is in the works and will be were things really takes off.

    Btw, I will not persue Retronitus on the P2 either, Wuerfel21 will probably continue the development when she gets her P2. And to be honest I couldn't be happier than to have her doing it. She has made some amazing things on the P1! :smile:

    Moderators... please lock this thread and make a link to the Crescendo project for further discussions there. :smiley:

    /Johannes

  • pik33pik33 Posts: 2,352
    edited 2021-02-08 15:06

    I got the board! At last. Time to start tinkering. I have an idea of several objects... now the free time, or rather lack of. can ba a factor: I have a lot too much to do for my job now.

    Edit: cannot get SIDCog 1.4 working at pins 6,7... either silence or a constant frequency... A headphone demo works.

    Much to learn now....

    Edit: It works when compiled using flexspin. It doesn't work while compiled by Propeller Tool

Sign In or Register to comment.