Hi,

i tried to change the buffer size of printf as mentioned in the TinyOS
documentation by adding the following line to my Makefile:

     CFLAGS += -DPRINTF_BUFFER_SIZE=2000

When I try to build the application it fails. The problem is that the
last three lines of the following output repeat forever:

-----------------
$ makesnooper.sh
mkdir -p build/micaz
    compiling SnooperAppC to a micaz binary
ncc -o build/micaz/main.exe -Os -I%T/lib/net/ctp -I%T/lib/net
-I%T/lib/net/le -finline-limit=100000 -Wall -Wshadow -Wnesc-all
-target=micaz -fnesc-cfile=build/micaz/app.c
 -board=mts300 -I/opt/tinyos-2.x/tos/lib/printf -I../
-DCC2420_NO_ACKNOWLEDGEMENTS -DCC2420_NO_ADDRESS_RECOGNITION
-DPRINTF_BUFFER_SIZE=2000 -DIDENT_PROGRAM_NAME=\"SnooperAppC\"
-DIDENT_USER_ID=\"Nicki\" -DIDENT_HOSTNAME=\"ltnic\"
-DIDENT_USER_HASH=0xce21d42fL -DIDENT_UNIX_TIME=0x4891a807L
-DIDENT_UID_HASH=0xd45e3960L -fnesc-dump=wiring
-fnesc-dump='interfaces(!abstract())'
-fnesc-dump='referenced(interfacedefs, components)'
-fnesc-dumpfile=build/micaz/wiring-check.xml SnooperAppC.nc -lm
In file included from SnooperC.nc:1:
/opt/tinyos-2.x/tos/lib/printf/printf.h:41:1: warning:
"PRINTF_BUFFER_SIZE" redefined

<command line>:5:1: warning: this is the location of the previous definition
In file included from <command line>:13:
/tmp/nesccppm2005000:1046:1: warning: "PRINTF_BUFFER_SIZE" redefined
-----------------

Does anybody know a clean way to change the buffer size that works? Or
am I doing anything wrong? I do not want to change it in the printf.h
file because this would affect all applications and I only want to
change it for my snooper application.

Thanks Nicola
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to