Legacy Forum: Preserving Nearly 20 Years of Community History - A Time Capsule of Discussions, Memories, and Shared Experiences.

problem building RCservo in DOS

Based on DMP's Vortex processor / SoC this board is a full computer capable of running a standard Windows and Linux installation on the backpack of your robot.
3 postsPage 1 of 1
3 postsPage 1 of 1

problem building RCservo in DOS

Post by copperclad » Sun Jan 10, 2010 5:43 pm

Post by copperclad
Sun Jan 10, 2010 5:43 pm

hi
i am running Borland C++ v4.51 and compiling for a DOS.exe

the program compiles fine but when i go to build i am getting some errors

here is the program i am trying , it compiles fine with 0 errors
#include <stdio>
#include <roboard>

int main(void) {
if (rcservo_Initialize(RCSERVO_USECHANNEL0)) {
printf("Initialized. Channel 0\n");
rcservo_Close();
} else {
printf("Initialization failed\n");
}

return 0;
}


and here are the errors i get when i try to build for an exe file
Linker Error:Undefined symbol_rcservo_close in module SERVO1.CPP
Linker Error:Undefined symbol_rcservo_Initialize in module SERVO1.CPP



not sure what i am doing wrong , any help would be great , thanks :D

i am guessing i am getting these errors because i have had trouble installing the library

i have downloaded the RoBoIO folder with the example and MAKE.DJ file in it , and when i go to a command line and type "make -f Make.DJ"
i get an error tell me that there needs to be a colon on lines 43 and 61 and errors out , without making the library , i have the files libRBIO.a and RoBOIO.lib in the C:\BC45\LIB folder , but i am not sure if they are installed correctly


.
hi
i am running Borland C++ v4.51 and compiling for a DOS.exe

the program compiles fine but when i go to build i am getting some errors

here is the program i am trying , it compiles fine with 0 errors
#include <stdio>
#include <roboard>

int main(void) {
if (rcservo_Initialize(RCSERVO_USECHANNEL0)) {
printf("Initialized. Channel 0\n");
rcservo_Close();
} else {
printf("Initialization failed\n");
}

return 0;
}


and here are the errors i get when i try to build for an exe file
Linker Error:Undefined symbol_rcservo_close in module SERVO1.CPP
Linker Error:Undefined symbol_rcservo_Initialize in module SERVO1.CPP



not sure what i am doing wrong , any help would be great , thanks :D

i am guessing i am getting these errors because i have had trouble installing the library

i have downloaded the RoBoIO folder with the example and MAKE.DJ file in it , and when i go to a command line and type "make -f Make.DJ"
i get an error tell me that there needs to be a colon on lines 43 and 61 and errors out , without making the library , i have the files libRBIO.a and RoBOIO.lib in the C:\BC45\LIB folder , but i am not sure if they are installed correctly


.
copperclad
Robot Builder
Robot Builder
Posts: 11
Joined: Tue Dec 08, 2009 2:06 pm

Re: problem building RCservo in DOS

Post by roboard » Mon Jan 11, 2010 6:39 am

Post by roboard
Mon Jan 11, 2010 6:39 am

copperclad wrote:i have downloaded the RoBoIO folder with the example and MAKE.DJ file in it , and when i go to a command line and type "make -f Make.DJ"
i get an error tell me that there needs to be a colon on lines 43 and 61 and errors out , without making the library , i have the files libRBIO.a and RoBOIO.lib in the C:\BC45\LIB folder , but i am not sure if they are installed correctly
.


MAKE.DJ is for DJGPP, not for BC45; so you can't use it to compile BC45 programs. The libRBIO.a and RoBoIO.lib you downloaded are for DJGPP, Linux gcc, or Visual C++. Currently no binary of RoBoIO is released for Borland C++.

There are two methods to use RoBoIO under BC45:

Method 1: Always add every .cpp files in the "libsrc" directory of RoBoIO into your BC45 projects (open a project by BC45 "Project" menu), and then compile your programs.

Method 2: Build the binary of RoBoIO library for BC45 by yourself (you can find some information on internet), and then use it in your BC projects.
copperclad wrote:i have downloaded the RoBoIO folder with the example and MAKE.DJ file in it , and when i go to a command line and type "make -f Make.DJ"
i get an error tell me that there needs to be a colon on lines 43 and 61 and errors out , without making the library , i have the files libRBIO.a and RoBOIO.lib in the C:\BC45\LIB folder , but i am not sure if they are installed correctly
.


MAKE.DJ is for DJGPP, not for BC45; so you can't use it to compile BC45 programs. The libRBIO.a and RoBoIO.lib you downloaded are for DJGPP, Linux gcc, or Visual C++. Currently no binary of RoBoIO is released for Borland C++.

There are two methods to use RoBoIO under BC45:

Method 1: Always add every .cpp files in the "libsrc" directory of RoBoIO into your BC45 projects (open a project by BC45 "Project" menu), and then compile your programs.

Method 2: Build the binary of RoBoIO library for BC45 by yourself (you can find some information on internet), and then use it in your BC projects.
roboard
Savvy Roboteer
Savvy Roboteer
Posts: 302
Joined: Fri Jul 03, 2009 4:44 am

Post by copperclad » Tue Jan 12, 2010 4:35 pm

Post by copperclad
Tue Jan 12, 2010 4:35 pm

thank you

i will download DJGPP and try using it , thanks again :D
thank you

i will download DJGPP and try using it , thanks again :D
copperclad
Robot Builder
Robot Builder
Posts: 11
Joined: Tue Dec 08, 2009 2:06 pm


3 postsPage 1 of 1
3 postsPage 1 of 1