DSP What is a program? (& Linux IDE?)
Posted: Tue Mar 10, 2020 7:56 am
Sorry new to DSP, but reading through the documentation this all seems pretty straight forward. One question however concerns what is a DSP Program. I'm coming from an embedded C background and a program running on a bare metal system will have an infinite process loop. If I didn't have that structure in the code, 'C' or assembly then the program counter would simply increment through the flash and overflow to 0x00000, in the fullness of time. (Yes I have made those kind of mistakes, and thought that's taking longer then I'd thought I'm making a few assumptions there but you know what I mean. Obviously if you're running on an OS the program would terminate.
From what I've read the FV-1 has a very limited RAM memory section for a 'program', think I read 128 Bytes, (can that be right?). The example source code in the application notes simply ends the source code/program with a comment! So for example the first code example in AN-0001 ends the 'program' with:
; That's it
Obviously I recognise what's intended, but what does the FV-1 do? Does it always simply execute ALL of the loaded instructions in RAM even if there's instructions there or not, (NOP)? There is no branching, I'm not even sure you can 'Skip' backwards to 'Start' so I can only assume you have a limited number of instructions in a program, (possibly 128), use them, or don't, they'll still be executed. Does the architecture rely on the Program Counter over flowing to 0x0000? I guess if I only used 28 bytes of a program I could possibly skip forward 100 bytes to speed things up and reduce latency?
Linux: - And finally I'm not much of an IDE user, if there was a command line assembler and emacs I'd be happy. The assembler is probably written in a high level language, so it can execute on Linux, but the IDE's GUI isn't going to be that simple. Not sure about the programming of EEPROM via USB. USB is 'Universal' so I guess a simple command line program could be used to communicate the Hex file to the dev board. 'spin_flash my_effect.hex'.
So I guess my work flow would be:
$ emacs my_effect.src
$ spin_asm my_effect.src -o my_effect.hex
$ spin_flash my_effect.hex
Whilst none of that is rocket science, I guess there's not a lot of demand for that type of programming, so they don't exist. I'm sure I have a laptop with a windows partition so I'll get stuck into bad code presently.
From what I've read the FV-1 has a very limited RAM memory section for a 'program', think I read 128 Bytes, (can that be right?). The example source code in the application notes simply ends the source code/program with a comment! So for example the first code example in AN-0001 ends the 'program' with:
; That's it
Obviously I recognise what's intended, but what does the FV-1 do? Does it always simply execute ALL of the loaded instructions in RAM even if there's instructions there or not, (NOP)? There is no branching, I'm not even sure you can 'Skip' backwards to 'Start' so I can only assume you have a limited number of instructions in a program, (possibly 128), use them, or don't, they'll still be executed. Does the architecture rely on the Program Counter over flowing to 0x0000? I guess if I only used 28 bytes of a program I could possibly skip forward 100 bytes to speed things up and reduce latency?
Linux: - And finally I'm not much of an IDE user, if there was a command line assembler and emacs I'd be happy. The assembler is probably written in a high level language, so it can execute on Linux, but the IDE's GUI isn't going to be that simple. Not sure about the programming of EEPROM via USB. USB is 'Universal' so I guess a simple command line program could be used to communicate the Hex file to the dev board. 'spin_flash my_effect.hex'.
So I guess my work flow would be:
$ emacs my_effect.src
$ spin_asm my_effect.src -o my_effect.hex
$ spin_flash my_effect.hex
Whilst none of that is rocket science, I guess there's not a lot of demand for that type of programming, so they don't exist. I'm sure I have a laptop with a windows partition so I'll get stuck into bad code presently.