There is a nice tool with full java sources which enables C like flow constructs in your ASM sources. Unfortunately AVR is not yet supported, but according to what I saw adding new processors is just a matter of extending existing XML file 8). This is how high level C constructs can look in ASM source:
// C form if( A==2 ) { ; Expression Code ; This is the PASS Code Block } else { ; This is the ELSE Code Block } ; Assembly form START: ; Insert A==2 Expression Code Here PASS: ; Insert PASS Code Block Here JMP OUT FAIL: ; Insert ELSE Code Block Here OUT:
// C form do { ; This is the PASS Code Block } while( A==2 ) ; Expression Code ; Assembly form START: PASS: ; Insert PASS Code Block Here ; Insert A==2 Expression Code Here FAIL: OUT:
// C form while( A==2 ) { ; Expression Code ; This is the PASS Code Block } ; Assembly form START: ; Insert A==2 Expression Code Here PASS: ; Insert PASS Code Block Here JMP START FAIL: OUT:
http://computerarcheology.com/bl...
http://computerarcheology.com/bl...
Call it like this:
java -classpath . Blend GAP.ASM GAPLOLEV.ASM
Just imagine this as a preprocessor extension for AVR Studio...