login

online now

We have 120 guests and no members online

search

 
Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: Arduino 1.0.1 IDE - GinSing v4 and SoftwareSerial

Arduino 1.0.1 IDE - GinSing v4 and SoftwareSerial 5 years 4 months ago #224

So in the Arduino 1.0.1 IDE you can't use both the Ginsing v4 and SoftwareSerial libraries in the same project. How do you get around this? Just make a simple project and include both headers, it won't compile.
Last Edit: 5 years 2 months ago by administrator.
The administrator has disabled public write access.

Re: Arduino 1.0.1 IDE - GinSing v4 and SoftwareSerial 5 years 4 months ago #225

Hi zparticle.

The GinSing version of the SoftwareSerial code has only one modification from the original version, which allows it to support hardware overflow from the Babblebot IC. This modification is not relevant to other serial devices unless you route the connected device to another pin on the Arduino; aside from that you should be able to create another instance of the GinSing serial interface in your code.

For example, your code can contain the usual GinSing code, but can also include another instance of the GinSing serial code as follows:
#include <GinSing.h>         // GinSing header file ( includes serial )
GinSing  GS;                 // GinSing interface

#define rcvPin  4            // GinSing serial receive pin
#define sndPin  3            // GinSing serial send pin
#define ovfPin  2            // GinSing serial overflow  pin


GinSingSerial mySerial;     // an additional serial interface


void setup ()
{
  GS.begin ( rcvPin , sndPin , ovfPin );      // start up GinSing
  
  
  // configure my own serial interface
  
  mySerial.config ( 12                        // my receive pin
                    11                        // my send pin
                    0xff                      // my overflow (n/a)
                  );
}

There is a restriction on SoftSerial that you can only read one interface at a time. This generally should not be a problem since most applications don't care what information comes back from the GinSing board.
The administrator has disabled public write access.

Re: Arduino 1.0.1 IDE - GinSing v4 and SoftwareSerial 5 years 4 months ago #226

Excellent, thanks. I'll give it a try tonight. I wasn't sure if I needed to do something special or not.
The administrator has disabled public write access.
  • Page:
  • 1
Time to create page: 0.218 seconds