Write to a memory with Arduino Yún

I’m using netIO app (it's an android app for my phone), and I can write directly to a pin, using the bridge library. But now I would need to write to a memory using the bridge library (html code).

My idea is to send a value from the app, save it in arduino yun, and then work with that value in the sketch using analog write to another pin. I want to do that to move a motor from the app.

Is this possible? Is there a different/better way to do that?

Thanks

if i understand correctly all you nead to do is:

add global array

int mem[10];

add new REST command like

[u]/arduino/memory/0/100[/u]

first digit index in array second value

Yes, that's what I want!

But, how can I add a new REST command like this one in the Bridge library?

Thanks

You don't need to. Read this http://blog.arduino.cc/2013/09/05/hands-on-the-arduino-yuns-bridge/ and play with the TemperatureWebPanel example

Hi Federico, could you explain me a little bit more in depth, how could I do what I want using this?

I’ve been reading the example and how it works, although I don’t have a temperature sensor to make it work.

Aren’t you also creating a new rest command (the “temperature” one)? How could I do what ranma1988 was saying (which I think is more or less what I need) without creating a new rest command?

Thanks

Onuk: How could I do what ranma1988 was saying (which I think is more or less what I need) without creating a new rest command?

The accepted REST commands depend on the sketch. Each sketch defines what are the accepted REST commands. The Bridge example defines a few of them. The TemperatureWebPanel example defines just one. Your sketch has to define what REST command to accept and what to do with it