diff --git a/colorchord2/default.conf b/colorchord2/default.conf index 725ce96..0e121b5 100644 --- a/colorchord2/default.conf +++ b/colorchord2/default.conf @@ -41,7 +41,7 @@ amplify = 2.0 # What is the base note? I.e. the lowest note. # 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) # decompose_iterations = 1000 diff --git a/colorchord2/double_pie_voice.conf b/colorchord2/double_pie_voice.conf index 192a0fb..df7eb1c 100644 --- a/colorchord2/double_pie_voice.conf +++ b/colorchord2/double_pie_voice.conf @@ -27,7 +27,7 @@ port = 7777 address = 192.168.4.1 slope=.10 -amplify=.24 +amplify=.35 lightx = 20 @@ -42,8 +42,10 @@ sourcename = fliprg = 1 skittlequantity = 24 +base_hz = 71.5000 -led_limit=.5 + +led_limit=1.0 diff --git a/embedded8266/common/commonservices.c b/embedded8266/common/commonservices.c index 9460ade..9627cf1 100644 --- a/embedded8266/common/commonservices.c +++ b/embedded8266/common/commonservices.c @@ -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. spi_flash_read( nr, (uint32*)buffend, datlen ); + buffend += datlen; break; } } diff --git a/karaoke/composer.c b/karaoke/composer.c index df87d2c..a0654b5 100644 --- a/karaoke/composer.c +++ b/karaoke/composer.c @@ -170,7 +170,7 @@ void LoadRaw() FILE * f = fopen( rawfilename, "rb" ); 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 ); } @@ -200,6 +200,9 @@ void LoadRaw() int sbp = 0; float IntSoundBuffer[sbs]; + + FILE * fr = fopen( "folded_data.txt", "w" ); + for( i = 0; i < SoundPictureStacks; i++ ) { int nplace = ((int)(SoundPictureTime * (i+1)))&0xffffffe; @@ -233,8 +236,16 @@ void LoadRaw() { 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" ); fprintf( pic, "P6\n%d %d\n255\n", SoundPictureStacks, SoundPictureBins ); int x, y; @@ -258,6 +269,8 @@ void LoadRaw() } fclose( pic ); + + } int main(int argc, char ** argv)