strncpy() causes reset

It looks like I'm running out of RAM. I added a FreeMemory routine I found here: Arduino Playground - AvailableMemory

Before I define reply2, I have less then 200 bytes. reply2 would be 308 bytes. I'd like not have to create reply2 and just use reply with strtok(), but reply is a const char and strtok() doesn't like that. So my solution is to strncpy reply to reply2.

I think I'm running out of ram when I define reply2 on line 451.

I would also like to free up some ram, but I'm not sure how to do that. Attached is the entire sketch, except for PachubeAPIKey.h which is just a #DEFINE with my API key (65 characters).

I'm using a Nanode, which is similar to Arduino Deumilanove.

Water_Detector_Nanode_v6.ino (20.9 KB)