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

RFC: applet.program.ecp5_flash #192

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

gregdavill
Copy link
Contributor

This is my initial work at using the spi_background_programming mode of the Lattice ECP5 FPGA to perform operations on the configuration memory via JTAG, instead of requiring a separate SPI connection.

This code builds on the work of #191

This applet is essentially a wrapper for memory.25x which overrides _command() with one that sends commands over JTAG instead of SPI.

I've been successful with getting this to work on some ECP5 boards here, but still has a few features that I'd like to add.

greg@xps:~/projects/Glasgow/software$ glasgow run program-ecp5-flash --pin-tck 3 --pin-tms 2 --pin-tdi 0 --pin-tdo 1 --freq 6000 --voltage 3.3 identify
I: g.device.hardware: device already has bitstream ID e7f22a6221689b598c39f770500c31ca
I: g.cli: running handler for applet 'program-ecp5-flash'
I: g.applet.program.ecp5_flash: port(s) A, B voltage set to 3.3 V
I: g.applet.program.ecp5_flash: manufacturer=0x021 (Lattice Semi.) part=0x1112 version=0x4
I: g.applet.program.ecp5_flash: Found Device: ECP5Device(name='LFE5U-45', idcode=1091641411)
I: g.applet.memory.25x: JEDEC manufacturer 0x01 (AMD) device 0x17 (8-bit ID)
I: g.applet.memory.25x: JEDEC manufacturer 0x01 (AMD) device 0x2018 (16-bit ID)
I: g.applet.memory.25x: device has valid SFDP 1.6 (JESD216B) descriptor
I: g.applet.memory.25x:   SFDP table #0: JEDEC, Flash Parameter Table 1.0 (JESD216)
I: g.applet.memory.25x:     density (Mbits)        : 128
...

Base automatically changed from master to main February 27, 2021 09:59
@whitequark
Copy link
Member

This applet is a bit hard to review--I think I'll be able to give it a full review after #191. That said, it needs to be updated to track latest changes in Glasgow too.

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