Arduino IDE is not happy with the ASM code.
fsr, I simply want to load the PPSDiv code to arduino. I think it works "out of the box" so I do not expect to have to modify it, I just want to get the code onto a 328p chip. I think there is a way to burn the hex file which is included. I recall burning the bootloader onto bare chips so I may review how I did that, so many years ago... But to take a step back, I don't really need this code, but any code that will do the same thing. I could also just order some pic chips and try the picdiv code, but I don't have those chips and I have plenty of Arduinos.
This is the ASM code I tried to compile in Arduino IDE.
#include <m32def.inc>
void setup(){
init:
LDI R16,0xFF
OUT DDRA,R16
CLR R15
CLR R14
CLR R13
CLR R12
CLR R11
CLR R10
CLR R9
CLR R8
void loop(){
LDI R16,0x0A
INC R15
CP R15,R16
BRNE nd1
CLR R15
nd1: BRNE nd1w
INC R14
nd1w: CP R14,R16
BRNE nd2
CLR R14
nd2: BRNE nd2w
INC R13
nd2w: CP R13,R16
BRNE nd3
CLR R13
nd3: BRNE nd3w
INC R12
nd3w: CP R12,R16
BRNE nd4
CLR R12
nd4: BRNE nd4w
INC R11
nd4w: CP R11,R16
BRNE nd5
CLR R11
nd5: BRNE nd5w
INC R10
nd5w: CP R10,R16
BRNE nd6
CLR R10
nd6: BRNE nd6w
INC R9
nd6w: CP R9,R16
BRNE cready
CLR R9
cready: CLT
BLD R8,0
OUT PORTA,R8
LDI R17,08
WLP0: DEC R17
BRNE WLP0
CLR R8
LDI R16,0x05
SET
BLD R8,0
CP R15,R16
BRCS d2
BLD R8,1
d2: CP R14,R16
BRCS d3
BLD R8,2
d3: CP R13,R16
BRCS d4
BLD R8,3
d4: CP R12,R16
BRCS d5
BLD R8,4
d5: CP R11,R16
BRCS d6
BLD R8,5
d6: CP R10,R16
BRCS d7
BLD R8,6
d7: CP R9,R16
BRCS ok
BLD R8,7
ok: OUT PORTA,R8
LDI R17,03
WLP1: DEC R17
BRNE WLP1
NOP
RJMP
}