Skip to content

Instantly share code, notes, and snippets.

View Yatekii's full-sized avatar

Noah Hüsser Yatekii

View GitHub Profile

Abstract

Ever wanted to know how the magic spell you always used to program that mystery ELF file onto your embedded target works? I did so in February 2019. This is the story of probe-rs, your magic spellbook to talk to embedded targets.

Close to a decade now, I have been working with embedded systems. While complaining about subpar tooling was always an option, stepping up and make better tooling somehow seemed impossible. One year ago, having no prior knowledge of this matter, I started to look into how debug probes work, how the debug interface of ARM cores works and how prior tooling, such as OpenOCD, pyOCD and Segger, approaches this.

One year later, we have a working library to interact with ARM and RISC-V targets, as well as a cargo plugin to program the target of your choice. Of course we are not done yet. There is a plethora of embedded targets, bugs arise everyday and there is way more awesome functionality and tooling, such as ITM, ETM and custom target hooks (e.g. chip unlock), w

For Rev

version: '3'
networks:
deploy_review-master-8dyme2-net:
external: true
services:
reverse-proxy:
# The official v2 Traefik docker image
image: traefik:v2.2
# Enables the web UI and tells Traefik to listen to docker
command: --api.insecure=true --providers.docker
version: '3'
# networks:
# $CI_ENVIRONMENT_SLUG-net:
volumes:
cache:
services:
static:
image: "$CI_REGISTRY_IMAGE/static:$CI_COMMIT_BRANCH"
container_name: "$CI_ENVIRONMENT_SLUG-static"
# networks:
reverse-proxy_1 | time="2020-05-24T13:31:35Z" level=debug msg="vulcand/oxy/roundrobin/rr: Forwarding this request to URL" Request="{\"Method\":\"GET\",\"URL\":{\"Scheme\":\"\",\"Opaque\":\"\",\"User\":null,\"Host\":\"\",\"Path\":\"/favicon.ico\",\"RawPath\":\"\",\"ForceQuery\":false,\"RawQuery\":\"\",\"Fragment\":\"\"},\"Proto\":\"HTTP/1.1\",\"ProtoMajor\":1,\"ProtoMinor\":1,\"Header\":{\"Accept\":[\"image/webp,*/*\"],\"Accept-Encoding\":[\"gzip, deflate\"],\"Accept-Language\":[\"en-US,en;q=0.5\"],\"Cache-Control\":[\"no-cache\"],\"Connection\":[\"keep-alive\"],\"Cookie\":[\"_pk_id.1.f628=55a88e7af6d1eec6.1590237704.4.1590323215.1590323215.\"],\"Pragma\":[\"no-cache\"],\"User-Agent\":[\"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:76.0) Gecko/20100101 Firefox/76.0\"],\"X-Forwarded-Host\":[\"review-master-8dyme2.technokrat.ch:8012\"],\"X-Forwarded-Port\":[\"8012\"],\"X-Forwarded-Proto\":[\"http\"],\"X-Forwarded-Server\":[\"b05c3d158dcd\"],\"X-Real-Ip\":[\"217.22.129.225\"]},\"ContentLength\":0,\"TransferEncodin
version: '3'
networks:
$CI_ENVIRONMENT_SLUG-net:
volumes:
cache:
services:
static:
image: "$CI_REGISTRY_IMAGE/static:$CI_COMMIT_BRANCH"
container_name: "$CI_ENVIRONMENT_SLUG-static"
networks:
version: '3'
networks:
$CI_ENVIRONMENT_SLUG-net:
services:
static:
image: "$CI_REGISTRY_IMAGE/static:$CI_COMMIT_BRANCH"
container_name: "$CI_ENVIRONMENT_SLUG-static"
networks:
- $CI_ENVIRONMENT_SLUG-net
ports:
yatekii@arcturo:~/repos/xyz/website$ docker login registry.xyz.ch
Username: kek
Password:
WARNING! Your password will be stored unencrypted in /home/yatekii/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store
Login Succeeded
yatekii@arcturo:~/repos/xyz/website$ docker tag alpine:latest registry.xyz.ch/alpine
yatekii@arcturo:~/repos/xyz/website$ docker push registry.xyz.ch/alpine
000000b4 <EraseSector>:
b4: b5b0 push {r4, r5, r7, lr}
b6: 4604 mov r4, r0
b8: f240 0504 movw r5, #4
bc: f2c0 0500 movt r5, #0
c0: 2002 movs r0, #2
c2: f849 0005 str.w r0, [r9, r5]
c6: eb09 0005 add.w r0, r9, r5
ca: 2100 movs r1, #0
cc: e9c0 1101 strd r1, r1, [r0, #4]
ATTRIBUTE X_INTERFACE_INFO : STRING;
ATTRIBUTE X_INTERFACE_PARAMETER : STRING;
ATTRIBUTE X_INTERFACE_PARAMETER of AxiAClkxCI: SIGNAL is "XIL_INTERFACENAME CLOCK, ASSOCIATED_BUSIF S0, ASSOCIATED_RESET ARESETN, FREQ_HZ 100000000, PHASE 0.000, INSERT_VIP 0";
ATTRIBUTE X_INTERFACE_INFO of AxiAClkxCI: SIGNAL is "xilinx.com:signal:clock:1.0 CLOCK CLK";
ATTRIBUTE X_INTERFACE_PARAMETER of AxiAResetxRBI: SIGNAL is "XIL_INTERFACENAME RESET, POLARITY ACTIVE_LOW, INSERT_VIP 0, TYPE INTERCONNECT";
ATTRIBUTE X_INTERFACE_INFO of AxiAResetxRBI: SIGNAL is "xilinx.com:signal:reset:1.0 RESET RST";
ATTRIBUTE X_INTERFACE_INFO of AxiAWAddrxDI: SIGNAL is "xilinx.com:interface:aximm:1.0 S0 AWADDR";
ATTRIBUTE X_INTERFACE_INFO of AxiAWProtxDI: SIGNAL is "xilinx.com:interface:aximm:1.0 S0 AWPROT";
--------------------------------------------------------------------------------------------------------------
--
-- Generic AXI 4 Light Slave Interface
--
-- (c) 2014
-- A. Traber
-- L. Schrittwieser
--
--------------------------------------------------------------------------------------------------------------
--