Teleduino and SD card

Hello everybody, I don’t really know which section this question belongs to…

I am setting up a remotely controlled Arduino via Teleduino and I also want to log some data on a SD card. I have two codes (one for writing on the SD and one for the remote control) that work well alone, but I get some errors when I try to merge them.

It seems to me that there is an incompatibility issue in the libraries: with the following code I get some lines of errors.

CODE

#include <EEPROM.h>
#include <Servo.h>
#include <Wire.h>
#include <Teleduino328.h>

#include <SPI.h>
#include <SD.h>
#include <Ethernet.h>

void setup(){}
void loop(){}

ERRORS

In file included from C:\Program Files (x86)\Arduino\libraries\SD/SD.h:21,
                 from sketch_dec28a.ino:7:
C:\Program Files (x86)\Arduino\libraries\SD/utility/SdFatUtil.h: In function 'int FreeRam()':
C:\Program Files (x86)\Arduino\libraries\SD/utility/SdFatUtil.h:38: error: type mismatch with previous external decl of 'int __bss_end'
C:\Program Files (x86)\Arduino\libraries\Teleduino328/Teleduino328.h:29: error: previous external decl of 'unsigned int __bss_end'
C:\Program Files (x86)\Arduino\libraries\SD/utility/SdFatUtil.h:39: error: type mismatch with previous external decl of 'int* __brkval'
C:\Program Files (x86)\Arduino\libraries\Teleduino328/Teleduino328.h:31: error: previous external decl of 'void* __brkval'

Can someone give me a hint on what to do? Has someone faced a similar problem before?

Your Teleduino code seems do redeclare some variables from the SD-Library. What is the behaviour if you only include SD.h or only Teleduino328.h?

In your SdFatUtil.h file you can delete the complete FreeRam() function as it's not used anywhere in the library. I don't know the Teleduino library and you didn't provide a link to it so I don't hint you there.