Communication between processors and between laptop and Yun in my application

Hi folks,

Here's what I need to do:

The 32U4 on the Yun needs to run a small program loop that: reads commands delivered via WiFi to set two output bits on/off, monitors two input switches and toggles those 2 outputs bits on/off, reads an analog input and sends the status of the outputs and analog input via WiFi to my control station. I can handle writing the Sketch for the 32U4, but I am still not clear what I need to do to communicate with the WiFi portion of the Yun and how to link the commands. Is Bridge the right thing to use in the 9331 side? Or Yun Mailbox Constructor? Or do I need a Python script?

I'm also clueless on how to write my app for the laptop/notepad. Is their an easy GUI program to use on that end that will allow me to send and receive commands to the Yun over Wifi, and create my interactive icons?

Thanks,

Dean

For receiving commands (eg: running a function or analogWrite a certain value), one easy way is using Bridge's YunClient/YunServer. The Bridge example (examples, Bridge, Bridge) does just that.

To publish readings to the outside world, one easy way is using Bridge.put() and have something calling yun's /data/ urls, eg: have your sketch run Bridge.put("living_room_temperature", String(22)) and use your browser to access http://myyun.local/data/get/living_room_temperature

Take a look at this for other info regarding how Bridge works Hands on: the Arduino Yún's Bridge | Arduino Blog