for my 16f1826 enhanced chip i get errors unless my array index variables are word sized variables. can anyone fix this because the word variables makes my code entirely too large to fit on my chip
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
dir PORTB.0 in
dir PORTB.1 out
iy = 0
i = 0
Start:
a0.i(iy) = portb.0
if portb.1 = 1 then ' for test purpose
portb.1 = 0
else
portb.1 = 1
end if
i = i + 1
if i > 7 then
i = 0
iy = iy + 1
if iy > 10 then
iy = 0
end if
end if
goto start
it gave me error.
Error: GCASM: Symbol IY_H has not been defined
With older chip like 16F877 it compiled it perfect
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
for my 16f1826 enhanced chip i get errors unless my array index variables are word sized variables. can anyone fix this because the word variables makes my code entirely too large to fit on my chip
same problem. Have you solve it?
Here is my code :
;Chip Settings
#chip 16F1827,20
#config FOSC_HS,WDTE_OFF
;Variables
Dim a0(10)
dir PORTB.0 in
dir PORTB.1 out
iy = 0
i = 0
Start:
a0.i(iy) = portb.0
if portb.1 = 1 then ' for test purpose
portb.1 = 0
else
portb.1 = 1
end if
i = i + 1
if i > 7 then
i = 0
iy = iy + 1
if iy > 10 then
iy = 0
end if
end if
goto start
it gave me error.
Error: GCASM: Symbol IY_H has not been defined
With older chip like 16F877 it compiled it perfect