[sdiy] Some Audio DSP prototypes
igg.debus at gmail.com
Wed Apr 20 14:00:08 CEST 2022
> Am 20.04.2022 um 10:50 schrieb rburnett at richieburnett.co.uk:
> For nearly 30 years I've programmed PICs in assembly language for both hobby projects and commercial work. To be honest I don't see how you could program most of the low-end parts in any other way. In some cases they only have a handful of bytes of RAM and less than 1K of program space, so I can't see them being much use in any sort of higher level language.
On my day job, I had written programs for the 8051 (only 256 bytes of RAM! Certainly not more powerful than a PIC) in C for many years. In fact, C can be easier on RAM than assembly language, since in assembly there’s no such thing as local variables.
And regarding program memory usage: in the beginning I tried to outsmart the compiler (counting a loop counter down rather than up), hoping the compiler would use the DJNZ instruction. DJNZ (decrement and jump if not zero) is a powerful 8051 instruction for creating loops. Then I looked at the code the compiler had created: no DJNZ in there. Looking closer I found that the compiler’s solution was shorter and faster than the one I had in mind.
Look at Arduino: tons of programs for the low-end 8 bit AVR, all written in C++. I really don’t get it why the PIC guys stick to assembly language.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Synth-diy