-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
greatunclebulgaria Nov 29, 2013 4:51 AM (in response to cy.wbz)Matt,
Thanks for this post, looks very interesting, BUT I'm having trouble with the hardware connections.
POSC4 P5LP header Pin POSC4 P5LP header Name AK4556 J6 Header AK4556 Pin Number CS42L51 CS42L51 Pin VDD 1 P5 VDD J6-35/36 4/5 5/12/27 I2C_SCL 2 P1.2 PSOC_CODEC_I2C_SCL 3 – SCL/CCLK PDM_DATA 3 P0.0 LRCLK 4 P0.1 J6-15 (P5-3) 14 - LRCK TP113 – CODEC_LRCLK 1 - LRCK PDM_LR_SEL 5 P3.4 SCLK 6 P3.5 J6-13 (P5_5) 16 - BCLK TP112 – CODEC_SCLK 31 - SCLK CODEC_RST 7 P3.6 TP111 – CODEC_RST 25 - RESET SDTO 8 P3.7 J6-11 (P5-7) 8 - SDTO TP115 – CODEC_SDTO 29 – SDOUT/M/S PDM_CLK 9 P12.6 MCLK 10 P12.7 J6-12 (P5_6) 15 - MCLK TP110 – CODEC_MCLK 30 - MCLK GND 11 GND J6-37 3 13/28 I2C_SDA 12 P3.0 PSOC_CODEC_I2C_SDA 2 – SDA/CDIN TP114 – CODEC_SDTI As you can see I am unable to match up all the pins to the CS42L51, and am not entirely sure of the AK4556 pin connections.
I'm surprise you used a CODEC with limited availability, and not board support.
After a quick Google I found Audio Codec PROTO - Development Board with WM8731 Audio Codec which I think does all you are doing with the codec, and is available on a development board in the States for $19?!?
Nice idea, and nice code, but I'm surprised and disappointed by your choice of hardware.
OR MAYBE I'M MISSING THE POINT?
Thanks for all the projects, I've been following since before the 100 days projects, and have a PSoC4 and many of the shields you have demo’ d.
Well done
Thanks
David
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
cy.kris Dec 5, 2013 1:38 PM (in response to greatunclebulgaria)2 of 2 people found this helpfulDavid,
Thanks for your interest with this example project. The pins that are left are the PDM microphone module connections. PDM microphone (ADMP521Z EVAL) is a separate module and is not part of CS42L51 or AK4556 codecs.
Sorry about using a codec hardware that is not readily available in the market. We couldn't find a codec only development board/shield that suits our requirements.
We looked at the Wolfson Codec proto board, it doesn't accept an external I2S master clock (which is required for synchronous USB audio implementation) and we couldn't use it for the demo.
In theory, this example project will work with any codec that supports the following features:
- 24-bit I2S slave interface (PSoC 5LP is the I2S master)
- Accept external I2S master clock (PSoC 5LP supplies the I2S master clock that is in sync with USB SOF) of 256 * Fs (Fs = audio sampling frequency)
-Krishna
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
cy.roit Dec 6, 2013 6:23 AM (in response to cy.wbz)2 of 2 people found this helpfulThe PSoC 5LP USB Audio example project offers a great way to do a general USB Audio solution.
Here, I would like to add that if somebody is looking particularly for native MFi USB audio solution for Apple Devices (not through Camera Connection Kit), then Cypress provides full support through their kit CY8CKIT-033A. Any MFi Licensee can order this kit as well as the installer package (containing example projects, documents and schematics) through MFi Avnet website.
-Rohit
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
cy.roit Feb 10, 2014 3:41 AM (in response to cy.roit)2 of 2 people found this helpfulFor the interest of members who wants to understand the implementation of the PDM audio path, this solution provides a single chip audio path implementation for converting 1-bit PDM input signal to PCM signal (which includes PDM clock generation, PDM Data sampling, DMA data transfer, integrator, decimator and droop correction filtering) and transfer the resultant PCM samples over USB audio class interface to a USB host device.
This audio path implementation uses PSoC's UDB and DMA engine to process and transfer the microphone data, minimizing the CPU overhead and providing a high quality low power PDM microphone interface.
For more details on implementation, see this article: http://edn.com/design/consumer/4425878/High-quality-PDM-microphone-interfacing-using-off-the-shelf-SoCs
-Rohit
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
dandumit Apr 27, 2014 12:49 AM (in response to cy.roit)Hi,
I have landed on this page searching for PSoC4 and DMA. Unfortunately (for me) it seems that you are using PSoC5.
Could you please confirm that PSoC4 has no DMA?
BR,
DAniel
-
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
yourskp Apr 30, 2014 4:00 PM (in response to cy.wbz)2 of 2 people found this helpfulThe PSoC Creator project attached to the original post doesn't work with PSoC Creator 3.0 SP1 (It was build with PSoC Creator 2.2 SP1). I have made minimal changes to the original project (updated Cy_boot component only) to make it build with PSoC Creator 3.0 SP1.
The updated project is attached here and is also @ GitHub - https://github.com/yourskp/PioneerKit_P5LP_USB_Audio
I recommend not to update other components, as we haven't tested the project with all the latest PSoC Creator 3.0 SP1 components.
-Krishna
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
alwynallan Dec 3, 2014 9:37 AM (in response to yourskp)The project compiles fine with the latest version of PSoC Creator and appears to work (I'm using PowerfulBoard, not Pioneer Kit). However, when the components are updated to their latest versions, the project fails: the USB device continually disconnects and then tries to enumerate again on Windows 7 Pro 32-bit. Any idea what is causing this and how to fix it?
Thanks for sharing this work. It's much easier than starting with the datasheets.
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
alwynallan Mar 31, 2015 3:58 AM (in response to alwynallan)1 of 1 people found this helpfulI solved this problem with help from Pavan at Cypress:
Which component version you are updating to ? If it is v2.7, please do the below modification.
This is because we have added a workaround for a known issue. But in v2.7, it is fixed in the component itself.
1) Go to file – “USBiAP_episr.c”
2) Search for Interrupt function – “USBiAP_ARB_ISR”
3) Comment out the lines of code available inside comment section –
/* `#START ARB_BEGIN_USER_CODE` Place your code here */
/* `#END` */
4) Comment out the #endif available inside comments –
/* `#START ARB_END_USER_CODE` Place your code here */
// #endif
/* `#END` */
5) Build the project your project should work with USB component version 2.7.
That file is one of hundreds in the "Generated Source" folder.
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
cyaniccypher May 19, 2017 5:19 PM (in response to yourskp)I was able to get this to work, but what needs to be done to get 96kHz and 24bit, I am only able to get up 48khz sampling rate. Thanks.
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
minngocbg1 Jan 15, 2015 7:44 PM (in response to cy.wbz)why when i bootloader for kit, the bootloader report : PID is 0xF139 not 0xF13B
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
clem57Jan 17, 2015 12:18 PM (in response to minngocbg1)
Good question by the way. The PID(product identification) usually has a family or version. Without specifics, I would say the first part does not change(family byte), but the second byte will with a new version.
Clem
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
minngocbg1 Jan 19, 2015 2:05 AM (in response to cy.wbz)How i'm bootloader with that PID? When I click program bootloader report : The data does not expect value
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
cy.gul Jan 22, 2015 10:41 PM (in response to minngocbg1)2 of 2 people found this helpfulhold down the reset button on the kit while plugging it into USB.
the status LED on the board goes to a blinking state, indicating that you have entered bootloader mode.
after this you should be able to see the correct PID in the Bootloader Host Tool
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
minngocbg1 Jan 22, 2015 11:06 PM (in response to cy.wbz)Who are have datasheet of PDM_CIC ?
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
julian168 Mar 31, 2015 1:00 AM (in response to cy.wbz)Can there anybody tell me where to buy the overall package of "PSoC 4 Pioneer Kit Community Project#102"? Thanks!
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
clem57Mar 31, 2015 2:24 AM (in response to julian168)
1 of 1 people found this helpful -
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
julian168 Mar 31, 2015 3:15 AM (in response to clem57)Hi Martins,
Thanks for your feedback!
However, I need to buy the whole package inside the top chart of arthur's article. Is there any dedicated shop?
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
clem57Mar 31, 2015 3:46 AM (in response to julian168)
1 of 1 people found this helpfulThe audio codec board is limited availability (Prototype). After a quick Google I found Audio Codec PROTO - Development Board with WM8731 Audio Codec which I think does all you are doing with the codec, and is available on a development board in the States for $19?!?
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
dave4psoc Oct 12, 2015 4:42 AM (in response to clem57)I got Error with USB boot loader when using the CY8CKIT-059CY8CKIT-059 PSOC-059 PSoc
Please help to have Bootloader on the PSOC 5LP Prototype board
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
hasan2015 Jun 4, 2017 11:36 PM (in response to clem57)Hello,
I need a cheap USB ic which can work with a PDM microphone.
Need a CODEC usb support kit where Headset is for microphone output. The microphone we gonna use is MEMs one.
Hope you help me.
-
-
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
cmydlarz Oct 2, 2015 1:31 PM (in response to cy.wbz)Im using a slightly edited version of the provided example code built to run on the CY8C5667LTI-LP009 MCU. I have a custom board using a PDM output digital mic running into the MCU. I programmed the MCU using the MiniProg3 over SWD with the Cypress Programmer 3.23.1 and it all seemed to go smoothly. However, when I plug in the board via USB to a mac or PC the thing doesn't enumerate. Does anyone have any nuggets of info on why this might be happening?
Is there some special way to program the MCU so that it will enumerate as a USB audio device or should it work when programmed the way I mention?
Any help would be much appreciated and virtual beer tokens can be sent!
Charlie
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
cyaniccypher May 19, 2017 5:20 PM (in response to cy.wbz)I got this to work with one of cypress' other eval boards, but I am not able to get 96kHz sampling rate, what do I need to change in the project?
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
olsond3 Jun 12, 2017 9:36 PM (in response to cy.wbz)It would sure be great to get this updated to work with the latest version of Creator. I tried to build using Creator 3.3 and it was ugly. I would rather not load another old version just to run this project.
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
1s2d3d54f4 Feb 8, 2018 10:00 AM (in response to cy.wbz)Is there a good reason why Cypress code always uses global variables for everything instead of using limited-scope variables, parameters and returns, etc.? And contains unnecessary comparisons like if (codecInit == TRUE) instead of if (codecInit), uses function-like macros instead of inline functions, defines macros like TRUE instead of using stdbool.h types, etc.?
To read through the code and understand how it works, I constantly have to do a project-wide search for each variable and try to remember every other function that modifies it, and it's frustrating. Every source I've found says these practices should be avoided, but maybe the rules are different for embedded code? I want to change them all to make them more readable, but I'm afraid there's some reason they were done this way. Do these practices help with optimizing code size or preventing stack overflows or something? Or are they just bad programming?
-
Re: PSoC 4 Pioneer Kit Community Project#102 – USB Audio using the PSoC 5LP
ralphrmartin Nov 24, 2018 5:13 PM (in response to cy.wbz)Could the PDM-CIC component be added to the Cypress Component Library for PSoC 5LP? There is one, but annoyingly, it seems to only be for PSoC 6??!!
Hello!
In today’s example we are including a demonstration project for supporting Audio playback and audio recording using USB digital audio. The PSoC 5LP communicates with any USB host, provides a high-quality recording interface to it, and extras high-quality digital audio from the USB host. In this example we show the PSoC 5LP device communicating to:
- Windows
- Mac
- Linux
- Android
- Raspberry Pi
- BeagleBone Black
- Android
- iOS
This example project utilizes the PSoC 5LP device on the PSoC 4 Pioneer Kit. This example has the following features:
- Audio-out (I2S)
- Audio-in (PDM Mic)
- USB Host Interface
- Volume Control
- Watchdog
The firmware was designed and tested with PSoC Creator 2.2 SP1.
Forum Post Attachments:
At the bottom of this post we are including the following items:
- Example Project Zip File
- Project Images
- Example Documentation
Components Used:
The user can download the example project at the bottom of this post. The project uses the following list of Creator Components:
- I2C
- EZI2C
- SPI
- UART
Firmware Description:
The main.c firmware is included in the example project. Please review the commented sections for more details.
Attached to this example project is a detailed example description. In this file we include a detailed write up of the external hardware used in the example, the internal firmware architecture, and how to recreate the system on your own. Please feel free to review this document for a detailed understanding of how the example is designed and used.
We are also listing the custom components, hardware, and firmware files necessary to create this example. Please feel free to download the zip file for more information.
Hardware Connections:
The hardware connections are detailed in the attached zip project. We include the codec board schematics in the documentation folder.
Test Your Project:
Please see the below image of the example in action.
I hope this example can help you in your design.
Best,
Matt