Author Topic: Can't compile message_out  (Read 2959 times)

Algol

  • Jr. Member
  • **
  • Posts: 4
  • Karma: +0/-0
Can't compile message_out
« on: May 10, 2013, 12:56:34 AM »
Hi, I started playing with the Kilobots, but a strange thing happens: I am not able to successfully compile a program in AVR studio (even the ones provided as example) if I use the message_out function. The compiler says that message_out is an unknown identifier...any suggestion about how to solve this problem? Am I missing something?

All the other functions of the API seem to compile without any problem.

Thanks for your help.

kteam

  • Administrator
  • Hero Member
  • *****
  • Posts: 378
  • Karma: +7/-1
Re: Can't compile message_out
« Reply #1 on: May 13, 2013, 11:44:13 AM »
Dear Algol,

Try "clean" (key F12), then "rebuild all" (menu "Build").

It is strange. You mean the KilobotSkeleton.c does not compile without modification?

Look into the libkilobot.c and libkilobot.h to see if the function is present!

in libkilobot.c , you should have:
void message_out(char tx0,char tx1,char tx2)
{
   message_tx0=tx0;
   message_tx1=tx1;
   message_tx2=tx2;
   message_tx2 &= 0xfe ;
}   


in libkilobot.h: extern void message_out(char ,char ,char );

Do you have #include "libKilobot.h" at the beginning of your file?

Something may have wrongly installed!

Best regards,
K-TEAM

Algol

  • Jr. Member
  • **
  • Posts: 4
  • Karma: +0/-0
Re: Can't compile message_out
« Reply #2 on: May 21, 2013, 01:24:24 PM »
Hi,

Thanks for your help with this.

I think the problem with message_out has now been solved, as this is not flagged as undefined when I try to build the project.

Thanks again!