160
index.html
160
index.html
@ -9,10 +9,10 @@
|
||||
|
||||
<link rel="stylesheet" href="dist/reset.css">
|
||||
<link rel="stylesheet" href="dist/reveal.css">
|
||||
<link rel="stylesheet" href="dist/theme/night.css">
|
||||
<link rel="stylesheet" href="dist/theme/fossasia2022.css">
|
||||
|
||||
<!-- Theme used for syntax highlighted code -->
|
||||
<link rel="stylesheet" href="plugin/highlight/monokai.css">
|
||||
<link rel="stylesheet" href="plugin/highlight/zenburn.css">
|
||||
</head>
|
||||
|
||||
<!--
|
||||
@ -80,17 +80,32 @@
|
||||
|
||||
<body>
|
||||
<div class="reveal">
|
||||
<div class="footer">
|
||||
<a class="url" href="https://p.xobs.io/fa22/">p.xobs.io/fa22</a>
|
||||
</div>
|
||||
<div class="slides">
|
||||
<section>
|
||||
<section>
|
||||
<h2>Renode: Easy CI for your Weird Hardware</h2>
|
||||
<h3>Sean Cross</h3>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Renode</h2>
|
||||
<p>I find it a useful tool. Maybe you will, too!
|
||||
</section>
|
||||
<section>
|
||||
<h2>What is "Weird Hardware"?</h2>
|
||||
<ul>
|
||||
<li>Hardware that there is only one of (because you just made it)</li>
|
||||
<li>Hardware that you're trying to understand</li>
|
||||
<li>Hardware that uses ARM, i386, PowerPC, Risc-V, Sparc, or Xtensa</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
<h2>About Me: I Do Weird Hardware</h2>
|
||||
<ul>
|
||||
<li>Simmel: Contact Tracing with Audio</li>
|
||||
<li>Chibitronics: Programming Stickers with Audio</li>
|
||||
<li>Betrusted/Precursor: FPGA Secure Communications</li>
|
||||
<li>Fomu: World's Smallest FPGA Dev Board</li>
|
||||
<li>Novena: Open Source Laptop</li>
|
||||
<li>Senoko: Open Source Power Board for Novena</li>
|
||||
</ul>
|
||||
@ -113,20 +128,20 @@
|
||||
<li>MIT Licensed</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
<!-- <section>
|
||||
<h2>About This Talk</h2>
|
||||
<ul>
|
||||
<li>Overview of Emulators</li>
|
||||
<li>Oevrview of Weird Hardware</li>
|
||||
<li>Cool things you can do</li>
|
||||
</ul>
|
||||
</section>
|
||||
</section> -->
|
||||
<section>
|
||||
<h2>Who will find this interesting?</h2>
|
||||
<h2>Who Might Find This Talk Interesting?</h2>
|
||||
<ul>
|
||||
<li>Creators: Those making new boards or hardware</li>
|
||||
<li>Integrators: Running CI on firmware files</li>
|
||||
<li>Reverse Engineers: Understanding new hardware and firmware</li>
|
||||
<li>Creators</li>
|
||||
<li>Integrators</li>
|
||||
<li>Reverse Engineers</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
@ -134,7 +149,8 @@
|
||||
<ul>
|
||||
<li>Reusing an existing platform</li>
|
||||
<li>Reusing an existing microcontroller</li>
|
||||
<li>New microcontroller fron existing family</li>
|
||||
<li>New microcontroller from existing family</li>
|
||||
<li>New microcontroller with a common CPU</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
@ -146,7 +162,6 @@
|
||||
</ul>
|
||||
<li>Hardware crunch makes it difficult to get hardware</li>
|
||||
<li>Downloading software is much cheaper than shipping</li>
|
||||
<li>Can run tests on every code push</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
@ -154,22 +169,13 @@
|
||||
<ul>
|
||||
<li>Staring at code flow is enlightening, but time-consuming</li>
|
||||
<li>What is it doing and how does it get there?</li>
|
||||
<li>How can we make it do $x?</li>
|
||||
</ul>
|
||||
<img src="media/bluenrg-ghidra-trace.png" class="fragment">
|
||||
</section>
|
||||
</section>
|
||||
<section>
|
||||
<section data-transition="fade-out">
|
||||
<h2>What is an Emulator?</h2>
|
||||
<img class="fragment" src="media/bbs-example.png">
|
||||
</section>
|
||||
<section data-transition="fade">
|
||||
<h2>What is an Emulator?</h2>
|
||||
<img src="media/DEC_VT100_terminal_cropped.jpg">
|
||||
</section>
|
||||
<section data-transition="fade-in slide-out">
|
||||
<h2>What is an Emulator?</h2>
|
||||
<img src="media/bbs-example.png">
|
||||
<section>
|
||||
<h2>What Is an Emulator?</h2>
|
||||
</section>
|
||||
<section data-transition="slide-in fade-out">
|
||||
<h2>Whole-System Emulator</h2>
|
||||
@ -201,14 +207,29 @@
|
||||
<li>Rosetta on Mac</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section data-transition="slide-in fade-out">
|
||||
<h2>What is an Emulator?</h2>
|
||||
<img class="fragment" src="media/bbs-example.png">
|
||||
</section>
|
||||
<section data-transition="fade">
|
||||
<h2>What is an Emulator?</h2>
|
||||
<img src="media/DEC_VT100_terminal_cropped.jpg">
|
||||
</section>
|
||||
<section data-transition="fade-in slide-out">
|
||||
<h2>What is an Emulator?</h2>
|
||||
<img src="media/bbs-example.png">
|
||||
</section>
|
||||
<section>
|
||||
<h2>Emulation Depends on your Goals!</h2>
|
||||
</section>
|
||||
<!-- <section>
|
||||
<h2>Renode Is Many of These</h2>
|
||||
<ul>
|
||||
<li>Console: Able to present an interactive environment</li>
|
||||
<li>Transparent: Can run in CI via Robot commands</li>
|
||||
<li>Debugger: Has a GDB server built in</li>
|
||||
</ul>
|
||||
</section>
|
||||
</section> -->
|
||||
</section>
|
||||
|
||||
<section>
|
||||
@ -246,10 +267,10 @@
|
||||
<h2>What is a Computer?</h2>
|
||||
<img src="media/bluenrg-block-diagram-peripherals.png">
|
||||
</section>
|
||||
<section>
|
||||
<!-- <section>
|
||||
<h2>What is a Computer?</h2>
|
||||
<img src="media/bluenrg-peripherals.png">
|
||||
</section>
|
||||
</section> -->
|
||||
<section>
|
||||
<h2>What is a Computer?</h2>
|
||||
<img src="media/bluenrg-memory-map.png">
|
||||
@ -260,7 +281,7 @@
|
||||
</section>
|
||||
<section>
|
||||
<h2>Defining a Computer in Renode</h2>
|
||||
<pre><code data-trim>
|
||||
<pre><code data-trim data-line-numbers="|1-5|7-8|10-13">
|
||||
flash: Memory.MappedMemory @ sysbus 0x00000000
|
||||
size: 0x00008000
|
||||
|
||||
@ -301,15 +322,16 @@
|
||||
<pre class="fragment"><code data-trim>
|
||||
sysbus LoadBinary @rom.bin 0x20000000
|
||||
</code></pre>
|
||||
<pre class="fragment"><code data-trim>
|
||||
<!-- <pre class="fragment"><code data-trim>
|
||||
sysbus LoadSymbolsFrom @rom.elf
|
||||
</code></pre>
|
||||
</code></pre> -->
|
||||
</section>
|
||||
<section>
|
||||
<h2>How does Renode Interact With $VENDOR_TOOL?</h2>
|
||||
<ul>
|
||||
<li>Hopefully your vendor tool produces ELF files</li>
|
||||
<li class="fragment">At the end of the day, it's all bytes. Just use <code>LoadBinary</code>!
|
||||
<li class="fragment">HEX? BIN? Just use <code>LoadBinary</code>!
|
||||
<li class="fragment">Custom firmware format? Need to unpack first.</li>
|
||||
</li>
|
||||
</ul>
|
||||
</section>
|
||||
@ -324,8 +346,11 @@
|
||||
<li>Jump to loaded program</li>
|
||||
</ol>
|
||||
<pre class="fragment"><code data-trim>
|
||||
sysbus LoadBinary @rom.bin 0x20000000
|
||||
sysbus.cpu VectorTableOffset 0x20000000
|
||||
sysbus.cpu PC 0x20000c00
|
||||
sysbus.cpu SP `sysbus ReadDoubleWord 0x20000000`
|
||||
sysbus.cpu PC `sysbus ReadDoubleWord 0x20000004`
|
||||
start
|
||||
</code></pre>
|
||||
</section>
|
||||
</section>
|
||||
@ -341,7 +366,19 @@
|
||||
<li>They are easy to script</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section data-transition="fade-out">
|
||||
<section>
|
||||
<h2>What is a Computer?</h2>
|
||||
<img src="media/bluenrg-memory-map.png">
|
||||
</section>
|
||||
<section data-transition="slide-in fade-out">
|
||||
<h2>What is a Register?</h2>
|
||||
<img src="media/pl011-bluenrg.png">
|
||||
</section>
|
||||
<section data-transition="fade">
|
||||
<h2>What is a Register?</h2>
|
||||
<img src="media/pl011-bluenrg-field.png">
|
||||
</section>
|
||||
<section data-transition="fade">
|
||||
<h2>What is a Register?</h2>
|
||||
<img src="media/pl011-bluenrg.png">
|
||||
<img class="fragment" src="media/pl011-cc2538-cropped.png">
|
||||
@ -376,6 +413,17 @@
|
||||
PerformanceInMips: 24
|
||||
</code></pre>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Setting up Renode</h2>
|
||||
<pre data-id="code-animation"><code data-trim>
|
||||
machine LoadPlatformDescription @bluenrg-1.repl
|
||||
sysbus LoadBinary @BLE_Chat_Server.bin 0x10040000
|
||||
cpu VectorTableOffset 0x10040000
|
||||
cpu SP `sysbus ReadDoubleWord 0x10040000`
|
||||
cpu PC `sysbus ReadDoubleWord 0x10040004`
|
||||
start
|
||||
</code></pre>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Output Success!</h2>
|
||||
<img src="media/bluenrg-renode-uart.png">
|
||||
@ -413,7 +461,10 @@
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Example Serial Port</h2>
|
||||
<h2>Modify an Existing Block</h2>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Example Serial Port: LiteX UART</h2>
|
||||
<pre class="code-animation"><code class="cs" data-trim data-line-numbers="|132-140|118-126|125|20-33">
|
||||
//
|
||||
// Copyright (c) 2010-2018 Antmicro
|
||||
@ -575,6 +626,14 @@
|
||||
<li class="fragment">Most writes can be ignored</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Peripheral Rapid Development</h2>
|
||||
<img src="media/hardware-20191117-cropped.jpg">
|
||||
</section>
|
||||
<section>
|
||||
<h2>Peripheral Rapid Development</h2>
|
||||
<video class="r-stretch" data-autoplay src="media/Renode-20191117-trimmed.m4v"></video>
|
||||
</section>
|
||||
<section data-transition="fade-out">
|
||||
<h2>Advantages of Emulation</h2>
|
||||
<img src="media/betrusted-soc-uart-mux.png">
|
||||
@ -583,6 +642,14 @@
|
||||
<h2>Advantages of Emulation</h2>
|
||||
<img src="media/renode-xous-double-uart-tiled.png">
|
||||
</section>
|
||||
<section>
|
||||
<h2>Getting Hardware to Users</h2>
|
||||
<img src="media/betrusted-wycheproof-patch.png">
|
||||
</section>
|
||||
<section>
|
||||
<h2>Getting Hardware to Users</h2>
|
||||
<img src="media/betrusted-wycheproof-patch-fix.png">
|
||||
</section>
|
||||
</section>
|
||||
<!--
|
||||
<section>
|
||||
@ -798,7 +865,7 @@
|
||||
</section>
|
||||
<section>
|
||||
<h2>SVD: Using with Renode</h2>
|
||||
<pre class="code-animation"><code data-trim data-line-numbers="|1-6|8-18|20-26|28-40">
|
||||
<pre class="code-animation"><code data-trim>
|
||||
sysbus ApplySVD @BlueNRG2.svd
|
||||
</code></pre>
|
||||
<img class="fragment" src="media/bluenrg-renode-svd.png">
|
||||
@ -817,16 +884,23 @@
|
||||
<img src="media/ghidra-decompile.png">
|
||||
</section>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Multi-System Emulation</h2>
|
||||
<img src="media/renode-multi-system.png">
|
||||
</section>
|
||||
<section>
|
||||
<h2>Multi-System Emulation</h2>
|
||||
<img src="media/betrusted-ec-com-1.png">
|
||||
</section>
|
||||
<section>
|
||||
|
||||
<section>
|
||||
<h2>Multi-System Emulation</h2>
|
||||
<img src="media/betrusted-ec-com-1.png">
|
||||
</section>
|
||||
<section>
|
||||
<h2>Multi-System Emulation</h2>
|
||||
<img src="media/renode-multi-system.png">
|
||||
</section>
|
||||
</section>
|
||||
<section>
|
||||
<h2>Renode is Free Software</h2>
|
||||
Give it a try!
|
||||
</section>
|
||||
<section>
|
||||
<h2>Thank you for your time</h2>
|
||||
</section>
|
||||
</div>
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user