Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

which info is stored in the voicehat.eep file? #3

Open
nivw opened this issue May 12, 2018 · 7 comments
Open

which info is stored in the voicehat.eep file? #3

nivw opened this issue May 12, 2018 · 7 comments

Comments

@nivw
Copy link

nivw commented May 12, 2018

Hi Sid,
I am looking to use a microphone and a speaker with I2S, as you did here.
I found little info on the web, on how to achieve this, and many folks asked about it.
So I looked to see what you used in your voicehat.eep.
I read This and can understand the first part of the eeprom:

hexdump -C voicehat.eep
00000000 52 2d 50 69 01 00 02 00 7c 00 00 00 01 00 00 00 |R-Pi....|.......|
00000010 40 00 00 00 5e 69 95 06 36 73 da 92 91 42 be 31 |@...^i..6s...B.1|
00000020 52 b7 df 0d 01 00 01 00 0c 1c 47 6f 6f 67 6c 65 |R.........Google|
00000030 2c 20 49 6e 63 2e 47 6f 6f 67 6c 65 20 41 49 59 |, Inc.Google AIY|
00000040 20 61 75 64 69 6f 48 41 54 20 42 6f 61 72 64 20 | audioHAT Board |
00000050 76 31 92 90 02 00 01 00 20 00 00 00 00 00 00 00 |v1...... .......|
00000060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000070 00 00 00 00 00 00 00 00 00 00 ed 6e ff ff ff ff |...........n....|
00000080 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff |................|
*
00001000

Your vendor info atom data is clear, but I don't understand the GPIO and the device tree. in facat I see no device tree 0x0003 type at all.
So what is the GPIO setup and what device tree do you use?
Thank you very much for sharing this great project.
Niv

@diabl0w
Copy link

diabl0w commented Aug 14, 2020

hi, did you ever get this to work? I am trying to get the microphones and speaker output over i2s at the same time, but my speakers arent working. I can't tell if its a wiring issue or an eeprom issue or a kernel limitation issue

@shivasiddharth
Copy link
Owner

@diabl0w I am still using the same custom hat even after so many updates and upgrades to the OS. I first flashed the EEPROM before wiring anything. And then went through the audio setup process. At this point if the flashing was done properly, you should see the DAC listed when you use the asound -l and arecord -l commands. Also, you should see the device tree. Only after verifying this you should wire the parts. I have shown this all in the video attached in the README.

@shivasiddharth
Copy link
Owner

@diabl0w
Copy link

diabl0w commented Aug 14, 2020

@diabl0w I am still using the same custom hat even after so many updates and upgrades to the OS. I first flashed the EEPROM before wiring anything. And then went through the audio setup process. At this point if the flashing was done properly, you should see the DAC listed when you use the asound -l and arecord -l commands. Also, you should see the device tree. Only after verifying this you should wire the parts. I have shown this all in the video attached in the README.

Thank you so much! I got it working and I am loving it! One problem I am having:

If I use a pcm5102a DAC both microphone and speaker work great! However, I wanted to use a better DAC, so I tried using an "Allo Boss" clone. If I use that, i only either get microphone or speaker, never both. Because the Allo Boss requires its own "dtoverlay", so whatever one i put second in "/boot/config.txt" works. The AlloBoss does not have its own eeprom, but it does use SDA/SCL, but at a different address (0x4d) and not our address of 0x50

EDIT: For clarification, I mean i got your original project working, but thanks for that other link anyways. But these issues I am discussing are still for the original project

@diabl0w
Copy link

diabl0w commented Aug 14, 2020

Okay, I think I know the issue. The issue is that the Allo Boss uses PCM5122. The PCM5122 can use i2s either over the actual i2s interface or i2s via spi. The allo boss has it configured to use the native i2s-1 pins (pins 3 and 5 on pi). The PCM5102 on the other hand uses i2s over spi.

So, that is the problem, but I do not know the solution. Can our hat coexist with the allo boss both using actual i2s? Or I can pull one of the headers on the Allo Boss to high which will make it work in spi mode like the pcm5102.

Id rather not have to modify the Allo Boss board

@shivasiddharth
Copy link
Owner

Do check the pinout for that Allo DAC to see if there is any overlap with the Mics. You cna use other DACs like pHAT DAC, etc. I have tested it and it works. https://www.youtube.com/watch?v=m2aSVqBKY4Y

@diabl0w
Copy link

diabl0w commented Aug 14, 2020

pHAT DAC

yes, that is because that dac also uses the "PCM5102". The issue I am running into is that the Allo Boss uses a PCM5122, which despite the similar name, operates very differently. To add more complexity, the allo boss also has its own master clock, instead of using the raspberry pi's. I think the solution would be creating a custom dtoverlay/dts. Unfortunately, that is over my head of knowledge. But thank you for your help, I am still quite satisfied with the setup you provided :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants