Ok, I was able to execute the actual code, but I the output is not correct.
Here is what I did cat ~/data/audio/bfire-w2m.mp2 ./minimad > x.pcm I then encapsulate the PCM as a wave file with a program I wrote, and produced the file x-mni.wav
and I also did on the development linux machine. ./madplay --output=wave:x.-mp86.wav ~/data/audio/bfire-w2m.mp2
You can see that file size is different here: -rw-r--r-- 1 erojas users 37528 Sep 24 13:33 x-mini.wav -rw-r--r-- 1 erojas users 16172 Sep 24 13:36 x-mp86.wav
When I play these files on a PC using winamp the madplay produced file is correct, and the minimad produced file is white noisy.
Any ideas? Endianess? Number of bits per sample? It does output PCM?
--------------------
Re: building madplay for the target, I'm having a devil of a time. Because I need to first install both the MAD library and tags library. But I can get the tags library to figure because it needs zlib. I have tried installing zlib, and I believe this has been done correctly, but the configure for the tags lib can not find it. I think this is because it is not telling the compiler to look in the right place, but I'm not really sure.
Re: script problem: The problem my be that I am installing the code in a directory that is later mounted as the root of the STB that I am developing for. I tried removing that part of the path in the one place it appeared and then executing it on the target but I still had the same error.
thanks, emil
At 02:30 PM 9/23/2004, Rob Leslie wrote:
On Sep 23, 2004, at 2:22 PM, Emil Rojas wrote:
Hmm, I still get this stuff when I try to run minimad, do have any idea what would cause that? I will make madplay and try it also.
I think it is probably because the minimad "executable" that is built is really only a shell script that invokes the real executable after first arranging to locate the correct shared libraries in the build environment (as they may not be installed yet).
The real executable lives in the .libs subdirectory.
-- Rob Leslie rob@mars.org
On Sep 24, 2004, at 1:54 PM, Emil Rojas wrote:
Ok, I was able to execute the actual code, but I the output is not correct.
Here is what I did cat ~/data/audio/bfire-w2m.mp2 ./minimad > x.pcm
What you've done is to concatenate the mp2 file with the minimad executable itself to produce your output.
The correct way to invoke minimad is like this:
./minimad < ~/data/audio/bfire-w2m.mp2 > x.pcm
Re: building madplay for the target, I'm having a devil of a time. Because I need to first install both the MAD library and tags library. But I can get the tags library to figure because it needs zlib. I have tried installing zlib, and I believe this has been done correctly, but the configure for the tags lib can not find it. I think this is because it is not telling the compiler to look in the right place, but I'm not really sure.
It's probably best to cross-compile zlib yourself, and install it into a staging area which you then tell the configure script for libid3tag about.
A convenience package for building zlib can be found here:
ftp://ftp.mars.org/pub/mpeg/extra/libz-1.1.4.tar.gz
If your staging area is $staging, the basic idea goes like this:
cd libz-1.1.4 ./configure --host=mipsel-linux --prefix=$staging make && make install
cd libid3tag-0.15.1b ./configure --host=mipsel-linux --prefix=$staging \ CPPFLAGS=-I$staging/include LDFLAGS=-L$staging/lib make && make install
The same process also works for libmad and madplay.
Re: script problem: The problem my be that I am installing the code in a directory that is later mounted as the root of the STB that I am developing for. I tried removing that part of the path in the one place it appeared and then executing it on the target but I still had the same error.
If you follow the above guidelines, you can copy the entire staging directory to the target. You may have to manipulate your LD_LIBRARY_PATH to find the shared libraries on the target if the path on the target is not the same as the path to the staging directory on your build system.