I have made changes - all looking very stable. However, the OS is not installing using AVRASM2 - which it needs to. I have seen this error many times. See https://1drv.ms/v/c/2f87ffe77f3dbec7/IQAOrLqgMBtbQpDpvzuaPqN8AboPJovzFVWEYUUdfKbs8-U?e=Jv8T5F
ok. No chip init. Agreed. What name for the constant? What should the prefix be for routines that must be compiled and included in the output? Other changes?
A demo - I have GCASM and AVRASM2 operating. Review the video - there are some questions I need answers to. Naming, restore the clear RAM routines, and many more questions. I have added ORG support ( this is cross platform so use .ORG or ORG the target chip determines the output ). Lots of capabilities - that did not exist two days ago. Enjoy https://1drv.ms/v/c/2f87ffe77f3dbec7/IQDLUFp2hwJVTp6zszCj2mTbARTDm7DRwb0yfLZA6z6cvgs?e=vrac0G
That is the goal. :-)
That is the goal. :-)
The rjmp is not a sub call. It is a short vector goto using 2 insructions. Where as a goto will use 3 instructions. The compiler will inspect all rjmp's and replace with goto if required ( greater than the scope of rjmp ). Please test the program change with a real interrupt handler call (not just reti). Does the interrupt handler appear in the assembly code? With this option active. The reti is replaced by the rjmp ISR, and sub ISR.. end Sub would need to defined. The assembler would issue an error...
Progress. One thing to resolve, and some decisions. Source #chip mega328p #option explicit #option UserCodeOnly INITMCU2: // Vectors - must come before the UserCodeOnly label ASM .ORG 2 ASM reti ;INT0 #ASMRAW .ORG 4 #ASMRAW reti ;INT1 #ASMRAW[ .ORG 6 reti ;PCINT0 .ORG 8 reti ;PCINT1 #ASMRAW] // The following .ORG statement can ONLY be ASM instriction NOT #ASMRAW as we need the preprocessor to repace the constant /* All these are now valid constants for the address above the interrupt vectors CHIPTOP_VECTOR_ADDRRESS...
Goto's just cannot be debugged. Real SIm shows the ADC correctly. Load the RPP project provided. Add lots of serial debug and I would use the real hardware with a USB/TTL. You can probable keep all the gotos but refactoring is really the way to figure out what is going on.