i want the basic project of arduino with full programmming
i want the basic project of arduino with full programmming
I am sorry but you need to provide a bit more detail of what you need help with
Provide schematic, and or Code up to now, pictures, sketches etc.
thanks
I suggest you read through and do some tutorials if you are just trying to teach yourself the platform.
http://arduino.cc/en/Tutorial/HomePage
This is the easiest project possible. Arduino - Blink
Doh, I had boolean running = false; on the wrong line. Fixed, formatted the code and included the compile size.
boolean running = false;
void setup() {
pinMode(13, OUTPUT);
}
void loop() {
digitalWrite(13,running=!running);
delay(1000);
}Binary sketch size: 1070 bytes (of a 32256 byte maximum, 3.32 percent).
And tbh we can do even better than that :-) (/me ponders how low can it go?)
Any other takers? we can go deeper :-)
void setup() {
pinMode(13, OUTPUT);
}
void loop() {
digitalWrite(13,!digitalRead(13));
delay(1000);
}compiles to a Binary sketch size: 1,234 bytes (of a 32,256 byte maximum)
void setup() {
DDRB = DDRB | B00100000; // set pin 13 to output
}
void loop() {
PORTB = PORTB ^ B00100000;
delay(1000);
}Compiles to a Binary sketch size: 666 bytes (of a 32,256 byte maximum)
Oh Ya
Using the registers on the micro and compiling to 666 bytes. NICE :-)
EDIT: Using _delay_ms(); we can get it down even smaller but I still like the 666 bytes compile
#include <util/delay.h>
void setup() {
DDRB = DDRB | B00100000; // set pin 13 to output
}
void loop() {
PORTB = PORTB ^ B00100000;
_delay_ms(1000);
}Binary sketch size: 494 bytes (of a 32256 byte maximum, 1.53 percent).
i looked for a lower level delay function but could not find it, well done 
I will keep a mental note of that call for future
As a beginner of course people will take the first approach but even in this simple demo is shows that when the memory starts to get constrained there are ways of significantly getting it back
we reduced a >1234byte program by 2/3rds (494 bytes) which is awesome if you think about it.
Peter