I got a piece of hardware using the FV-1 that has 3 different programs where the only difference i a single coefficient in the code between the 3.
So my question ; is it possible to use something like a macro so I only have to have one source code that results in 3 programs - but only one code to maintain ?
Coding with macroes ?
Moderator: frank
SpinASM does not have a macro processor built in so for simple things like a coefficient you should be able to use an EQU statement like:
coeff EQU 0.5 ; version 1 code
; coeff EQU 0.6 ; version 2 code
; coeff EQU 0.7 ; version 3 code
later in the code you could use the value of coeff like:
sof coeff, 0.5
So you would just uncomment the desired coefficient and comment out the other two.
coeff EQU 0.5 ; version 1 code
; coeff EQU 0.6 ; version 2 code
; coeff EQU 0.7 ; version 3 code
later in the code you could use the value of coeff like:
sof coeff, 0.5
So you would just uncomment the desired coefficient and comment out the other two.
Frank Thomson
Experimental Noize
Experimental Noize
-
- Posts: 13
- Joined: Wed Sep 27, 2017 8:31 am