I have been analysing the QBas Scan Matrix program that is written in ASM. I would like to modify it to incorporate changes due to velocity variations between black and white keys.
When reading about Assembler and C, I learned that it is sometimes more efficient to program in C and allow the compiler to compose the the ASM code. The article however, pointed out that C should not be used where interrupts were involved.
Looking at QBas 16 X 16 scan matrix I wonder whether there would be scope for writing in the program in C and including asm code where needed. (Using __asm “asm code” __endasm)
I would guess that the likely asm code would include would be the following.
Manipulations of clocks associated with Dout and Din.
Code such as the Function SM_VEL_Timer that uses FSR2 and IRQ_TMPx
Question Should I just use asm for sm_fast? or is there some scope for using asm within C?
I would appreciate any guidance.
Robin
