How do I change the default LED pin for displaying uploading
Clash Royale CLAN TAG#URR8PPP
up vote
2
down vote
favorite
I made a board for my project based on Arduino Pro Mini. The problem is, that I had to put the LED on pin 4 instead of pin 13.
What setting do I have to change to make pin 4 the default one? Or do I have to write my own Board Library?
arduino-ide led
add a comment |Â
up vote
2
down vote
favorite
I made a board for my project based on Arduino Pro Mini. The problem is, that I had to put the LED on pin 4 instead of pin 13.
What setting do I have to change to make pin 4 the default one? Or do I have to write my own Board Library?
arduino-ide led
add a comment |Â
up vote
2
down vote
favorite
up vote
2
down vote
favorite
I made a board for my project based on Arduino Pro Mini. The problem is, that I had to put the LED on pin 4 instead of pin 13.
What setting do I have to change to make pin 4 the default one? Or do I have to write my own Board Library?
arduino-ide led
I made a board for my project based on Arduino Pro Mini. The problem is, that I had to put the LED on pin 4 instead of pin 13.
What setting do I have to change to make pin 4 the default one? Or do I have to write my own Board Library?
arduino-ide led
edited Aug 14 at 9:27
Greenonline
1,90941539
1,90941539
asked Aug 14 at 9:04
AntonÃn Gazda
133
133
add a comment |Â
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
3
down vote
accepted
The blinking while uploading makes the bootloader. Arduino Mini uses Optiboot. The source codes are on GitHub. You would need to change the pin in pin_defs.h and make the bootloader. Then flash it to the 328p with a programmer over ICSP.
Details what to change are in Greenonline's answer.
add a comment |Â
up vote
2
down vote
Following on from Juraj's answer:
The blinking while uploading makes the bootloader. Arduino Mini uses
Optiboot. The source codes are on GitHub. You would need to
change the pin in pin_defs.h and make the bootloader. Then flash it to
the 328p with a programmer over ICSP.
The line that you need to change in pin_defs.h
is line number 27:
#define LED B5
As you can see it is currently set to B5
. This is the fifth bit in port B which corresponds to pin 13
Pin 4 corresponds to PORTD
bit 4, so the line would become
#define LED D4
The Arduino digital pins are connected to three different banks of 8 bits, known as ports (PORTD
, PORTB
and PORTC`). To see their relation, refer to this table from Arduino Playground - Pins
I copied my answer as intro into this answer
â Juraj
Aug 14 at 12:15
Ok, thanks. I'm not sure it was necessary, unless you planned on deleting your answer. However, I've added a link back to yours to reference the quote, and it makes a bit more sense that way. Thanks again :-).
â Greenonline
Aug 14 at 13:56
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
accepted
The blinking while uploading makes the bootloader. Arduino Mini uses Optiboot. The source codes are on GitHub. You would need to change the pin in pin_defs.h and make the bootloader. Then flash it to the 328p with a programmer over ICSP.
Details what to change are in Greenonline's answer.
add a comment |Â
up vote
3
down vote
accepted
The blinking while uploading makes the bootloader. Arduino Mini uses Optiboot. The source codes are on GitHub. You would need to change the pin in pin_defs.h and make the bootloader. Then flash it to the 328p with a programmer over ICSP.
Details what to change are in Greenonline's answer.
add a comment |Â
up vote
3
down vote
accepted
up vote
3
down vote
accepted
The blinking while uploading makes the bootloader. Arduino Mini uses Optiboot. The source codes are on GitHub. You would need to change the pin in pin_defs.h and make the bootloader. Then flash it to the 328p with a programmer over ICSP.
Details what to change are in Greenonline's answer.
The blinking while uploading makes the bootloader. Arduino Mini uses Optiboot. The source codes are on GitHub. You would need to change the pin in pin_defs.h and make the bootloader. Then flash it to the 328p with a programmer over ICSP.
Details what to change are in Greenonline's answer.
edited Aug 14 at 13:54
Greenonline
1,90941539
1,90941539
answered Aug 14 at 9:23
Juraj
3,4211317
3,4211317
add a comment |Â
add a comment |Â
up vote
2
down vote
Following on from Juraj's answer:
The blinking while uploading makes the bootloader. Arduino Mini uses
Optiboot. The source codes are on GitHub. You would need to
change the pin in pin_defs.h and make the bootloader. Then flash it to
the 328p with a programmer over ICSP.
The line that you need to change in pin_defs.h
is line number 27:
#define LED B5
As you can see it is currently set to B5
. This is the fifth bit in port B which corresponds to pin 13
Pin 4 corresponds to PORTD
bit 4, so the line would become
#define LED D4
The Arduino digital pins are connected to three different banks of 8 bits, known as ports (PORTD
, PORTB
and PORTC`). To see their relation, refer to this table from Arduino Playground - Pins
I copied my answer as intro into this answer
â Juraj
Aug 14 at 12:15
Ok, thanks. I'm not sure it was necessary, unless you planned on deleting your answer. However, I've added a link back to yours to reference the quote, and it makes a bit more sense that way. Thanks again :-).
â Greenonline
Aug 14 at 13:56
add a comment |Â
up vote
2
down vote
Following on from Juraj's answer:
The blinking while uploading makes the bootloader. Arduino Mini uses
Optiboot. The source codes are on GitHub. You would need to
change the pin in pin_defs.h and make the bootloader. Then flash it to
the 328p with a programmer over ICSP.
The line that you need to change in pin_defs.h
is line number 27:
#define LED B5
As you can see it is currently set to B5
. This is the fifth bit in port B which corresponds to pin 13
Pin 4 corresponds to PORTD
bit 4, so the line would become
#define LED D4
The Arduino digital pins are connected to three different banks of 8 bits, known as ports (PORTD
, PORTB
and PORTC`). To see their relation, refer to this table from Arduino Playground - Pins
I copied my answer as intro into this answer
â Juraj
Aug 14 at 12:15
Ok, thanks. I'm not sure it was necessary, unless you planned on deleting your answer. However, I've added a link back to yours to reference the quote, and it makes a bit more sense that way. Thanks again :-).
â Greenonline
Aug 14 at 13:56
add a comment |Â
up vote
2
down vote
up vote
2
down vote
Following on from Juraj's answer:
The blinking while uploading makes the bootloader. Arduino Mini uses
Optiboot. The source codes are on GitHub. You would need to
change the pin in pin_defs.h and make the bootloader. Then flash it to
the 328p with a programmer over ICSP.
The line that you need to change in pin_defs.h
is line number 27:
#define LED B5
As you can see it is currently set to B5
. This is the fifth bit in port B which corresponds to pin 13
Pin 4 corresponds to PORTD
bit 4, so the line would become
#define LED D4
The Arduino digital pins are connected to three different banks of 8 bits, known as ports (PORTD
, PORTB
and PORTC`). To see their relation, refer to this table from Arduino Playground - Pins
Following on from Juraj's answer:
The blinking while uploading makes the bootloader. Arduino Mini uses
Optiboot. The source codes are on GitHub. You would need to
change the pin in pin_defs.h and make the bootloader. Then flash it to
the 328p with a programmer over ICSP.
The line that you need to change in pin_defs.h
is line number 27:
#define LED B5
As you can see it is currently set to B5
. This is the fifth bit in port B which corresponds to pin 13
Pin 4 corresponds to PORTD
bit 4, so the line would become
#define LED D4
The Arduino digital pins are connected to three different banks of 8 bits, known as ports (PORTD
, PORTB
and PORTC`). To see their relation, refer to this table from Arduino Playground - Pins
edited Aug 14 at 13:54
answered Aug 14 at 9:37
Greenonline
1,90941539
1,90941539
I copied my answer as intro into this answer
â Juraj
Aug 14 at 12:15
Ok, thanks. I'm not sure it was necessary, unless you planned on deleting your answer. However, I've added a link back to yours to reference the quote, and it makes a bit more sense that way. Thanks again :-).
â Greenonline
Aug 14 at 13:56
add a comment |Â
I copied my answer as intro into this answer
â Juraj
Aug 14 at 12:15
Ok, thanks. I'm not sure it was necessary, unless you planned on deleting your answer. However, I've added a link back to yours to reference the quote, and it makes a bit more sense that way. Thanks again :-).
â Greenonline
Aug 14 at 13:56
I copied my answer as intro into this answer
â Juraj
Aug 14 at 12:15
I copied my answer as intro into this answer
â Juraj
Aug 14 at 12:15
Ok, thanks. I'm not sure it was necessary, unless you planned on deleting your answer. However, I've added a link back to yours to reference the quote, and it makes a bit more sense that way. Thanks again :-).
â Greenonline
Aug 14 at 13:56
Ok, thanks. I'm not sure it was necessary, unless you planned on deleting your answer. However, I've added a link back to yours to reference the quote, and it makes a bit more sense that way. Thanks again :-).
â Greenonline
Aug 14 at 13:56
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2farduino.stackexchange.com%2fquestions%2f55279%2fhow-do-i-change-the-default-led-pin-for-displaying-uploading%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password