Compare commits

..

No commits in common. "47c7e55cba43673ea72070670a2b205841392316" and "2991dcef68494d2f83c6b4e5591c753ccd9fbc1a" have entirely different histories.

4 changed files with 46 additions and 84 deletions

View File

@ -51,10 +51,10 @@ FROM base as toolsbuilder
RUN git clone https://github.com/YosysHQ/icestorm /src
WORKDIR /src
RUN git checkout d20a5e9001f46262bf0cef220f1a6943946e421d \
RUN git checkout 45f5e5f3889afb07907bab439cf071478ee5a2a5 \
&& make -j$(nproc --ignore=2) \
&& make install
RUN git >/usr/local/repo-commit-icestorm describe --all --always --long --dirty
RUN git >/usr/local/repo-commit-icestorm describe --tags --always --dirty
WORKDIR /
RUN rm -rf /src
@ -63,34 +63,39 @@ RUN git clone -b interfaces --depth=1 https://github.com/tillitis/icestorm /src
WORKDIR /src/iceprog
RUN make -j$(nproc --ignore=2) \
&& make PROGRAM_PREFIX=tillitis- install
RUN git >/usr/local/repo-commit-tillitis--icestorm describe --all --always --long --dirty
RUN git >/usr/local/repo-commit-tillitis--icestorm describe --tags --always --dirty
WORKDIR /
RUN rm -rf /src
RUN git clone -b yosys-0.26 --depth=1 https://github.com/YosysHQ/yosys /src
RUN git clone https://github.com/YosysHQ/yosys /src
WORKDIR /src
RUN make -j$(nproc --ignore=2) \
&& make install
RUN git >/usr/local/repo-commit-yosys describe --all --always --long --dirty
WORKDIR /
RUN rm -rf /src
RUN git clone -b nextpnr-0.5 --depth=1 https://github.com/YosysHQ/nextpnr /src
WORKDIR /src
RUN cmake -DARCH=ice40 -DCMAKE_INSTALL_PREFIX=/usr/local . \
# Avoiding current issue with yosys & icebram, filed in:
# https://github.com/YosysHQ/yosys/issues/3478
RUN git checkout 06ef3f264afaa3eaeab45cc0404d8006c15f02b1 \
&& make -j$(nproc --ignore=2) \
&& make install
RUN git >/usr/local/repo-commit-nextpnr describe --all --always --long --dirty
RUN git >/usr/local/repo-commit-yosys describe --tags --always --dirty
WORKDIR /
RUN rm -rf /src
RUN git clone https://github.com/YosysHQ/nextpnr /src
WORKDIR /src
# Use nextpnr-0.4. Aa few commits later we got issues, like on f4e6bbd383f6c43.
RUN git checkout nextpnr-0.4 \
&& cmake -DARCH=ice40 -DCMAKE_INSTALL_PREFIX=/usr/local . \
&& make -j$(nproc --ignore=2) \
&& make install
RUN git >/usr/local/repo-commit-nextpnr describe --tags --always --dirty
WORKDIR /
RUN rm -rf /src
RUN git clone --branch 1.5.0 --depth 1 https://github.com/raspberrypi/pico-sdk.git /usr/local/pico-sdk
WORKDIR /usr/local/pico-sdk
RUN git submodule update --init
RUN git >/usr/local/repo-commit-picosdk describe --all --always --long --dirty
RUN git >/usr/local/repo-commit-picosdk describe --tags --always --dirty
WORKDIR /
FROM base
LABEL org.opencontainers.image.description="Toolchain for building TKey FPGA bitstream, firmware, apps, programmer firmware"
LABEL org.opencontainers.image.description="Toolchain for building TKey FPGA bitstream, firmware, apps"
COPY --from=toolsbuilder /usr/local/ /usr/local

View File

