I'm trying to send POST data via a SIM900 module. The process is to create the large POST string by strcat'ing variables together, then set the SIM900 module up to send, then using hardware serial to output the char array @ 19200.
I'm using a ATMega1284 chip that has substantially more SRAM than a standard Arduino Uno, and I'm using the HobbyTronics Uno*Pro bootloader and pin layout. When I compile, I get this:
Sketch uses 30,432 bytes (23%) of program storage space. Maximum is 130,048 bytes. Global variables use 12,774 bytes (77%) of dynamic memory, leaving 3,610 bytes for local variables. Maximum is 16,384 bytes. Low memory available, stability problems may occur
It works for the first few hundred chars, but then corrupts. I've got to the point where I create the string, then I print it out 3 times with Serial.println() and each instance is different.
As I can't put it all in here, I've put the output and the code in this pastebin: http://pastebin.com/tPVb8LjP
Any pointers on whats going on? I've tried everything I know, and I've hit a wall :( I've increased the HardwareSerial buffer size, but that didn't seem to help either.
I'm using MsTimer2 with an interval of 150ms if that would affect the Serial interrupts.