Interfacing Arduino from Procesisng detailed tutorial

I wrote a detailed tutorial on basic Arduino Processing communication at my blog at https://abhikpal.github.io/blog/2013/10/05/getting-started-with-arduino-processing-serial-communication.

Hope it helps someone; comments regarding the blog would be appreciated.

Thank you, that's a very helpful tutorial, but I DO see some room for improvements.

For instance, you show 'processing 2' pics, but I didn't see where you linked or mention to get Processing V2 libs for firmata as they are not included in the Processing V2 distro.

Also, I think adding comments indicating the codes purpose is important to keep arduino v processing code separated in my brain.

Other than that pedantic rant... great job.

I bet you forgot that was an additional step to install the firmata lib in processing... for that matter, that's where some Q's still are in my head. But many others were answered, and I bet I would stumble upon answers to my remaining Q's if I played with it a little.

Also, I think adding comments indicating the codes purpose is important to keep arduino v processing code separated in my brain.

I've posted the whole code at Code to supplement the "Interfacing Arduino from Processing" Tutorial · GitHub. I avoided putting comments as each line of code was explained in the tutorial itself.

As for the Firmata installation problem; I will update the post soon.

You show an LED connected directly to the arduino pins with no current limiting resistor. This is bad and could damage your arduino. There is a myth that will not go away that pin 13 has a resistor in seriese with it. This has not been turn since 2007 but it still apperes in tutorials like yours.

You show an LED connected directly to the arduino pins with no current limiting resistor.

The first version of this tutorial was written for the tutorial series of an Indian start up called Ardubotics (learn.ardubotics.com), the workshops that they organize use the Freeduino USB board (Probots - Largest DIY Electronics, Robotics & Engineering Parts Buy Online Store Buy Online India) which has a current limiting resistor attached on pin 13.
Also, in the blog post I pointed that most Arduinos have a led connected to pin 13 and adding the LED was optional.
However, I will update the post.

The reason that the series resistor was removed from the official arduino boards was that it interfered with the action of the SPI interface that also uses that pin.

I will update the post.

Thanks

Post Updated . . . :slight_smile:

Abhik:

Also, I think adding comments indicating the codes purpose is important to keep arduino v processing code separated in my brain.

I've posted the whole code at Code to supplement the "Interfacing Arduino from Processing" Tutorial · GitHub. I avoided putting comments as each line of code was explained in the tutorial itself.

Thanks, but what I meant was, just a comment at the top indicating if the code was for processing or arduino - be it just a sub-section of code being analyzed or what ever. I found my self reading code and not certain if it was arduino or processing code.

I updated the final Arduino and Processing code snippets. :slight_smile: