2 baud rates require 2 arduino's?

Hi,

Just a quick newbie question: I have a parallax ping sensor and a parallax RFID reader. The ping sensor requires a 9600 baud rate, the rfid reader 2400.

On the site i’ve red "You can, however, specify other rates - for example, to communicate over pins 0 and 1 with a component that requires a particular baud rate."

Now I was wondering: since there are two pins, is it possible to read 2 sensor’s with a different baud rate?

Is it possible at all to read the 2 sensors with one arduino?

There is a SoftwareSerial library that sort of lets you do rs232 on any digital io pin. It has some limitations, but should be better in 0008. I think I’d be tempted to use an external multiplexor and use a third pin to switch my real hardware serial port back and forth between the two devices.

(A time honored technique. I have a frighteningly expensive piece of power generation gear that does this on its management interface. You can only issue commands to it within a couple milliseconds of receiving a report, after that it switches back to talking to an internal component for half a second.)

The parallax ping does not have a serial interface.

Ok so, I should setup the speed to 9600 since the ping has no serial and then with the software serial lib read the rfid scanner seperatly on a different speed within the loop as shown in the software serial tut?

hi

karlC is saying that the Ping does not need serial: just a regular I/O pin. Therefore just the RFID needs serial in your case, so set the baud rate to 2400 for the RFID, connect the RFID TX pin to the Arduino RX, and then connect the ping sensor to a digital pin between 2 and 13.

D

ow really? damn… that just works indeed
thank you so much!

I figured the ping always needed to be red at 9600 baud from the terminal since the example code started of with setting the serial to that speed… confusing =)

anyway, thx again, keep arduinoing!