Page 2 of 2

Posted: Sun Apr 28, 2013 5:09 pm
by frank
There seem to be 2 problems, one in your code and one in SpinAsm:

You have "SKP 10,4" but 10 is a decimal, not hex it should be $10 for a bit mask of %10000

BUT SpinAsm seems to not be accepting hex or binary bit masks properly for the SKP instruction for the flags so change to coding in symbolic like "SKP RUN,4"

Posted: Sun Apr 28, 2013 5:26 pm
by Digital Larry
Thanks Frank, it turns out there was a format control string in the code generation section that was set to output hex instead of decimal. So I output it as 16 base 10 for now.

It would be more clear to use the mnemonics as you suggest, although it's not really my intention to comment the SpinASM!

Posted: Sun Apr 28, 2013 5:40 pm
by frank
16 is the correct decimal value but SpinAsm won't assemble decimal properly in the skp instruction so anyone copying the code and assembling in SpinAsm will still get bad code.

To assemble the skp instruction properly in SpinAsm you must use the flag symbols and not any sort of binary/hex/decimal value.

SKP RUN,4 will assemble as: 80800011 <<< correct
SKP 16,4 will assemble as: 00800011 <<< incorrect
Using $10 or %10000 will also result in an incorrect assembly.

Posted: Sun Apr 28, 2013 5:47 pm
by Digital Larry
I hear and obey!

Thanks Frank.

Posted: Mon Apr 29, 2013 12:22 am
by slacker
Do you have a list of showing what registers and things the numeric values map to. This would help people understanding and debugging your code.

Posted: Mon Apr 29, 2013 3:54 am
by Digital Larry
Well the way that SpinCAD works is that you just draw the picture and it spits out the ASM code. Registers and memory are allocated automatically. By the time I dig deep enough to trace what's what and where's where I've usually (as in this case) figured out the problem.

But if I have some issue again like this I'll give it a try because I know that looking at uncommented code is pretty ridiculous! I could have the program insert some comments that at least separate the functional blocks.

Posted: Mon Apr 29, 2013 5:56 am
by slacker
Ok, that makes sense for the general registers and memory.
Do the pots, adcs and dacs get assigned random numbers or are they always the same?

Posted: Mon Apr 29, 2013 6:43 am
by frank
slacker wrote:Do you have a list of showing what registers and things the numeric values map to. This would help people understanding and debugging your code.

See the last few pages of the SpinAsm pdf for that info http://www.spinsemi.com/Products/datash ... Manual.pdf

Posted: Mon Apr 29, 2013 6:49 am
by Digital Larry
slacker wrote:Ok, that makes sense for the general registers and memory.
Do the pots, adcs and dacs get assigned random numbers or are they always the same?
Oh I see what you mean. I've been working in the engine room a little too long.

POT0 = 16
POT1 = 17
POT2 = 18

ADCL = 20
ADCR = 21
DACL = 22
DACR = 23

Posted: Mon Apr 29, 2013 6:54 am
by slacker
Thanks chaps, that's just what I was after, should have known it would be in the docs somewhere.

Code works a treat now, sounds very nice.

Posted: Mon Apr 29, 2013 10:06 am
by frank
Update to my earlier comments, seems a hex value will work in the skp instruction but it must be the full 32-bits like:

skp $80000000,4 ; $80000000 is a RUN flag

Decimal will still not work, must be hex.

Posted: Wed May 08, 2013 8:39 am
by phaseman
Hi everyone!
this is my first post, but I've been reading A LOT :) of threads, examples, Knowledge Base stuff.... Also, I've tried almost every algorithm on the forum :)

I am amazed with FV1, it has changed the way I use and treat guitar effects.

Anyway, I am new to dsp, and I've started learning SpinAsm assembler few mounths a go...

I have a question about the revers reverb algorithm:
How can one subtract the original signal from that program? How can I make it wet only?

I must say I did try some ideas but with no success...


Regards,
Marko

Posted: Wed May 08, 2013 9:26 am
by frank
Hi Marko, please do not introduce new topics in an existing thread, please start a new thread for your topic.

But, to answer your question, it may not be possible to remove the wet signal, a reverse reverb works very different and it depends on how you coded it. Please start a new thread and post your code there and I'll take a look at it.