ADAU1467 booting 3 x AD1937 codec's

Hi there,

I'm working on a design with a central ADAU1467 DSP connected to 3 x AD1937 codecs so I can have 4 x balanced audio (mic/line) inputs and 24 balanced audio outputs.  I'm at the stage of considering the control.  I like how on the EVAL board for the ADAU1467 can self-boot from settings saved to the EEPROM; I will be replicating this functionality in our design.  My question is what to do with the AD1937 codecs.  I know I can control them individually via SPI using SigmaStudio.  But that doesn't really leave me with a "set and forget" option once the design is deployed. 

The EVAL-ADAU1467 manual alludes to having the DSP boot the codec but states "This configuration is beyond the scope of this user guide".  Can I get some assistance as to how I need to configure my ADAU1467 and 3 x AD1937's so the DSP can boot all three codecs? 

Will this allow the DSP and codecs to be configured from within SigmaStudio and utilise just the one SPI link?

If not, how can I have the 3 x AD1937's always boot up with the correct configuration; i.e. perform self-boot, to be running in the mode I want?

Thanks for your assistance!

Kind regards,

Mark

  • Hello Mark,

    I am making some assumptions here. The first is that you will be using a SPI EEPROM to seflboot because you need the selfboot to happen fast. 

    The AD1937 is an I2C device so if you want to use that part then you will have to split off the I2C Master port over to its own pins. This post talks about it. I am not certain if this has indeed been updated. 

    (+) ADAU1467 Dual Master Control Port - Q&A - SigmaDSP Processors and SigmaStudio Development Tool - EngineerZone (analog.com)

    If you want to have only SPI then you will have to use the AD1939 which is the same part but is a SPI controlled part. 

    Also, there are many posts about booting up the AD1938 codec. Those posts all apply and the XML examples would all work. All of these parts have the same register set and the same functionality. The differences are either with differential DAC outputs or the SPI verses I2C for the control interface. 

    This post has an example and XML file for booting an AD1938/AD1939 using SPI

    (+) Controlling AD1939 via master control port ADAU1452 - Q&A - SigmaDSP Processors and SigmaStudio Development Tool - EngineerZone (analog.com)

    Here is something else to read up on:

    Master Control Port Boot time I/O (ADAU145x) [Analog Devices Wiki]

    This post is a start. We will see what questions you have afterwards.

    Thanks,

    Dave T

  • Hi Dave, thanks for your reply.  I appreciate it.

    Yes, I've since realised that the AD1937 is an I2C device.  Ideally I'd have the ADAU1467 self-boot from EEPROM and also be responsible for booting the Codec's.  However, I'd need to first configure the 3 x codec's in the mode I want them to work.  So, I need 2 solutions.  

    1.  Configure the 3 codecs from SigmaStudio individually

    2.  have the ADAU1467 then use that configuration file to self-boot the 3 x codecs once the system is deployed.

    My circuit design currently incorporates 3 x AD1937's as I had received those as samples from our local supplier.  Maybe I'll have to update my design to use the AD1938's?  Does this sound like the easiest solution for me?  Could I then achieve my requirements above?

    Thanks for bearing with me.  Slight smile

  • Hello Mark,

    Look at this post:

    (+) Two AD1938 in daisy chain with ADAU1452 - Q&A - SigmaDSP Processors and SigmaStudio Development Tool - EngineerZone (analog.com)

    The post from Rocha shows how you configure the USBi in SigmaStudio. Since you are using I2C then just set them to different addresses in the USBi GUI. Then connect them all to the I2C clock and data from the USBi. 

    Then you will have different tabs for each codec on the SigmaStudio config page. Then you can setup each codec and once it is all working. All you need to do is this:

    1) Clear out the capture window.

    2) Go to the tab for one of the codecs, click on "Write Current Settings to chip". 

    3) Then click on the first command in the Capture window and "Shift-Click" on the last command to highlight all of them. Then hover over and right click and export them to an XML file. 

    4) Then you attach the XML file to the Startup boot cell where it asks for a sequence file. This info is detailed here:

    Master Control Port Boot Time I/O (ADAU145x) [Analog Devices Wiki]

    The entry in the Wiki for the single device boot actually has more information:

    Master Control Port Boot time I/O (ADAU145x) [Analog Devices Wiki]

    Dave T

  • Thanks, Dave! I'm going to be heading into uncharted waters now being all control signal stuff, but hopefully I can get there. 

    First thing is making sure I get the circuit design correct.  The post from Rocha shows the SPI as you noted.

    However, am I assuming I'll need one SPI latch from my USBi to the ADAU1467 (and another for my E2Prom) then another latch to the first codec, and then daisy chain the other two codecs to the first one?  Or do I need all 4 SPI latches to each codec independently (as per this image)?:

    Then do I also need the ADAU1467 pins 34 (SCL_M) and 35 (SDA_M) to daisy chain to the 3 x AD1937 codecs (pins 34 and 31; SCL & SDA respectively).  Each AD1937 would be configured with a separate I2C address assignment by configuring the ADDR0 & ADDR1 pins. I have set those pins on my 3 x codecs to (0,0), (0,1) and (10) in my circuit design.

    If you would prefer I can share snippets from my working schematic?

    Thanks again for your help!

  • Hello MDThommo81,

    This part has two basic ports, the slave port and the master port. Both can do I2C and SPI. 

    The slave port comes up in I2C mode and you need to send three dummy SPI writes to set it into SPI mode. This is the port that you use with the USBi to communicate with the part. There is a SPI latch for the slave port and only one. 

    The master port has the ability to be SPI or I2C but it can split off the I2C port using the multi-function pins so that you can use SPI and I2C at the same time with the master port. Well, you can only use one at a time but you can have both in your system. 

    There is a SPI latch pin on the master port that you must connect over to the SPI EEPROM and you also must set the selfboot mode to be SPI. This will allow you to boot up off of the EEPROM

    The AD1937 parts will have the SDA and SCL pins connected to each of the AD1937 codecs in parallel. The pins you use will depend on which assignable pins you are using for I2C. So it will not be the ones listed as SDA_M or SCL_M. Those will be used for their SPI port functions. 

    You will need to have some pull-up resistors on the I2C bus. The addressing is done in the I2C first byte so the DSP will just do that with no extra pins needed. You are correct that you will need to set each of the codecs to its own address so that the DSP can talk to each on its own. I2C does not require latches. 

    On the USBi GUI you will need to set each one to the correct address to coincide with the pin settings on the AD1937 parts. In the screenshot they are all set to the same address. 

     Dave T