Skip to content

Disable the lm32 firmware from SPI flash for now #275

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

Merged
merged 2 commits into from
Aug 6, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,11 @@ load: load-gateware $(addprefix load-,$(TARGETS))
# Flash
flash-gateware: gateware-submodules
$(MAKEPY_CMD) flash-bitstream
@echo ""
@echo ""
@echo "Gateware has been flashed."

flash: flash-gateware $(addprefix flash-,$(TARGETS))
flash: flash-gateware $(addprefix flash-,$(TARGETS))
@echo ""
@echo ""
@echo "Power cycle your board to boot newly flashed stuff."
Expand Down
15 changes: 13 additions & 2 deletions Makefile.lm32
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,20 @@ image-lm32: firmware-lm32
$(MAKEIMAGE_CMD) --fbi --output $(HDMI2USBDIR)/firmware/lm32/firmware.fbi $(HDMI2USBDIR)/firmware/lm32/firmware.bin

flash-lm32: image-lm32
@echo
@echo "Skipping writing lm32 firmware to flash."
@echo "(Loading lm32 firmware from flash is current disabled --"
@echo " see https://github.com/timvideos/HDMI2USB-misoc-firmware/issues/274)"
@echo "Booting will use lm32 firmware embedded in the gateware."
@echo
# export FIRMWARE_ADDRESS=$$($(PYTHON) -c "import platforms.$(BOARD) as b; print(b.Platform.gateware_size)"); \
# echo "Flashing to $$($(PYTHON) -c "print(hex($$FIRMWARE_ADDRESS))") ($$FIRMWARE_ADDRESS)"; \
# $(FLASHEXTRA_CMD) $(HDMI2USBDIR)/firmware/lm32/firmware.fbi $$FIRMWARE_ADDRESS

clear-flash-lm32:
export FIRMWARE_ADDRESS=$$($(PYTHON) -c "import platforms.$(BOARD) as b; print(b.Platform.gateware_size)"); \
echo "Flashing to $$($(PYTHON) -c "print(hex($$FIRMWARE_ADDRESS))") ($$FIRMWARE_ADDRESS)"; \
$(FLASHEXTRA_CMD) $(HDMI2USBDIR)/firmware/lm32/firmware.fbi $$FIRMWARE_ADDRESS
echo "Zeroing $$($(PYTHON) -c "print(hex($$FIRMWARE_ADDRESS))") ($$FIRMWARE_ADDRESS)"; \
$(FLASHEXTRA_CMD) $(HDMI2USBDIR)/firmware/zero.bin $$FIRMWARE_ADDRESS

clean-lm32:
if [ -f $(MSCDIR)/software/include/generated/cpu.mak ]; then \
Expand Down
Binary file added firmware/zero.bin
Binary file not shown.