Go Down

Topic: Combining VirtualWire and Softserial (Read 780 times) previous topic - next topic

Madeleine

Jan 30, 2011, 08:57 am Last Edit: Jan 30, 2011, 05:09 pm by Madeleine Reason: 1
I've briefly tried to combine the use of
  1. Softserial (for getting data from GPS) at 9600 bps
  2. VirtualWire (for sending the data to a remote host) at 2000 bps
But it seems like I'm not getting anything on the Softserial-watching port as soon as I include the VirtualWire-library.
They are of course using different pins.

Is this a known interrupt-issue?
I have the debugging computer connected on the normal Serial line. (115000 bps, is this an issue?)
I am in urgent need of sending the data. Please advise a lady in despair  :smiley-red:.

(Hardware: boarduino w atmega328, GPS, simple 434MHz ASK-transmitter)

PaulS

Quote
Is this a known interrupt-issue?

More like a missing code issue. As in your code is missing.

Madeleine

Haha. Point taken.
I switched to NewSoftSerial and rewrote everything from scratch. It seemed that I spent to much time recalculating checksums every turn in the loop.
Now it works. I simply watch the NewSoftSerial-port and when I get a stop-byte, I now recalculate the checksum and then send off the packet.

mikem

VirtualWire uses timer1 for its own purposes. May be that?

CaCo

Madeleine, could you please paste your code?? i've tried NewSoftSerial and I have the same problem... =S

Thanks in advance!

Go Up