Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #42 from shenki/mimasv2-fixes
Mimasv2 fixes
- Loading branch information
Showing
2 changed files
with
14 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
#!/bin/bash | ||
|
||
#!/usr/bin/env python3 | ||
|
||
import argparse | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,26 @@ | ||
# mimasv2 loading | ||
|
||
TARGET ?= base | ||
# FIXME(mithro): Detect the real serial port/add see udev rules to HDMI2USB-mode-switch... | ||
PORT ?= /dev/ttyACM0 | ||
BAUD ?= 19200 | ||
|
||
gateware-load-mimasv2: | ||
python3 $$(which MimasV2Config.py) /dev/ttyACM0 $(TARGET_BUILD_DIR)/gateware/top.bin | ||
@echo "MimasV2 doesn't support loading, use the flash target instead." | ||
@echo "make gateware-flash-mimasv2" | ||
@false | ||
|
||
image-load-mimasv2: | ||
gateware-flash-mimasv2: | ||
python3 $$(which MimasV2Config.py) $(PORT) $(TARGET_BUILD_DIR)/gateware/top.bin | ||
|
||
image-flash-mimasv2: | ||
python mkimage.py | ||
python3 $$(which MimasV2Config.py) /dev/ttyACM0 $(TARGET_BUILD_DIR)/flash.bin | ||
python3 $$(which MimasV2Config.py) $(PORT) $(TARGET_BUILD_DIR)/flash.bin | ||
|
||
firmware-load-mimasv2: | ||
flterm --port=/dev/ttyACM0 --kernel=$(TARGET_BUILD_DIR)/software/firmware/firmware.bin --speed=19200 | ||
flterm --port=$(PORT) --kernel=$(TARGET_BUILD_DIR)/software/firmware/firmware.bin --speed=$(BAUD) | ||
|
||
firmware-connect-mimasv2: | ||
flterm --port=/dev/ttyACM0 --speed=19200 | ||
flterm --port=$(PORT) --speed=$(BAUD) | ||
|
||
.PHONY: gateware-load-mimasv2 firmware-load-mimasv2 |