Page 1 of 1

chprintf with STM32F100 demo error

Posted: Sun Sep 22, 2013 6:17 pm
by pito
I cannot get working

Code: Select all

..
#include "chprintf.h"
#include <chstreams.h>
#include <string.h>
#include <stdio.h>
..
chprintf((BaseSequentialStream*)&SD1, "DDD\r\n");

with stm32vl demo. I get "undefined reference to chprintf" error.

It compiles with stn32f407 demo. Any hint plz?

Re: chprintf with STM32F100 demo error

Posted: Sun Sep 22, 2013 6:22 pm
by Tectu
Are you referring to /demos/ARMCM3-STM32F100-DISCOVERY? That one build just fine for me - I even checked the latest master.
Make sure that you included the chprintf stuff in your Makefile:

Code: Select all

CSRC += $(CHIBIOS)/os/various/chprintf.c



~ Tectu

Re: chprintf with STM32F100 demo error

Posted: Sun Sep 22, 2013 6:32 pm
by pito
Yes, all the latest.
The adding the above line into the Makefile helped. Thanks.

Re: chprintf with STM32F100 demo error

Posted: Sun Sep 22, 2013 6:54 pm
by pito
Edit: deleted, solved