Need some help with sending data between two aurdinos.

hey guys, i need some help to connect my two aurdino's, i am thinking of a bluetooth connection. i'm sensing temperature using lm35 and currently uploaded the data to one aurdino. Now i have to send the data to another aurdino using bluetooth and i have no idea how to. please help me with the code and interfacing. Thanks , any help would be appreciated. nt val; int tempPin = 1;

void setup() { Serial.begin(9600); } void loop() { val = analogRead(tempPin); float mv = ( val/1024.0)*5000; float cel = mv/10; float farh = (cel*9)/5 + 32;

Serial.print("TEMPRATURE = "); Serial.print(cel); Serial.print("*C"); Serial.println(); delay(1000);

/* uncomment this to get temperature in farenhite Serial.print("TEMPRATURE = "); Serial.print(farh); Serial.print("*F"); Serial.println();

*/ } PS. this is the code i used to sense temperature.

Which distance?

Anyway, your options are

wired: short distance (50cm or so): directly connected software serial, I2C, SPI longer (15 meters): software serial with RS232 drivers much longer (to 1000 plus meters): software serial with RS422 or RS485

wireless: 433MHz, wifi, bluetooth, nrf24 (no real expertise with any of those).

balganz: hey guys, i need some help to connect my two aurdino's, i am thinking of a bluetooth connection. i'm sensing temperature using lm35 and currently uploaded the data to one aurdino. Now i have to send the data to another aurdino using bluetooth and i have no idea how to.

https://arduino-info.wikispaces.com/BlueTooth-HC05-HC06-Modules-How-To

i have to send the data to another aurdino using bluetooth

School assignment?

Bluetooth is like serial-by-wireless. When you have your connection established the examples in Serial Input Basics may be useful. The technique in the 3rd example will be most reliable.

...R