Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 01/19/2015 in all areas

  1. Hi mwpost! Unfortunately I didn't had the time this week end to test my old pga pcb with MIOS32 (I have an LPC17 board, not STM32F4, but it shouldn't be a big difference for this). What you could do, is to try to set the gain without the encoder first (comment or remove the code setting the gain in the encoder callback). just add this function in your c file : void SetPGAGain(u8 leftGain, u8 rightGain) { MIOS32_SPI_RC_PinSet (2,0,0); MIOS32_SPI_TransferByte(2, mios32_dout_reverse_tab[rightGain]); // right MIOS32_SPI_TransferByte(2, mios32_dout_reverse_tab[leftGain]); // left MIOS32_SPI_RC_PinSet (2,0,1); } and for example in APP_Background void APP_Background(void) { SetPGAGain(0, 0); while (1) { } } When you start the application, you should hear no sound at all (0 is the special value for MUTE). Then try for example SetPGAGain(32, 32); etc and then with other values, and see how it behave. It might help to understand what is going on by just changing the value once. There's no "useless hobby" :smile: I was very excited by the PGA at that time, I ordered some, made a quick board, wrote the code for MIOS... and when it worked, I though "Cool, I need to put it in a very cool project!", and I haven't touch it since... (like so many other "project" I started)
    1 point
×
×
  • Create New...