I have found an problem here

i am new in using arduino uno and I have face this problem I use the blinking code of led but it is not working well when I try to change the delay function and upload it , it gives me this error :

Sketch uses 924 bytes (2%) of program storage space. Maximum is 32256 bytes.
Global variables use 9 bytes (0%) of dynamic memory, leaving 2039 bytes for local variables. Maximum is 2048 bytes.
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x22
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x22
Failed uploading: uploading error: exit status 1
could anybody help me to find the solution

Did you set up the board type and port number correctly ?

1 Like

This error has nothing to do with your programing code, it is a problem with upload.

1 Like

Go into tools and select the AVR and UNO. I am not sure of the path as I do not know which IDE you are using.

Could you suggest a solution could help please to solve I have found that the problem in port or define the my laptop just provide power but not define the port correctly just come3,4

Provided you select in 'Tools' the correct Port: 'Com(number)', Board: 'UNO' and Programmer: 'Arduino as ISP' it should compile when clicking 'top left tick in a circle' and then load by clicking 'Right arrow in circle'. Provided you are using Windows it is always worth checking device manager to see Arduino Uno listed under ports. For reference I always use the following code for test, which produces a binary count on PORTB and slowly flashes the on-board LED attached to pin 13.

int cnt;

void setup() {
  DDRB = 0b00111111;
}

void loop() { 
  PORTB = cnt++;
  delay(100);
}

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.