Some housekeeping fixes and fix a bug with "FR" that prevented it's functioning.
This commit is contained in:
parent
c6d1e93f5d
commit
aad48e3799
|
@ -41,7 +41,7 @@ amplify = 2.0
|
||||||
|
|
||||||
# What is the base note? I.e. the lowest note.
|
# What is the base note? I.e. the lowest note.
|
||||||
# Note that it won't have very much impact until an octave up though!
|
# Note that it won't have very much impact until an octave up though!
|
||||||
base_hz = 55.0000
|
base_hz = 55
|
||||||
|
|
||||||
# This is only used when dealing with the slow decompose (now defunct)
|
# This is only used when dealing with the slow decompose (now defunct)
|
||||||
# decompose_iterations = 1000
|
# decompose_iterations = 1000
|
||||||
|
|
|
@ -27,7 +27,7 @@ port = 7777
|
||||||
address = 192.168.4.1
|
address = 192.168.4.1
|
||||||
|
|
||||||
slope=.10
|
slope=.10
|
||||||
amplify=.24
|
amplify=.35
|
||||||
|
|
||||||
|
|
||||||
lightx = 20
|
lightx = 20
|
||||||
|
@ -42,8 +42,10 @@ sourcename =
|
||||||
fliprg = 1
|
fliprg = 1
|
||||||
skittlequantity = 24
|
skittlequantity = 24
|
||||||
|
|
||||||
|
base_hz = 71.5000
|
||||||
|
|
||||||
led_limit=.5
|
|
||||||
|
led_limit=1.0
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -201,6 +201,7 @@ failfx:
|
||||||
{
|
{
|
||||||
buffend += ets_sprintf(buffend, "FR%08d\t%04d\t", nr, datlen ); //Caution: This string must be a multiple of 4 bytes.
|
buffend += ets_sprintf(buffend, "FR%08d\t%04d\t", nr, datlen ); //Caution: This string must be a multiple of 4 bytes.
|
||||||
spi_flash_read( nr, (uint32*)buffend, datlen );
|
spi_flash_read( nr, (uint32*)buffend, datlen );
|
||||||
|
buffend += datlen;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -170,7 +170,7 @@ void LoadRaw()
|
||||||
FILE * f = fopen( rawfilename, "rb" );
|
FILE * f = fopen( rawfilename, "rb" );
|
||||||
if( !f )
|
if( !f )
|
||||||
{
|
{
|
||||||
fprintf( stderr, "Error: Can't open the specified rawfile.\n" );
|
fprintf( stderr, "Error: Can't open the specified rawfile. %s\n", rawfilename );
|
||||||
exit( -20 );
|
exit( -20 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -200,6 +200,9 @@ void LoadRaw()
|
||||||
int sbp = 0;
|
int sbp = 0;
|
||||||
float IntSoundBuffer[sbs];
|
float IntSoundBuffer[sbs];
|
||||||
|
|
||||||
|
|
||||||
|
FILE * fr = fopen( "folded_data.txt", "w" );
|
||||||
|
|
||||||
for( i = 0; i < SoundPictureStacks; i++ )
|
for( i = 0; i < SoundPictureStacks; i++ )
|
||||||
{
|
{
|
||||||
int nplace = ((int)(SoundPictureTime * (i+1)))&0xffffffe;
|
int nplace = ((int)(SoundPictureTime * (i+1)))&0xffffffe;
|
||||||
|
@ -233,7 +236,15 @@ void LoadRaw()
|
||||||
{
|
{
|
||||||
SoundPicture[i*SoundPictureBins+j] = nf->outbins[j];
|
SoundPicture[i*SoundPictureBins+j] = nf->outbins[j];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for( j = 0; j < nf->freqbins; j++ )
|
||||||
|
{
|
||||||
|
fprintf( fr, "%f ", nf->folded_bins[j] );
|
||||||
}
|
}
|
||||||
|
fprintf( fr, "\n" );
|
||||||
|
}
|
||||||
|
|
||||||
|
fclose( fr );
|
||||||
|
|
||||||
FILE * pic = fopen( "pic.pgm", "wb" );
|
FILE * pic = fopen( "pic.pgm", "wb" );
|
||||||
fprintf( pic, "P6\n%d %d\n255\n", SoundPictureStacks, SoundPictureBins );
|
fprintf( pic, "P6\n%d %d\n255\n", SoundPictureStacks, SoundPictureBins );
|
||||||
|
@ -258,6 +269,8 @@ void LoadRaw()
|
||||||
}
|
}
|
||||||
fclose( pic );
|
fclose( pic );
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int argc, char ** argv)
|
int main(int argc, char ** argv)
|
||||||
|
|
Loading…
Reference in a new issue