firewhale
Junior Member level 1
- Joined
- Oct 14, 2012
- Messages
- 19
- Helped
- 0
- Reputation
- 0
- Reaction score
- 0
- Trophy points
- 1,281
- Activity points
- 1,398
i have a big problem when using array
the array works until my array is 4
but after i add 5th number, avr started joking....
the program very easy & problem seems very old
& ex:when i remove 5th value, array restore correctly
with or without PROGMEM program not change
the array works until my array is 4
but after i add 5th number, avr started joking....
the program very easy & problem seems very old
Code C - [expand] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 #include <avr/io.h> #include <avr/delay.h> #include <avr/pgmspace.h> int main(void) { uint8_t i = 0; const uint8_t j[] = { 0x00,0x01,0x02,0x03,0x04, }; DDRB = 0xff; PORTB = 0x00; for(i=0;i<4;i++) { PORTB=j[i]; _delay_ms(500); } }
& ex:when i remove 5th value, array restore correctly
with or without PROGMEM program not change
Last edited by a moderator: