Author Topic: Questions regarding the makefile in libkhepera  (Read 44080 times)


  • Newbie
  • *
  • Posts: 2
  • Karma: +0/-0
Questions regarding the makefile in libkhepera
« on: August 07, 2019, 11:01:47 PM »
Hello to all,

This may be a very basic question, but does anyone know how to modify the "makefile" text file in libkhepera-2.1/template, so that I can make c files with names other than "prog-template" and create make files with names other than "template"? Also, is there a way to make multiple c scripts at once?

I have been working with khepera IV a few months by now, but I always edit everything in prog-template because I am afraid to mess up anything in the "makefile" text file. I would rally appreciate the help, thanks!



  • Administrator
  • Hero Member
  • *****
  • Posts: 379
  • Karma: +7/-1
Re: Questions regarding the makefile in libkhepera
« Reply #1 on: August 28, 2019, 05:07:03 PM »
Dear Micheal,

one of the simpliest solution is to work under the libkhepera-2.1/src/tests folder. here, you will find all the actual program example.

Simply copy the one which is corresponding to your needs (khepera4_test.c is a good start). Rename it as you want, and add this name in the makefile libkhepera-2.1/src/tests/Makefile.

you just need to add to the Target your file name (line 25-30):
#Test Programs
TARGETS   = kb_config_test \
     koreio_test koreio_auto kmot_monitor gpio_test \
     kmot_ipserver kmotLE_monitor koreioLE_test \
     koreioLE_auto kgripper_test \
     klrf_test klrf_small_ex kgazer_test kgazer_small_ex \
     kh4_example khepera4_test gpio_test_all kh4server kh4_lrf_batpower

best regards