Need Help about WinARM

OP #1171690
Rate this post
useful
not useful
Hi every body ! I interested in this page
http://dma.elektroda.net/projects/mp3_arm_player/mp3_arm_player.html
About building MP3 player only use the LPC2106 microcontroller
I've made this hardware and load the .hex file, wowww it had worked ok!
Now, I want to improve the software, by using the WinARM compiler in
this page
http://www.siwawi.arubi.uni-kl.de/avr_projects/arm_projects/#winarm
First, I using the origin source code,
while compiling the source code, an error has occur, but I can't fix
this problem, who had done with it please give some advances. I'm sorry,
my english is rather pour!

Here is the error session :


Linking: main.elf
arm-elf-gcc -mcpu=arm7tdmi-s -I. -gdwarf-2 -DROM_RUN -D ARM -O2 -Wall
-Wcast-align -Wcast-qual -Wimplicit -Wpointer-arith -Wswitch
-Wredundant-decls -Wreturn-type -Wshadow -Wunused -Wa,-adhlns=crt0.lst
-I./efsl -I./efsl/inc -I./efsl/conf -I./mp3dec -I./mp3dec/pub -MD -MP
-MF .dep/main.elf.d crt0.o ./mp3dec/real/arm/asmpoly_gcc.o main.o uart.o
timer.o VIClowlevel.o pwm.o dac.o led.o debug.o utilities.o lpc.o
./efsl/src/efs.o ./efsl/src/plibc.o ./efsl/src/disc.o
./efsl/src/partition.o ./efsl/src/time.o ./efsl/src/fs.o
./efsl/src/fat.o ./efsl/src/file.o ./efsl/src/dir.o ./efsl/src/ls.o
./efsl/src/mkfs.o ./efsl/src/debug.o ./efsl/src/ioman.o ./efsl/src/ui.o
./efsl/src/extract.o ./efsl/src/interfaces/sd.o
./efsl/src/interfaces/efsl_dbg_printf_arm.o
./efsl/src/interfaces/lpc2000_spi.o ./mp3dec/mp3dec.o ./mp3dec/mp3tabs.o
./mp3dec/real/bitstream.o ./mp3dec/real/buffers.o ./mp3dec/real/dct32.o
./mp3dec/real/dequant.o ./mp3dec/real/dqchan.o ./mp3dec/real/huffman.o
./mp3dec/real/hufftabs.o ./mp3dec/real/imdct.o ./mp3dec/real/scalfact.o
./mp3dec/real/stproc.o ./mp3dec/real/subband.o ./mp3dec/real/trigtabs.o
--output main.elf -nostartfiles -Wl,-Map=main.map,--cref -lc -lm -lc
-lgcc -TLPC2106-ROM.ld
c:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/lib\libc.a(ma 
llocr.o):
In function `_malloc_r':
mallocr.c.text+0x424): undefined reference to `_sbrk_r'
mallocr.c.text+0x4cc): undefined reference to `_sbrk_r'
c:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/lib\libc.a(fr 
eer.o):
In function `_malloc_trim_r':
mallocr.c.text+0x48): undefined reference to `_sbrk_r'
mallocr.c.text+0x64): undefined reference to `_sbrk_r'
mallocr.c.text+0x84): undefined reference to `_sbrk_r'
collect2: ld returned 1 exit status
make.exe: *** [main.elf] Error 1
Guest #1171691
Rate this post
useful
not useful
Phuong Minh wrote:
> Hi every body ! I interested in this page
> http://dma.elektroda.net/projects/mp3_arm_player/mp3_arm_player.html
> About building MP3 player only use the LPC2106 microcontroller
> I've made this hardware and load the .hex file, wowww it had worked ok!
> Now, I want to improve the software, by using the WinARM compiler in
> this page
> http://www.siwawi.arubi.uni-kl.de/avr_projects/arm_projects/#winarm
> First, I using the origin source code,
> while compiling the source code, an error has occur, but I can't fix
> this problem, who had done with it please give some advances. I'm sorry,
> my english is rather pour!
>
> Here is the error session :
>
>
> Linking: main.elf
> arm-elf-gcc -mcpu=arm7tdmi-s -I. -gdwarf-2 -DROM_RUN -D ARM -O2 -Wall
> -Wcast-align -Wcast-qual -Wimplicit -Wpointer-arith -Wswitch
> -Wredundant-decls -Wreturn-type -Wshadow -Wunused -Wa,-adhlns=crt0.lst
> -I./efsl -I./efsl/inc -I./efsl/conf -I./mp3dec -I./mp3dec/pub -MD -MP
> -MF .dep/main.elf.d crt0.o ./mp3dec/real/arm/asmpoly_gcc.o main.o uart.o
> timer.o VIClowlevel.o pwm.o dac.o led.o debug.o utilities.o lpc.o
> ./efsl/src/efs.o ./efsl/src/plibc.o ./efsl/src/disc.o
> ./efsl/src/partition.o ./efsl/src/time.o ./efsl/src/fs.o
> ./efsl/src/fat.o ./efsl/src/file.o ./efsl/src/dir.o ./efsl/src/ls.o
> ./efsl/src/mkfs.o ./efsl/src/debug.o ./efsl/src/ioman.o ./efsl/src/ui.o
> ./efsl/src/extract.o ./efsl/src/interfaces/sd.o
> ./efsl/src/interfaces/efsl_dbg_printf_arm.o
> ./efsl/src/interfaces/lpc2000_spi.o ./mp3dec/mp3dec.o ./mp3dec/mp3tabs.o
> ./mp3dec/real/bitstream.o ./mp3dec/real/buffers.o ./mp3dec/real/dct32.o
> ./mp3dec/real/dequant.o ./mp3dec/real/dqchan.o ./mp3dec/real/huffman.o
> ./mp3dec/real/hufftabs.o ./mp3dec/real/imdct.o ./mp3dec/real/scalfact.o
> ./mp3dec/real/stproc.o ./mp3dec/real/subband.o ./mp3dec/real/trigtabs.o
> --output main.elf -nostartfiles -Wl,-Map=main.map,--cref -lc -lm -lc
> -lgcc -TLPC2106-ROM.ld
> c:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/lib\libc.a(ma 
llocr.o):
> In function `_malloc_r':
> mallocr.c.text+0x424): undefined reference to `_sbrk_r'
> ...

Please search this forum. It is a FAQ - missing "syscall". Provide your
own sbrk_r implementation. See the newlib-lpc-code or the example-code
that come with WinARM. Further information in the newlib documentation.
It would be nice if you could give people some time to answer before
asking the same question in various forums and by e-mail.

Martin Thomas

Reply

Please log in before posting.

or

Log in with Google account

Registration is free and takes only a minute.

Register now