simple serial Max to Arduino discussion

Liang's icon

i always send data from Arduino to Max, and there is an example in Arduino ---> Example ----> communication ---- > Graph that we can just copy and paste to make this done.
and here i'd share a really simple way to send data from Max to Arduino, this example is to press toggle in Max to control the Led (pin13) on/off on the Arduino main board. (surely u can use a relay replace this led, etc.)
SERIAL_IN_SIMPLE.ZIP is arduino zip file.
and there must be lot of better ways, anyone would like to talk about it ?

Screen-Shot-2015-12-31-at-9.24.17-AM.png
png
Screen-Shot-2015-12-31-at-9.24.03-AM.png
png
serial_in_simple.zip
zip
Scott Fitzgerald's icon

In the same Arduino —> Example —-> Communication —- > path of the Arduino IDE, there are a number of examples for Max to Arduino serial communication. See also : Dimmer (fade an LED), Physical Pixel (turn an LED on/off), SerialCallResponse (send multiple bytes from Arduino to Max), SerialCallResponseASCII (send ASCII messages from Arduino to Max), and VirtualColorMixer (send the value of three pots to Max to change the color of the patcher background).

In each example, there's a Max 5+ compatible compressed patch at the bottom of the sketch (scroll past the Processing bits).

I'm going to selfishly hijack this post, as I just had a conversation about this issue with some of the core Arduino people. What is missing from the documentation of the Arduino platform that people are compelled to turn to Maxuino and other frameworks for such simple things as blinking an LED? Why reinvent the wheel when there's samples that work out of the box? Do these not work? Are they not visible enough?

Sorry for the short ramble, but I'm genuinely curious.

Holland Hopson's icon

@Scott,
I use these serial communication examples often with both Max and Processing. The one that's most useful for me is the VirtualColorMixer example and it's the last example in the list. Maybe some users give up before they get there?

Simon's icon

@Scott
If I ever noticed these examples over the last nine years, which I think I did, I soon forgot where they were, which is a personal failing and maybe an indication.
It would seem to be well past time to make these more obvious in the tutorials of both Max & Arduino, and maybe time to extend them a bit.
An i2c one would be my personal fave ...hint hint

Anyway, thanks for ther great demystifying examples so far!

Simon

Scott Fitzgerald's icon

Howard, glad to hear that's helpful for you! Unfortunately, the examples are organized alphabetically, I don't have much sway over that aspect of organization.

Simon, noted with the I2C request. It may be awhile yet though :)

Scott Fitzgerald's icon

* apologies, I meant Holland, not Howard!