Go Down

Topic: avr tutorial (Read 3390 times) previous topic - next topic

jnguyen327

I found a lot of the responses to the tutorial to be rather critical. Personally the tutorial was wonderful to me, keep up the great work!

zitron

#31
Dec 06, 2007, 02:43 am Last Edit: Dec 06, 2007, 02:44 am by zitron Reason: 1
Hey, really nice work, I have a friend that might be interested in getting an arduino, this will save me time explaining things! I liked how you explained the differences between byte, int, long and stuff, showing that you get weird results from not using the proper types. I had to help out in a micro-controller lab at uni, I saw a lot of people getting stuck after multiplying a int by a large number, totally messing up the program even though the equations were correct!

Oh how do I apply for a contract job at "Blinky Lite Fun Company Inc"  :D? I can totally make things blink!

-Z-

twf

Ladyada, I'd like to thank you for writing the tutorial. I bought an Arduino mainly on the basis of seeing your tutorials. They are really well written, and easy to follow for someone who has just minor knowledge of electronics. Kudo's, therefore. And, I eagerly await the next lesson ;)


dickda

These tutorials are very high quality.  

I teach engineering in high school using the Arduino processor.  This is just the sort of tutorial I could hand to a new electronics student.  Wonderful!

Please continue the tutorials

ladyada

i took a break to make some cool shields, but will return to the tutorials soon. they take a surpringly long time to write (like 3 days each) and i got a little burnt out after writing 4 in 2 weeks :)

TomP

Quote
i took a break to make some cool shields, but will return to the tutorials soon.

Cool shields are an acceptable excuse  :)  Is it just the motor shield and boarduino 2, or have you been keeping some of your projects secret...?

Adion

Nice tutorials!

I noticed that the Help section said it's not Vista-ready, but at least on Vista 32-bit the Arduino Deciemila works perfectly now.

Also I think a tutorial about interrupts might be a good idea, since in your last tutorial there are already 250 ms between each digitalread, so with even more complex loop-lights I can imagine that more button-presses will be missed unless you check the button state in-between loops.

mem

#37
Feb 20, 2008, 12:41 pm Last Edit: Feb 20, 2008, 12:43 pm by mem Reason: 1
Quote
... I think a tutorial about interrupts might be a good idea, since in your last tutorial there are already 250 ms between each digitalread, so with even more complex loop-lights I can imagine that more button-presses will be missed unless you check the button state in-between loops.


If this is the tutorial you are referring to, it has a delay of 10ms, and that is necessary to reduce switch bounce.  Reading switch values any faster than that could result in false readings.

Adion

I should have been more specific.
At the bottom there are also some loop-sequences, for example one does this:
Code: [Select]
 if (lightMode == 3)  { // "wave"
   digitalWrite(led5Pin, LOW);
   digitalWrite(led1Pin, HIGH);
   delay(50);
   digitalWrite(led1Pin, LOW);
   digitalWrite(led2Pin, HIGH);
   delay(50);
   digitalWrite(led2Pin, LOW);
   digitalWrite(led3Pin, HIGH);
   delay(50);
   digitalWrite(led3Pin, LOW);
   digitalWrite(led4Pin, HIGH);
   delay(50);
   digitalWrite(led4Pin, LOW);
   digitalWrite(led5Pin, HIGH);
   delay(50);
   digitalWrite(led5Pin, LOW);
 }    

Only after the sequence is finished the input will be read again, so this is effectively a 250ms period where button-presses will not be detected.

mem

#39
Feb 21, 2008, 04:07 pm Last Edit: Feb 21, 2008, 04:09 pm by mem Reason: 1
I think the author of that code could reasonably argue that its better for the 'wave' to finish before acting on another button.

But if a faster response was required then how about instead of calling delay having something like a delayAbort function that checked every 10 milliseconds or so if a switch was pressed and returned immediately if it was.

TomP

There was some discussion of this issue over on ladyada's forums, in a thread titled Lesson 3 - delay on reading button press.

justfred

Quote
Why start with lesson 0 and not with lesson 1?  ::)

If you open a box of chocolates, the first chocolate you grab out of the box, it's chocolate 1, not chocolate 0...   ;)

For the rest, keep up the good work  :)



(aside from the zero-based array argument...) Step zero is usually the step you have to do before you can do anything real.  In the arduino instructions, it's getting set up.  In the chocolate box, step zero is "open the box".

4fun

I found the tutorials very helpful. As a newbie they are exactly the kind of thing that let me take the leap and not worry about making  things work. Once you can blink some lights the world is your oyster anyhow. So thanks Ladyada I am in your debt.

Go Up