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

GOWIN algorithms re-write #371

Closed
wants to merge 8 commits into from
Closed

Conversation

aystarik
Copy link
Contributor

Checked working program SRAM, internal FLASH on Tang Nano1k and Tang Nano 9k with three JTAG cables: original FT232, on-board BL702 emulating FT2232 and CH347 (optimized in this PR).

@aystarik aystarik force-pushed the master branch 3 times, most recently from 55c08a8 to 45e8fb7 Compare September 1, 2023 17:24
Comment on lines -748 to -751
#define spi_gowin_write(_wr, _rd, _len) do { \
_jtag->shiftDR(_wr, _rd, _len); \
_jtag->toggleClk(6); } while (0)

Copy link
Owner

Choose a reason for hiding this comment

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

To avoid code duplication (for ease of maintenance/improvement) I prefer keeping this macro. After preprocessor pass code will look similar to your.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's better to make it a function then, "inline" was invented for this same purpose... Would you like what I update the patch?

@aystarik aystarik force-pushed the master branch 4 times, most recently from 469bfad to 34aca16 Compare September 6, 2023 11:53
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.

2 participants