TF CD32 Riser Revision 3 Design discussion

TF CD32 Riser

Moderators: terriblefire, Terriblefire Moderator

User avatar
arkadiusz.makarenko
Moderator Team
Moderator Team
Posts: 1208
Joined: Wed Jun 19, 2019 7:36 am
Location: Edinburgh

Re: TF CD32 Riser Revision 3 Design discussion

Post by arkadiusz.makarenko »

terriblefire wrote: Wed Feb 10, 2021 10:34 pm
arkadiusz.makarenko wrote: Wed Feb 10, 2021 10:22 pm I have mp3 decoder working, reading from fifo and outputing values.... it is not timed correctly and ouput is just rubbish but it decodes info, now need to understand what to do with it, as it is in stereo 16bit signed value.
Anyway I was happy to see this
20210210_220755.jpg

Time to sync everything and check if there is enough RAM on stm32 to make it sound right.
sweet.. :D

I will find some time to do the eagle changes for you soon.. have house viewings right now
There is still a lot of life left on Rev 2.
I will move posts back to rev 2 thread.
Do not trust people. They are capable of greatness.
~ Stanislaw Lem
User avatar
arkadiusz.makarenko
Moderator Team
Moderator Team
Posts: 1208
Joined: Wed Jun 19, 2019 7:36 am
Location: Edinburgh

Re: TF CD32 Riser Revision 3 Design discussion

Post by arkadiusz.makarenko »

I have a some issues. I can decode mp3 to 16bit signed PCM, now how to squeeze it to 12-bit dac with right voltage levels. Data can be 8bit Right aligned, 12 bit Left or right aligned. Need to figure it out. This would allow me to fully sync communication and decoding. This is to judge if there is enough resources to do it right.

Anyway if this idea would be properly continued I can't see it without expanding it to 16bit CD quality DAC with right analog circuit.
Do not trust people. They are capable of greatness.
~ Stanislaw Lem
User avatar
arkadiusz.makarenko
Moderator Team
Moderator Team
Posts: 1208
Joined: Wed Jun 19, 2019 7:36 am
Location: Edinburgh

Re: TF CD32 Riser Revision 3 Design discussion

Post by arkadiusz.makarenko »

Got basics. Just don't get why timer need to be set up 4 times to keep up qith right speed as it should be 44.1k
Anyway most important bits, amiga buffer most time is 75% full, so no underfill.
Next step TIM->DMA->DAC.
Do not trust people. They are capable of greatness.
~ Stanislaw Lem
User avatar
arkadiusz.makarenko
Moderator Team
Moderator Team
Posts: 1208
Joined: Wed Jun 19, 2019 7:36 am
Location: Edinburgh

Re: TF CD32 Riser Revision 3 Design discussion

Post by arkadiusz.makarenko »

I managed to do basics, but sound quality is simply not there.
Important bits. Data speed is there, there is even enough RAM in stm32 f7 series to handle it (including other functions),
MP3 decoding actually is simple, issue is to set up project to include SpiritMP3 libraries. There is so much resource on chip that I had to limit it as buffers were overrun constantly (even with stuff already on there, so many IRQs and USB handling)
Issue is in output, DAC outputs values as for base voltage, which are far from ideal for audio output.
I can't see decent results would be possible without external circuit to what is available on Rev2.
This is how far I can go for now.
Do not trust people. They are capable of greatness.
~ Stanislaw Lem
terriblefire
Moderator Team
Moderator Team
Posts: 5368
Joined: Mon Aug 28, 2017 10:56 pm
Location: Glasgow, UK

Re: TF CD32 Riser Revision 3 Design discussion

Post by terriblefire »

arkadiusz.makarenko wrote: Fri Feb 12, 2021 7:52 pm I managed to do basics, but sound quality is simply not there.
Important bits. Data speed is there, there is even enough RAM in stm32 f7 series to handle it (including other functions),
MP3 decoding actually is simple, issue is to set up project to include SpiritMP3 libraries. There is so much resource on chip that I had to limit it as buffers were overrun constantly (even with stuff already on there, so many IRQs and USB handling)
Issue is in output, DAC outputs values as for base voltage, which are far from ideal for audio output.
I can't see decent results would be possible without external circuit to what is available on Rev2.
This is how far I can go for now.
issue is arm is 12 bit dac?
———
"It is not necessarily a supply voltage at no load, but the amount of current it can provide when touched that
indicates how much hurting you shall receive."
User avatar
arkadiusz.makarenko
Moderator Team
Moderator Team
Posts: 1208
Joined: Wed Jun 19, 2019 7:36 am
Location: Edinburgh

