This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

WEC7 AM335x Volume Control with SGTL5000

We are using a system with an AM335x processor running windows CE7 based on the TI BSP.  The problem I'm having is that the volume control in the system control panel is not working.  If I use the media player and adjust volume it works just fine. 

I've modified the sgtl5000.cpp in the bootloader to change volume on startup, and that gets written over I2C to the sgtl5000 chip on startup, but there is never any more traffic over the I2C bus to change volume, either in the control panel or in the media player. 

I see two possible solutions:

1) Get the volume control in the control panel to work.

2) Write to the I2C bus using a pinvoke call and change the volume directly.

Has anyone else had this problem? 

Is there an example anywhere of writing to the I2C bus using managed code (VB.net or C#)?

  • There is a sample program testi2c.exe from TI that came with the BSP.  The source code is at C:\WINCE700\platform\AM33X_BSP\SRC\test\testI2c, take a look at the Outi2C subroutine, it forces the number of bytes written to 1. 

    With a slight change to the OutI2C subroutine, I now have control over the I2C bus and also the audio volume.