@ -1,51 +1,26 @@
# image produced by build-image targets
BUILDIMAGE=tkey-builder-local
# default image used when running a container
IMAGE=ghcr.io/tillitis/tkey-builder:2
all:
@echo "Targets:"
@echo "run Run a shell using image '$(IMAGE)' (Podman)"
@echo "run-make Build the FPGA bitstream using image '$(IMAGE)' (Podman)"
@echo "run-make-no-clean Like run-make but without cleaning first, useful for iterative firmware dev"
@echo "run-make-clean_fw Like run-make but cleans only firmware"
@echo "pull Pull down the image '$(IMAGE)' (Podman)"
@echo "build-image Build a toolchain image named '$(BUILDIMAGE)' (Podman)"
@echo " A newly built image can be used like: make IMAGE=$(BUILDIMAGE) run"
@echo "docker-run Run a shell using image '$(IMAGE)' (Docker)"
@echo "docker-build-image Build a toolchain image named '$(BUILDIMAGE)' (Docker)"
@echo "Build targets: "
@echo "build Build an image for building tools with Docker"
@echo "run Run a shell using the above image with Docker"
@echo "podman-pull Pull in the podman tkey builder"
@echo "podman-build Build an image with podman"
@echo "podman-run Run a shell using above image with podman"
@echo "podman-run-make Run the above image with podman and build the FPGA bitstream"
build:
docker build -t tkey-builder .
run:
podman run --rm --mount type=bind,source="`pwd`/../",target=/build -w /build -it \
$(IMAGE) /usr/bin/bash
docker run --rm --mount type=bind,source="`pwd`/../",target=/build -w /build -it tkey-builder /usr/bin/bash
docker-run:
docker run --rm --mount type=bind,source="`pwd`/../",target=/build -w /build -it \
$(IMAGE) /usr/bin/bash
podman-pull:
podman pull ghcr.io/tillitis/tkey-builder:1
run-make:
podman run --rm --mount type=bind,source="`pwd`/../hw/application_fpga",target=/build -w /build -it \
$(IMAGE) make clean application_fpga.bin
podman-build:
podman build -t tkey-builder .
run-make-testfw:
podman run --rm --mount type=bind,source="`pwd`/../hw/application_fpga",target=/build -w /build -it \
$(IMAGE) make clean application_fpga_testfw.bin
podman-run:
podman run --rm --mount type=bind,source="`pwd`/../",target=/build -w /build -it tkey-builder /usr/bin/bash
run-make-no-clean:
podman run --rm --mount type=bind,source="`pwd`/../hw/application_fpga",target=/build -w /build -it \
$(IMAGE) make application_fpga.bin
run-make-clean_fw:
podman run --rm --mount type=bind,source="`pwd`/../hw/application_fpga",target=/build -w /build -it \
$(IMAGE) make clean_fw application_fpga.bin
pull:
podman pull $(IMAGE)
build-image:
podman build -t $(BUILDIMAGE) .
docker-build-image:
docker build -t $(BUILDIMAGE) .
podman-run-make:
podman run --rm --mount type=bind,source="`pwd`/../hw/application_fpga",target=/build -w /build -it tkey-builder make

View File

@ -3,27 +3,6 @@
Descriptions of the tagged TKey releases.
## TK1-23.03.1
This is the official release of the "Bellatrix" version of
the Tillitis TKey device. This version is ready for general
use.
Given the OCI image `ghcr.io/tillitis/tkey-builder:2` built from
`../contrib/Dockerfile` and the generic UDS.hex and UDI.hex, a clean
build should generate the following digest:
```
sha256sum application_fpga.bin
d2970828269b3ba7f09fb73b8592b08814dfe8c8087b00b0659feb516bb00f33 application_fpga.bin
```
This bug fix release contains the following changes:
- Change the firmware protocol max frame size back to 128 bytes
- Correct a bug with the reading out of UDS
## TK1-23.03
This is the official release of the "Bellatrix" version of
the Tillitis TKey device. This version is ready for general

View File

@ -80,7 +80,7 @@ install other versions of these tools locally, they could conflict
git clone https://github.com/YosysHQ/icestorm
cd icestorm
git checkout d20a5e9001f46262bf0cef220f1a6943946e421d
git checkout 45f5e5f3889afb07907bab439cf071478ee5a2a5
make -j$(nproc)
sudo make install
cd ..
@ -96,14 +96,17 @@ install other versions of these tools locally, they could conflict
git clone https://github.com/YosysHQ/yosys
cd yosys
git checkout yosys-0.26
# Avoiding current issue with yosys & icebram, filed in:
# https://github.com/YosysHQ/yosys/issues/3478
git checkout 06ef3f264afaa3eaeab45cc0404d8006c15f02b1
make -j$(nproc)
sudo make install
cd ..
git clone https://github.com/YosysHQ/nextpnr
cd nextpnr
git checkout nextpnr-0.5
# Use nextpnr-0.4. Aa few commits later we got issues, like on f4e6bbd383f6c43.
git checkout nextpnr-0.4
cmake -DARCH=ice40 -DCMAKE_INSTALL_PREFIX=/usr/local .
make -j$(nproc)
sudo make install