I have an Arduino Uno, and I already use Serial with GSM/GPRS/GPS shield and I'd like to add softwareSerial that connect with OBD-II Adapter, how can I make OBD RX goes to Arduino softwareSerial TX on pin 12?

Hi all,

I included the library of SoftwareSerial.h in OBD.cpp file:

[code]#include <Arduino.h>
#include <avr/pgmspace.h>
#include <SoftwareSerial.h>

SoftwareSerial mySerial(10, 11); // RX, TX

#include "OBD.h"[/code]

and modified the original serial of uno to software serial in OBD.h file in the line 17

[code]#ifndef OBDUART
#if defined(__AVR_ATmega32U4__) || defined(__AVR_ATmega2560__) || defined(__AVR_ATmega1280__) || defined(__AVR_ATmega644P__)
#define OBDUART Serial1
#define OBDUART mySerial

and it complied successfully.
But when I attach the OBD adapter to software serial, the communication between OBD adapter and Arduino is faild and stuck on  this loop:

[code]// initiate OBD-II connection until success
    while (!obd.init()); [/code]

is there any solution for this?

thank you.