Datalogger with RFBee

Hi everyone,
I'm doing a datalogger with an Arduino UNO and remotes sensores with RFBee wireless transceiver (five, four nodes and one coordinator), for an educational project.
I have 4 spots with 7 sensors in each one. Each spot it's made with an RFBee to read analog sensors and send a wireless data packet.
The RFBee coordinator it's connected to the Arduino UNO by Serial TTL port, and just it's a bridge between Arduino UNO, who save data in a SD card with timestamp, and the wireless nodes. The communication between the nodes and coordinator works well when i tested with a computer terminal (putty).
The problem it's when the data must be saved in the SD card, some times works fine, others the TXT file is created but empty, and others the Arduino UNO just freezes.
Please Help me, I need to finish my project this week :~

I attached the code for ArduinoUNO is : ArduLogTest
and the code for RFBee coordinator is: RFBee_master

Best regards,

ArduLogTest.rar (2.79 KB)

RFBee_master.rar (23.9 KB)

i've similar project now, but i need to write out data from xbee to arduino pwm. Can you instead help me?
XD

Ok, i'm not using XBee, i'm using a RFBee ... it's "physical" equivalent format, but works different... RFBee has a ATMEGA328 core (arduino compatible) ...
So, i don't know how to inmediately help you
Siya!