Post Go back to editing

DSP selfboot following USBi and EVAL-ADAU1452REVBZ codec control modification

Thread Summary

The user asked if the EVAL-ADAU1452REVBZ board can still self-boot after modifying it to control the AD1938 codec independently. The final answer confirms that while the DSP will self-boot successfully, the codec registers will not be automatically initialized. To achieve this, the codec must be programmed via the Master Control Port or by connecting an additional slave select from USBi to the codec.
AI Generated Content
Category: Hardware
Product Number: eval-adau1452revBZ, adau1452

Hi there, I made the hardware modification to my EVAL-ADAU1452REVBZ board to explore the independent control of the AD1938 codec, however something that's not obvious (to me) in reading about this modification in UG-1662, and that is "following making the hardware modifications, can I still use my evaluation board in selfboot mode with following the usual method of downloading to the EEPROM after a link-compile-download"?  I assume now that my codec registers won't actually be changed during the selfboot process anymore. Is this assumption correct?

Many thanks!

Mark

Thread Notes

Parents
  • Hello Mark,

    You have two options; you can either program the codec by USBi or by DSP (master control port).

    I would like to confirm the expected behavior of the EVAL-ADAU1452REVBZ evaluation board after performing the hardware modification described in UG-1662, which isolates the control of the AD1938 codec from the ADAU1452.

    After this modification, you can program the DSP and the CODEC from the USBi by using two different slave selects which gives you additional control over the CODEC, you can change sample rate, audio formats, muting etc. from USBi via SS. Everything will be fine until now.

    If you plan to self-boot from EEPROM then you need to be careful.

    Now the DSP and CODEC is running properly after being programmed from USBi, once you write your program to the EEPROM, it will be written successfully, and it will be self-booted successfully. However, to initiate the self-boot process, you would have to trigger a reset by pressing the reset button. This action will activate the reset generator, which will reset both the DSP and the codec, as shown in the diagram below.

     

    Once you press reset, the DSP will fetch the code from EEPROM and will run the code properly (you can see any LED blink will work fine), but you won't be able to hear any audio since the codec registers are wiped out by the reset.

    Expected Behavior of above block diagram:

    • The ADAU1452 will self-boot successfully after pressing the reset button.
    • The AD1938 codec will no longer have its registers automatically initialized during the self-boot process, as the standalone mode configuration has been removed due to the modification.

    Booting codec from DSP:

    If you wish to use self-boot alongside the AD1938, the AD1938 can be controlled through the Master Control Port. Please refer to the diagram below for this setup. Here you don't have a continuous runtime control over the codec, you configure the codec as you want and export the files and send it from DSP to boot the codec.

    Here is the schematic

    1) Design your signal flow and place the startup boot module in the top of the program and config it properly.

    2) write latest compilation thru DSP (do the self-boot process)

    3) once it's done, connect the master control port SPI pins to codec SPI pins. I used LRCLK_IN2 as slave select.

    4) Turn on self-boot switch and hit reset. The codec will be programmed (from DSP) and will be running on pre-configured function.

    0871.CODEC_boot_48KHz_master port.zip

    Other method:

    One other thing that you can do is, you can design your signal flow and write that to EEPROM and make the DSP self-boot from the EEPROM (same self-boot procedure) and once it's self-booted and running (codec isn't programmed due to reset press, so audio won't be heard)

    1) Now you connect the USBi into the control port and the additional slave select from USBi to the codec Slave select. 

    2) create a new project with AD193x and configure the codec settings and link compile download, now the codec will be programmed and controlled in runtime, now you can pass audio signals.

    This gives runtime control over the codec after the DSP is self-booted. So, you can follow which is suited for your requirement.

    Please let me know if you have any further questions or if you need additional details on this modification.

    Regards,

    Harish

  • Hi  , just circling back to this again.  I'm now keen to move onto your proposed solution for "Booting Codec from DSP". We have hit a snag and can't seem to get it working yet...

    I see from the SigmaDSP file you provided that you've configured MP5 as an output which correlates with LRCLK_OUT1/MP5. You note in your response that "LRCLK_IN2 as slave select", can you elaborate on this?

    Also, the cabling connections in your photo aren't very clear, could you perhaps list out the source and destination on the EVM for each of those cables?  We tried connecting this up, but no success yet.

    In the SigmaDSP schematic you have 3 blocks controlling the codec self-boot.  1. ControlPort11, 2. Pulse1, and 3. GPO1.  Can you explain how the Pulse block works, and why 30% was input to that block?  How does the Control Port function with this pulse and GPO block? 

    Many thanks,

    Mark

  • Hello Mark,

    It seems you got confused a little. Let me clear things up.

    The MP5 is a GPIO pin which is connected to the LED on my Eval board, and pulse drives the LED output. So, it's a heartbeat signal to verify if the DSP self-boots correctly. The 30% is the duty cycle of the pulse signal. It has no relation with the master control port.

    Then the LRCLK_IN2 is MP12 pin, and I configured it as slave select. Please have a look at below, you can see I configured the MP12 to be a slave select number '1' and I also set this master control block to use slave select '1'. so, it maps correctly.

    Reg the board setup, as you can see, I have taken out the master control port's SPI pins (near reset button) named as SCLK_M,MOSI_M,MISO_M and also codec SPI pins near the switch.

    The Blue wire is the slave select, which is connected from MP12 (LRCLK_IN2 on the header) to the Codec's slave select (Latch). The DSP is driving the slave select via the MP12 pin.

    The Red wire is serial clock, which is connected from SCLK_M to AD1938_CCLK.

    The orange wire is MOSI, which is connected from MOSI_M to AD138_CDATA. 

    By using these SPI lines, the DSP programs the codec from the master control port.

    This SPI configuration and transaction will happen when the DSP self-boots and start executing the program. Since we used startup boot, the DSP first executes this master control port block and program the codec and then it starts executing the audio processing flow. where the audio processing blocks runs every sample period, this startup boot is executed only once at the start.

    So, before writing this program to EEPROM, first verify if the codec is programmed properly and the audio is playing with Sigma studio (USBi), once everything is working then you can write to EEPROM.

    Regards,

    Harish

  • Hi  thank you for the response this helps to clarify things. So I think this implies that the jumpers added from the ADAU1452 slave SPI control port to control the codec via the USBi should be removed, if we wish to boot the codec from the ADAU1452's Master Control Port? 

    I will try this out tomorrow and let you know how it goes.


    Thanks

    James

  •  Hi     playing along at home, confirming success on this end with getting the AD1938 to self-boot along with the ADAU1452 using the Master Control port. The reason I couldn't get it working before was simply confusion regarding the connections between the ADAU1452 and the codec, I didn't pick up initially that the "Booting Codec from DSP" solution connects SCLK_M and MOSI_M to the AD1938, rather than SCLK and MOSI (as in the USBi control scenarios). Thanks!

  • Excellent,   glad to hear you got it working now!  And thank you  !!

Reply Children
No Data