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

Unused CLK has been deleted, increased frequency for the screen and mic #189

Merged
merged 2 commits into from
Nov 11, 2024

Conversation

oVadim
Copy link
Contributor

@oVadim oVadim commented Nov 9, 2024

For Gowin, 27 Mhz. Unused CLK in lcd_800_480 has been deleted, also where it was used. The released clkout is prepared to adjust the frequency of 48 kHz for sound modules, 391.5/64. Increased the frequency for LCD, 48.937 MHz. Increased the frequency for the microphone from 1.6 to 2.4 MHz.

@anton-malakhov
Copy link
Contributor

hmm.. CI needs to be fixed to run - I dunno why it is not triggered

.clkout ( lcd_module_clk ), // 200 MHz
.clkoutd ( LCD_CLK ), // 33.33 MHz
.clkin ( clk ) // 27 MHz
.clkout ( lcd_module_clk ), // 391.5 MHz
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Это нужно обсудить. Зачем тут 48 MHz и тем более 391? В примерах от говина такого нет TangNano-20K-example/rgb_lcd/lcd_800_400/color_bar/src/gowin_rpll/gowin_rpll.ipc

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Проверил на 5' LCD, на 49 мгц работает хорошо. Эту частоту можно использовать там, где у других плат 50 мгц. 391 мгц (она пока не используется) - я хотел получить стандартную частоту для звука 48 кгц, чтоб можно было записывать, передавать и воспроизводить готовые файлы (391/64 /6/2 /64). Для существующих лаб это пока неактуально. У HDMI потом можно сделать 391/2 и 391/2 /5 двумя делителями. И сделать одновременный вывод на HDMI и LCD.

Copy link
Owner

@yuri-panchul yuri-panchul Nov 11, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Проблема тут вот в чем. При приеме данных из микрофона в модуль lab_top может возникнуть метастабильное состояние (из домена 50 MHz в домен 27 MHz). Можно конечно и главный дизайн сделать на такой частоте 50 MHz - тогда проблема метастабильного состояния снимается. И вообще сделать все платы у которых 27 MHz clock - с clock на 50 MHz (правда потом непонятно не вылезет ли у нас negative slack где-нибудь).

См. http://www.sunburst-design.com/papers/CummingsSNUG2008Boston_CDC.pdf

Что касается HDMI так оно уже работает с IP от производителя.

Но если вы хотите экспериментировать в рамках одной платы 20k, то я в принципе не против, пока оно все работает.

Насчет CLK - так как оно стояло в модуле от производителя, я его просто закомментарю там, так как я хочу сохранить исходный модуль от производителя с минимумом изменений, даже если он неоптимален, пока не появится серьезной причины его переписать.

@yuri-panchul yuri-panchul merged commit 023a0e8 into yuri-panchul:main Nov 11, 2024
2 checks passed
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

Successfully merging this pull request may close these issues.

3 participants