Re: TF CD32 Riser Revision 3 Design discussion

Post by arkadiusz.makarenko »

terriblefire wrote: Fri Feb 12, 2021 7:55 pm issue is arm is 12 bit dac?
I think it is more complex. DAC returns 0 - 3.3V range divided in 12bits. I assume it is far from ideal for audio.
MP3 decoder returns 16bit signed values, which I transform to 16 unsigned and then whatever I do with it I need to cut it to audio range (which in calculations result in as far as I understand lower resolution.


In my language: I can process data no issues there, but when I DAC it is sounds bad whatever I do with it.
Do not trust people. They are capable of greatness.
~ Stanislaw Lem
terriblefire
Moderator Team
Moderator Team
Posts: 5368
Joined: Mon Aug 28, 2017 10:56 pm
Location: Glasgow, UK

Re: TF CD32 Riser Revision 3 Design discussion

Post by terriblefire »

arkadiusz.makarenko wrote: Fri Feb 12, 2021 8:31 pm
terriblefire wrote: Fri Feb 12, 2021 7:55 pm issue is arm is 12 bit dac?
I think it is more complex. DAC returns 0 - 3.3V range divided in 12bits. I assume it is far from ideal for audio.
MP3 decoder returns 16bit signed values, which I transform to 16 unsigned and then whatever I do with it I need to cut it to audio range (which in calculations result in as far as I understand lower resolution.


In my language: I can process data no issues there, but when I DAC it is sounds bad whatever I do with it.
Needs an Amp i guess.
———
"It is not necessarily a supply voltage at no load, but the amount of current it can provide when touched that
indicates how much hurting you shall receive."
User avatar
arkadiusz.makarenko
Moderator Team
Moderator Team
Posts: 1208
Joined: Wed Jun 19, 2019 7:36 am
Location: Edinburgh

Re: TF CD32 Riser Revision 3 Design discussion

Post by arkadiusz.makarenko »

terriblefire wrote: Fri Feb 12, 2021 8:36 pm
Needs an Amp i guess.
And that is the thing, if it needs additional chip anyway then why not to use specialised audio dac with all the bells and whistles, like PCM5102, and use arm for data stuff...
Do not trust people. They are capable of greatness.
~ Stanislaw Lem
terriblefire
Moderator Team
Moderator Team
Posts: 5368
Joined: Mon Aug 28, 2017 10:56 pm
Location: Glasgow, UK

Re: TF CD32 Riser Revision 3 Design discussion

Post by terriblefire »

arkadiusz.makarenko wrote: Sat Feb 13, 2021 6:51 am
terriblefire wrote: Fri Feb 12, 2021 8:36 pm
Needs an Amp i guess.
And that is the thing, if it needs additional chip anyway then why not to use specialised audio dac with all the bells and whistles, like PCM5102, and use arm for data stuff...
You might also need an amp after that?
———
"It is not necessarily a supply voltage at no load, but the amount of current it can provide when touched that
indicates how much hurting you shall receive."
User avatar
arkadiusz.makarenko
Moderator Team
Moderator Team
Posts: 1208
Joined: Wed Jun 19, 2019 7:36 am
Location: Edinburgh

Re: TF CD32 Riser Revision 3 Design discussion

Post by arkadiusz.makarenko »

terriblefire wrote: Sat Feb 13, 2021 9:14 am
arkadiusz.makarenko wrote: Sat Feb 13, 2021 6:51 am

And that is the thing, if it needs additional chip anyway then why not to use specialised audio dac with all the bells and whistles, like PCM5102, and use arm for data stuff...
You might also need an amp after that?
Don't know, I just looked at Raspberry Pi HIFI solutions.
Output is Direct Line Level 2.1-VRMS. Whatever it means.

Anyway I will try to understand it a little bit more.

Maybe there is enough data bandwidth to send decoded data back to Amiga and play it from there?
Do not trust people. They are capable of greatness.
~ Stanislaw Lem
Post Reply

Return to “TF CD32 Riser”