music map init, dip scan added
This commit is contained in:
		
							parent
							
								
									12a64ff24b
								
							
						
					
					
						commit
						91efe74365
					
				
					 10 changed files with 97 additions and 49 deletions
				
			
		| 
						 | 
				
			
			@ -204,22 +204,6 @@ static const dacsample_t dac_buffer[DAC_BUFFER_SIZE] = {
 | 
			
		|||
 | 
			
		||||
// squarewave
 | 
			
		||||
static const dacsample_t dac_buffer_2[DAC_BUFFER_SIZE] = {
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
 | 
			
		||||
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
 | 
			
		||||
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
 | 
			
		||||
  0, 0, 0, 0, 0, 0, 0,  0,  0,  0,  0,  0,
 | 
			
		||||
| 
						 | 
				
			
			@ -234,7 +218,23 @@ static const dacsample_t dac_buffer_2[DAC_BUFFER_SIZE] = {
 | 
			
		|||
   0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,
 | 
			
		||||
   0,  0,  0,  0,  0,  0, 0, 0, 0, 0, 0, 0,
 | 
			
		||||
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
 | 
			
		||||
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
 | 
			
		||||
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047,
 | 
			
		||||
  2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047, 2047
 | 
			
		||||
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
/*
 | 
			
		||||
| 
						 | 
				
			
			@ -565,11 +565,11 @@ static void gpt_cb8(GPTDriver *gptp) {
 | 
			
		|||
        bool end_of_note = false;
 | 
			
		||||
        if (GET_CHANNEL_1_FREQ > 0) {
 | 
			
		||||
            if (!note_resting)
 | 
			
		||||
                end_of_note = (note_position >= (note_length*16 - 1));
 | 
			
		||||
                end_of_note = (note_position >= (note_length*8 - 1));
 | 
			
		||||
            else
 | 
			
		||||
                end_of_note = (note_position >= (note_length*16));
 | 
			
		||||
                end_of_note = (note_position >= (note_length*8));
 | 
			
		||||
        } else {
 | 
			
		||||
            end_of_note = (note_position >= (note_length*16));
 | 
			
		||||
            end_of_note = (note_position >= (note_length*8));
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        if (end_of_note) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue