<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<?xml-stylesheet href="/static/styles/feed.xsl" type="text/xsl"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
   <title>anna-docs</title>
   <link>https://anna-docs.netlify.app/</link>
   <description>Recent content on anna-docs</description>
   <language>en-IN</language>
   <webMaster>anna</webMaster>
   <copyright>This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International.</copyright>
   <lastBuildDate>Mon, 30 Mar 2026 22:58:41 +0530</lastBuildDate>
   <atom:link href="https://anna-docs.netlify.app/feed.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>When Microcontrollers Struggle with Math: Building Herald</title>
      <link>https://anna-docs.netlify.app/blogs/herald/</link>
      <pubDate>Sun, 29 Mar 2026 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/herald/</guid>
      <description>&lt;h2 id=&#34;why-i-built-herald&#34;&gt;Why I Built Herald&lt;/h2&gt;&#xA;&lt;p&gt;Microcontrollers are great, until you ask them to do math.&lt;/p&gt;&#xA;&lt;p&gt;Try throwing trigonometry or signal processing at a small MCU and things slow down very quickly. This is especially true for cheaper or simpler chips that either do not have a floating point unit or rely on relatively expensive hardware support. Even when FPUs are available, they are not always the best choice for power or area constrained systems.&lt;/p&gt;&#xA;&lt;p&gt;I wanted something simpler. Maybe a small hardware block that could handle these operations efficiently without dragging in all the overhead of floating point. And that idea eventually became &lt;a href=&#34;https://github.com/pranav0x0112/Herald&#34;&gt;Herald&lt;/a&gt;, a fixed-point DSP coprocessor designed for &lt;a href=&#34;https://tinytapeout.com/&#34;&gt;Tiny Tapeout&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;The design itself was written in &lt;a href=&#34;https://github.com/rsnikhil/Bluespec_BSV_Tutorial&#34;&gt;Bluespec SystemVerilog&lt;/a&gt; for rapid prototyping, and then compiled down to Verilog to fit into the Tiny Tapeout flow.&lt;/p&gt;&#xA;&lt;p&gt;At first, this was just an experiment to see if something like this could even fit within Tiny Tapeout&#39;s constraints. It turned out to be a lot more involved than expected.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;what-herald-does&#34;&gt;What Herald does&lt;/h2&gt;&#xA;&lt;p&gt;At a high level, Herald is a small hardware accelerator for math operations that tend to be slow on Microcontrollers.&lt;/p&gt;&#xA;&lt;p&gt;It focuses on two main categories:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Trigonometric and vector operations&lt;/li&gt;&#xA;&lt;li&gt;Multiply-accumulate (MAC) operations&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;That already covers a lot of real-world use cases like filtering, sensor fusion, and basic control systems. Instead of doing all this in software, the idea is simple. You send inputs to Herald, let it compute in hardware and the result is read back once its ready.&lt;/p&gt;&#xA;&lt;p&gt;Internally, this is handled by two main blocks:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;A &lt;a href=&#34;https://www.allaboutcircuits.com/technical-articles/an-introduction-to-the-cordic-algorithm/&#34;&gt;CORDIC&lt;/a&gt; engine for trigonometry and vector math&lt;/li&gt;&#xA;&lt;li&gt;A &lt;a href=&#34;https://en.wikipedia.org/wiki/Multiply%E2%80%93accumulate_operation&#34;&gt;MAC&lt;/a&gt; unit for fast arithmetic accumulation&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;A small control interface ties everything together and keeps the interaction simple.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;architecture-overview&#34;&gt;Architecture Overview&lt;/h2&gt;&#xA;&lt;p&gt;At a high level, Herald can be split into two parts: a control path and a data path.&lt;/p&gt;&#xA;&lt;p&gt;The control path is driven by a small FSM. It handles commands, collects input data, and decides when to start computation and when results are ready.&lt;/p&gt;&#xA;&lt;p&gt;The datapath is where the actual work happens. Inputs are routed to the appropriate compute block, and the result is selected and sent back through the interface.&lt;/p&gt;&#xA;&lt;p&gt;Keeping these two blocks seperate made the design easier to reason about, especially during debugging!&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;/assets/images/herald_block_diagram.png&#34; alt=&#34;Block_Diagram&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;High-level architecture of Herald showing the control FSM, compute engines, and result path.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;how-herald-really-works&#34;&gt;How Herald really works&lt;/h2&gt;&#xA;&lt;p&gt;For the low level nerds, this is where things get a bit more interesting.&lt;/p&gt;&#xA;&lt;p&gt;So Herald operates through a simple command driven flow controlled by a FSM. Each operation follows a fixed sequence:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;A command is written to select the operation&lt;/li&gt;&#xA;&lt;li&gt;Input data is sent byte by byte&lt;/li&gt;&#xA;&lt;li&gt;The selected compute block is triggered&lt;/li&gt;&#xA;&lt;li&gt;The result becomes available once computation completes!&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Since each operand is 24 bits wide, data is transferred over multiple cycles using an 8-bit interface. The FSM takes care of assembling these bytes and ensuring everything is aligned before execution starts.&lt;/p&gt;&#xA;&lt;p&gt;From the outside, this just looks like a small protocol. Internally though, it keeps the design predictable and, more importantly, saved me from pulling my hair out by avoiding a bunch of timing headaches.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;/assets/images/fsm.png&#34; alt=&#34;FSM&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;FSM controlling command intake, operand loading, execution and result output.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;the-interesting-bits&#34;&gt;The Interesting Bits&lt;/h2&gt;&#xA;&lt;p&gt;A lot of the design choices in Herald come down to one idea: keep things simple, but still useful.&lt;/p&gt;&#xA;&lt;h3 id=&#34;fixed-point-arithmetic&#34;&gt;Fixed-point arithmetic&lt;/h3&gt;&#xA;&lt;p&gt;Instead of using floating point, Herald uses a fixed-point format (Q12.12). In simple terms, everything is stored as an integer with an implicit scaling factor.&lt;/p&gt;&#xA;&lt;p&gt;So instead of working with something like &lt;code&gt;3.5&lt;/code&gt;, you scale it and store it as an integer. All computations then stay in integer form. This avoids the need for FPU entirely, which saves both area and complexity, while still giving enough precision for most embedded use cases.&lt;/p&gt;&#xA;&lt;h3 id=&#34;cordic-doing-trig-without-real-math&#34;&gt;CORDIC: doing trig without &amp;quot;real&amp;quot; math&lt;/h3&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;/assets/images/cordic.gif&#34; alt=&#34;CORDIC&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;CORDIC can be visualized as rotating a vector toward a target angle. In hardware, this happens iteratively in small steps.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;The CORDIC engine is probably the most interesting part of the design.&lt;/p&gt;&#xA;&lt;p&gt;Instead of directly computing things like &lt;code&gt;sin&lt;/code&gt; or &lt;code&gt;cos&lt;/code&gt;, it works by rotating a vector in small steps until it reaches the desire angle. Each step only uses shifts and additions, which makes it very hardware friendly.&lt;/p&gt;&#xA;&lt;p&gt;After enough iterations, you end up with a very close approximation of the result without ever using multipliers or complex functions.&lt;/p&gt;&#xA;&lt;h3 id=&#34;mac-simple-but-useful&#34;&gt;MAC: simple, but useful&lt;/h3&gt;&#xA;&lt;p&gt;The MAC Unit is much simpler, but it ends up being just as useful.&lt;/p&gt;&#xA;&lt;p&gt;It maintains an internal accumulator and supports operations like multiply, accumulate and subtract. This makes it ideal for things like dot product or filtering, where values are combined repeatedly.&lt;/p&gt;&#xA;&lt;p&gt;It is also much faster than the CORDIC path, completing in a single cycle in this design, which makes it a nice complement to the more iterative CORDIC engine.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;from-code-to-silicon&#34;&gt;From Code to Silicon&lt;/h2&gt;&#xA;&lt;h3 id=&#34;the-big-leagues&#34;&gt;The Big Leagues&lt;/h3&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;/assets/images/full_gds.png&#34; alt=&#34;Full GDS&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Full Tiny Tapeout IHP26A shuttle layout showing multiple user designs sharing the same space!&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;One of the most satisfying parts of this project was seeing the design turn into actual layout.&lt;/p&gt;&#xA;&lt;p&gt;At the shuttle level, Herald is just one small block among many designs sharing the same space. It is easy to forget how small your design really is until you see it in that context.&lt;/p&gt;&#xA;&lt;h3 id=&#34;zooming-into-herald&#34;&gt;Zooming into Herald&lt;/h3&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;/assets/images/herald_gds.png&#34; alt=&#34;Herald_GDS&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Herald&#39;s layout showing standard cells and routing after synthesis and place-and-route.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Grabbing a magnifying glass and looking into the shuttle GDS, we can have a closer look at Herald! This is where things get more interesting.&lt;/p&gt;&#xA;&lt;p&gt;What started as HDL modules and state machines is now a dense grid of standard cells and routing. Every operation (from simple addition to a full CORDIC iteration) is physically represented here in the most fundamental electronic device: the transistor.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;what-went-wrong-and-what-i-learned&#34;&gt;What Went Wrong (And What I Learned)&lt;/h2&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;/assets/images/bugs.png&#34; alt=&#34;Bugs&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;As is always the case, no hardware project is complete without a few things going wrong, and Herald definitely had its share.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;h3 id=&#34;the-it-workswait-no-it-doesnt-bug&#34;&gt;The &amp;quot;it works...wait, no it doesn&#39;t&amp;quot; bug&lt;/h3&gt;&#xA;&lt;p&gt;At one point, the CORDIC engine was producing completely incorrect results. Everything looked fine on paper, but the outputs were clearly off.&lt;/p&gt;&#xA;&lt;p&gt;After digging into it, the issue turned out to be a subtle timing problem. The design was effectively reading results before the computation had actually progressed, so it ended up returning values from an earlier iteration.&lt;/p&gt;&#xA;&lt;p&gt;The fix itself was small, just an extra control signal to make sure the computation had actually started, but figuring it out took a lot longer than expected.&lt;/p&gt;&#xA;&lt;h3 id=&#34;when-data-is-not-what-you-think-it-is&#34;&gt;When data is not what you think it is&lt;/h3&gt;&#xA;&lt;p&gt;Another issue introduced itself while testing the wrapper interface. Values coming out the design were correct, but somehow ended up in the wrong places.&lt;/p&gt;&#xA;&lt;p&gt;This turned out to be due to how tuples are packed in Bluespec SystemVerilog. The ordering was not what I initially assumed, which meant values were being interpreted incorrectly when read out.&lt;/p&gt;&#xA;&lt;h3 id=&#34;looks-rightuntil-you-check-it&#34;&gt;Looks right...until you check it&lt;/h3&gt;&#xA;&lt;p&gt;One interesting moment was verifying the CORDIC gain factor.&lt;/p&gt;&#xA;&lt;p&gt;Instead of just trusting the theoretical value, I compared expected results with actual hardware outputs. This helped confirm that the implementation was behaving as intended, even with approximation errors from finite iterations.&lt;/p&gt;&#xA;&lt;p&gt;It is very easy to assume things are correct when they &amp;quot;look right&amp;quot;, but actually checking the numbers made a big difference!&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;wrapping-up&#34;&gt;Wrapping Up&lt;/h2&gt;&#xA;&lt;p&gt;What started as a small experiment turned into a full journey through designing, debugging and finally seeing the project make its way to actual silicon!&lt;/p&gt;&#xA;&lt;p&gt;Working within the constraints of Tiny Tapeout forced a lot of decisions, from using fixed-point arithmetic to keeping the interface simple. In the end, those constraints shaped the design just as much as the original idea.&lt;/p&gt;&#xA;&lt;p&gt;More than anything, this project is a good proof which shows that the real challenges in hardware are not always the big ideas, but even the small details. Timing and integration tend to matter far more than expected.&lt;/p&gt;&#xA;&lt;p&gt;I am truly grateful to the Tiny Tapeout community for their quick help whenever I needed it. I am very much excited to see how Herald behaves in real silicon soon :)&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>You Don&#39;t Need Expensive Tools to Play with Silicon</title>
      <link>https://anna-docs.netlify.app/blogs/riscv-toolchain/</link>
      <pubDate>Sat, 07 Feb 2026 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/riscv-toolchain/</guid>
      <description>&lt;h2 id=&#34;so-youre-sold-on-risc-v-youve-seen-the-vision-now-comes-the-question-every-beginner-asks-okay-but-how-do-i-actually-start&#34;&gt;So you&#39;re sold on RISC-V. You&#39;ve seen the vision. Now comes the question every beginner asks: &lt;em&gt;&amp;quot;Okay, but how do I actually start?&amp;quot;&lt;/em&gt;&lt;/h2&gt;&#xA;&lt;p&gt;In the &lt;a href=&#34;https://homebrew.hsp-ec.xyz/posts/risc-v:-the-linux-of-hardware/&#34;&gt;previous post&lt;/a&gt;, we explored why RISC-V is the &amp;quot;Linux of hardware&amp;quot; and how it&#39;s making processor design accessible to everyone. Now let&#39;s talk about the actual tools that let you build, simulate, and hack on real processors.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;The good news?&lt;/strong&gt; You don&#39;t need expensive licenses, proprietary toolchains, or a university lab. The hardware hacking stack is wide open and it&#39;s free.&lt;/p&gt;&#xA;&lt;h2 id=&#34;breaking-the-myth-hardware--expensive&#34;&gt;Breaking the Myth: Hardware != Expensive&lt;/h2&gt;&#xA;&lt;p&gt;When most people think &amp;quot;chip design,&amp;quot; they imagine locked-down corporate tools with five-figure licenses: &lt;a href=&#34;https://en.wikipedia.org/wiki/Cadence_Design_Systems&#34;&gt;Cadence&lt;/a&gt;, &lt;a href=&#34;https://en.wikipedia.org/wiki/Synopsys&#34;&gt;Synopsys&lt;/a&gt;, &lt;a href=&#34;https://en.wikipedia.org/wiki/Mentor_Graphics&#34;&gt;Mentor Graphics&lt;/a&gt;. And yeah, industry still uses those. But here&#39;s what&#39;s changed in the last decade:&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;The FOSS hardware ecosystem has grown up.&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;Just like Linux gave us &lt;code&gt;gcc&lt;/code&gt;, &lt;code&gt;vim&lt;/code&gt;, and &lt;code&gt;git&lt;/code&gt;, the hardware world now has &lt;a href=&#34;https://yosyshq.net/yosys/&#34;&gt;Yosys&lt;/a&gt;, &lt;a href=&#34;https://www.veripool.org/verilator/&#34;&gt;Verilator&lt;/a&gt;, and &lt;a href=&#34;https://theopenroadproject.org/&#34;&gt;OpenROAD&lt;/a&gt;. Students, hobbyists, and even startups are designing real chips with these tools: chips that actually get manufactured and work.&lt;/p&gt;&#xA;&lt;p&gt;The barrier to entry isn&#39;t money anymore. It&#39;s just knowing where to look.&lt;/p&gt;&#xA;&lt;h2 id=&#34;the-open-hardware-toolchain-your-new-best-friends&#34;&gt;The Open Hardware Toolchain: Your New Best Friends&lt;/h2&gt;&#xA;&lt;p&gt;Let&#39;s walk through the essential tools that take you from &amp;quot;I have an idea&amp;quot; to &amp;quot;I have a working processor.&amp;quot; Think of this as your hardware hacker starter pack.&lt;/p&gt;&#xA;&lt;h3 id=&#34;1-simulation-verilator--icarus-verilog&#34;&gt;&lt;strong&gt;1. Simulation: Verilator &amp;amp; Icarus Verilog&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Simulation is basically running your hardware design in software to see how it behaves, think of it like a test drive before you commit to building the real thing. Writing hardware code (Verilog/VHDL) without simulation is like coding in C without ever compiling. You need to see if your logic actually works: does your processor fetch the right instruction? Does your ALU compute correctly?&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;https://www.veripool.org/verilator/&#34;&gt;Verilator&lt;/a&gt;&lt;/strong&gt; is the Usain Bolt of the bunch. It converts your Verilog code into C++ and compiles it into a native executable, which makes it insanely fast and perfect for simulating large designs like full processors. It&#39;s cycle-accurate, meaning it simulates your design clock cycle by clock cycle, just like the real hardware would run. The trade-off? It&#39;s a bit more complex to set up, but once you get it running, you&#39;ll appreciate the speed :)&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;http://iverilog.icarus.com/&#34;&gt;Icarus Verilog&lt;/a&gt;&lt;/strong&gt; is the friendlier option for beginners. It&#39;s an event-driven simulator that&#39;s simpler to use and doesn&#39;t require you to write testbenches in C++. Just write your Verilog, compile it with the command &lt;code&gt;iverilog&lt;/code&gt;, and run it with &lt;code&gt;vvp&lt;/code&gt;. Pair it with &lt;strong&gt;&lt;a href=&#34;http://gtkwave.sourceforge.net/&#34;&gt;GTKWave&lt;/a&gt;&lt;/strong&gt; to visualize signals as waveforms, and you&#39;ve got a complete simulation workflow. It&#39;s not as fast as Verilator for huge designs, but for learning and debugging, it&#39;s perfect.&lt;/p&gt;&#xA;&lt;p&gt;Try simulating a simple counter or a full adder. Watch the waveforms change. It&#39;s oddly satisfying to see logic come alive on your screen.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i.postimg.cc/hjqnQ850/Prawns-2026-02-07-13-06-48.png&#34; alt=&#34;GTKWave&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;A GTKWave waveform illustrating the timing of control, datapath, and ALU signals in a CPU core.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;2-synthesis-yosys&#34;&gt;&lt;strong&gt;2. Synthesis: Yosys&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;This is where your abstract &amp;quot;hardware description&amp;quot; becomes real logic that could be etched onto silicon. &lt;a href=&#34;https://yosyshq.net/yosys/&#34;&gt;Yosys&lt;/a&gt; converts your high-level Verilog code into a gate-level netlist: actual logic gates like AND, OR, and flip-flops.&lt;/p&gt;&#xA;&lt;p&gt;Think of Yosys as the &lt;strong&gt;&lt;code&gt;gcc&lt;/code&gt; of hardware&lt;/strong&gt;. It compiles your design into something a chip fab (or FPGA) can understand. Yosys is scriptable, modular, and works with a ton of FPGA and ASIC flows. It&#39;s used in actual chip tapeouts through projects like &lt;a href=&#34;https://github.com/google/skywater-pdk&#34;&gt;Google&#39;s open PDKs&lt;/a&gt; (a PDK, or Process Design Kit, is basically the instruction manual for a specific chip fabrication process: it tells your tools how that particular factory makes transistors).&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i.postimg.cc/Jn1kcXy3/yosys-block-diagram.png&#34; alt=&#34;yosys-block-diagram&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;The synthesis flow: your high-level hardware description gets compiled down to actual logic gates that can be implemented in silicon.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;So, feed Yosys a simple Verilog module, run synthesis, and look at the output netlist. Watching your code transform into gates is pretty cool.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;3-place--route-openroad&#34;&gt;&lt;strong&gt;3. Place &amp;amp; Route: OpenROAD&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Synthesis gives you logic. Place &amp;amp; route gives you geometry: where each gate sits, how wires connect, timing constraints, power routing. This is the final step before manufacturing.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;https://theopenroadproject.org/&#34;&gt;OpenROAD&lt;/a&gt;&lt;/strong&gt; is an open-source ASIC flow that takes your gate-level netlist and turns it into an actual physical chip layout. It handles everything from floorplanning (deciding where blocks go) to detailed routing (connecting all the wires) to timing analysis (making sure your chip actually works at the speed you want).&lt;/p&gt;&#xA;&lt;p&gt;What makes OpenROAD special is that it&#39;s not just a toy project, it&#39;s being used in real chip tapeouts. Companies and researchers are using it with &lt;a href=&#34;https://github.com/google/skywater-pdk&#34;&gt;Google&#39;s SkyWater 130nm PDK&lt;/a&gt; and platforms like &lt;a href=&#34;https://chipflow.io/&#34;&gt;ChipFlow&lt;/a&gt; to manufacture actual silicon. The same flow that powers multi-million dollar chip designs is now available to anyone with a laptop.&lt;/p&gt;&#xA;&lt;p&gt;The workflow is surprisingly straightforward: feed it your synthesized netlist, tell it about your target technology (via a PDK), set your constraints, and let it do its thing. It&#39;ll optimize placement, route all the connections, check timing, and spit out a GDSII file, the final layout that gets sent to the fab.&lt;/p&gt;&#xA;&lt;p&gt;So, you&#39;re literally designing the physical layout of a chip. This used to be reserved for grad students and industry engineers and now it&#39;s something you can mess around with on a Tuesday night.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i.postimg.cc/QdFzq9L4/gds.png&#34; alt=&#34;gds.png&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;My chip layout post place &amp;amp; route. Those colorful rectangles and wires? That&#39;s real geometry heading to the fab.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;4-risc-v-cores-the-playground&#34;&gt;&lt;strong&gt;4. RISC-V Cores: The Playground&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Now that you have the tools, what do you build? Here&#39;s where pre-existing RISC-V cores come in, think of them as reference designs you can learn from, modify, extend and even contribute to.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;https://github.com/YosysHQ/picorv32&#34;&gt;PicoRV32&lt;/a&gt;&lt;/strong&gt; is arguably the most famous RISC-V core, tiny and simple around 1000 lines of Verilog. Perfect for beginners because you can actually read and understand the whole thing. Simulate it, run a &amp;quot;Hello World&amp;quot; program, trace how instructions execute.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i.postimg.cc/YCfJ04FM/picorv32.jpg&#34; alt=&#34;picorv32.jpg&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;https://github.com/riscv-boom/riscv-boom&#34;&gt;BOOM (Berkeley Out-of-Order Machine)&lt;/a&gt;&lt;/strong&gt; is the other end of the table, a high-performance, Out-of-Order RISC-V core. When you&#39;re ready to level up, BOOM teaches you modern processor techniques. Study the pipeline, see how dynamic scheduling works.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i.postimg.cc/3rcfxXbf/boom.png&#34; alt=&#34;boom.png&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;https://github.com/pranav0x0112/RISCape&#34;&gt;RISCape&lt;/a&gt;&lt;/strong&gt; (shameless plug) is my 5-stage pipelined RISC-V core. Built by a student, for students. If I can do it, you absolutely can too. Fork it, break it, fix it, extend it. That&#39;s how you learn.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i.postimg.cc/2jsJxdFB/riscape.png&#34; alt=&#34;riscape.png&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;We can see the three levels of RISC-V cores: PicoRV32 for learning the basics, RISCape for understanding pipelines, BOOM for exploring modern processor techniques.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;5-tiny-tapeout-your-shot-at-real-silicon&#34;&gt;&lt;strong&gt;5. Tiny Tapeout: Your Shot at Real Silicon&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Remember all those tools we just talked about? &lt;a href=&#34;https://tinytapeout.com/&#34;&gt;Tiny Tapeout&lt;/a&gt; is where you actually use them to manufacture real chips.&lt;/p&gt;&#xA;&lt;p&gt;Tiny Tapeout is a platform that makes chip fabrication accessible. Instead of paying hundreds of thousands of dollars for a solo manufacturing run, multiple designs get combined into one &amp;quot;shuttle&amp;quot; and share the cost. For around $100-150, you can get your design fabricated in actual silicon using processes like IHP SG13G2 or SkyWater 130nm. No company backing, no research lab required, just you, your design, and a submission deadline.&lt;/p&gt;&#xA;&lt;p&gt;I first heard about Tiny Tapeout while working on a &lt;a href=&#34;https://www.prawns.dev/blogs/what-is-a-soc/&#34;&gt;System-on-Chip (SoC) project&lt;/a&gt; with some friends. The idea that students could tape out real chips felt almost too good to be true. My first real dive was through a &lt;a href=&#34;https://tinytapeout.com/competitions/risc-v-peripheral/&#34;&gt;crowd-sourced competition&lt;/a&gt; where participants contributed peripherals for a RISC-V SoC. That got me hooked, read about my submission &lt;a href=&#34;https://www.prawns.dev/blogs/tiny-tone/&#34;&gt;here&lt;/a&gt;!&lt;/p&gt;&#xA;&lt;p&gt;After that, I decided to go all in and do a dedicated tapeout of my own: &lt;a href=&#34;https://github.com/pranav0x0112/Herald&#34;&gt;Herald&lt;/a&gt;, a co-processor that handles CORDIC (coordinate rotation) and MAC (multiply-accumulate) operations. The workflow? Design in Verilog, simulate it, synthesize with Yosys, place &amp;amp; route with OpenROAD, verify timing, submit your GDSII file, and wait for the shuttle to tape out.&lt;/p&gt;&#xA;&lt;p&gt;Sounds smooth, right? It wasn&#39;t. Errors after errors timing violations, things that worked in simulation but failed in hardware checks. But here&#39;s the thing: the Tiny Tapeout community is incredibly active. Ask a question on Discord (even if you think it&#39;s silly), and someone will help. The barriers aren&#39;t technical anymore, they&#39;re just learning curves, and the community helps you climb them.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i.postimg.cc/Zn6jLFgy/full-gds.png&#34; alt=&#34;full-gds.png&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Real Tiny Tapeout shuttle layout (Shuttle - IHP26A) showing multiple designs(including mine) combined into one manufacturing run. Each colorful section is someone&#39;s chip: students, hobbyists, researchers all sharing the same silicon :)&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;What makes Tiny Tapeout special isn&#39;t just that it&#39;s affordable. It&#39;s that you&#39;re using the &lt;strong&gt;exact same tools and flows&lt;/strong&gt; that industry uses. You&#39;re not playing with toy simulators or fake environments. You&#39;re designing real chips, following real constraints, and getting real manufactured silicon at the end. That&#39;s the ultimate validation.&lt;/p&gt;&#xA;&lt;p&gt;If you&#39;ve been following along with the tools in this post—Verilator, Yosys, OpenROAD then Tiny Tapeout is where you put them all together. It&#39;s the final level of the training arc: from simulating logic gates to holding a physical chip with your design etched into it.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;closing-the-only-question-left-is-what-will-you-build&#34;&gt;Closing: The Only Question Left Is &amp;quot;What Will You Build?&amp;quot;&lt;/h2&gt;&#xA;&lt;p&gt;A decade ago, you needed a million-dollar lab to design a processor. Today, you need a laptop and curiosity.&lt;/p&gt;&#xA;&lt;p&gt;The tools are here. The cores are open. The community is waiting.&lt;/p&gt;&#xA;&lt;p&gt;You&#39;ve seen the philosophy &lt;a href=&#34;https://homebrew.hsp-ec.xyz/posts/risc-v:-the-linux-of-hardware/&#34;&gt;here&lt;/a&gt;. You&#39;ve seen the tools in this post. In the next post, we&#39;ll go deep into pipelines, out-of-order execution, hazards, caches, and the real magic happening inside modern processors. We&#39;ll talk about how I approached building &lt;a href=&#34;https://github.com/pranav0x0112/RISCape&#34;&gt;RISCape&lt;/a&gt;, the challenges I faced, and what I learned about computer architecture along the way.&lt;/p&gt;&#xA;&lt;p&gt;But for now? Start small. Run the tools. Let things break.&#xA;The rest follows.&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>Why GPU Threads Aren’t What They Look Like: SIMT + Divergence Explained</title>
      <link>https://anna-docs.netlify.app/blogs/simt_warp_divergence/</link>
      <pubDate>Tue, 02 Dec 2025 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/simt_warp_divergence/</guid>
      <description></description>
    </item>
    <item>
      <title>Tiny Tone - My First Accepted Tiny-Tapeout Design</title>
      <link>https://anna-docs.netlify.app/blogs/tiny-tone/</link>
      <pubDate>Sat, 25 Oct 2025 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/tiny-tone/</guid>
      <description>&lt;h2 id=&#34;introduction&#34;&gt;Introduction&lt;/h2&gt;&#xA;&lt;p&gt;In this blog, I share a small but meaningful design I submitted to the &lt;a href=&#34;https://github.com/TinyTapeout/ttsky25a-tinyQV&#34;&gt;TinyQV tapeout program&lt;/a&gt;, what it is, why it matters to me, and what I learned along the way. Before we understand what my design is all about, let’s be clear with some common terminologies I use in this blog.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;what-is-tinyqv&#34;&gt;What is TinyQV?&lt;/h2&gt;&#xA;&lt;p&gt;Tiny-QV is a collaborative competition under the &lt;a href=&#34;https://tinytapeout.com/&#34;&gt;&lt;strong&gt;Tiny Tapeout&lt;/strong&gt;&lt;/a&gt; program. The goal is to build a small but complete RISC-V SoC, where the CPU and peripherals are designed to be simple and within the strict constraints of Tiny Tapeout.&lt;/p&gt;&#xA;&lt;p&gt;At its heart is &lt;strong&gt;TinyQV&lt;/strong&gt;, a lightweight RISC-V CPU that implements the RV32EC instruction set along with the Zcb and Zicond extensions.&lt;/p&gt;&#xA;&lt;p&gt;The really fun part: the &lt;strong&gt;peripherals&lt;/strong&gt; that complete the SoC are contributed by the &lt;a href=&#34;https://en.wikipedia.org/wiki/Open_source&#34;&gt;open source&lt;/a&gt; community. Each submission is a chance to have your logic integrated into silicon and that’s where my project, &lt;a href=&#34;https://github.com/pranav0x0112/tiny-tone&#34;&gt;&lt;strong&gt;Tiny-Tone&lt;/strong&gt;&lt;/a&gt;, fits in.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://github.com/TinyTapeout/ttsky25a-tinyQV/raw/main/docs/riscv_compo.jpg&#34; alt=&#34;Risc-V competition logo&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;what-is-tapeout&#34;&gt;What is Tapeout?&lt;/h2&gt;&#xA;&lt;p&gt;In chip design, &lt;em&gt;tapeout&lt;/em&gt; is the moment when a design is functionally verified and sent off to be manufactured on real silicon. Back in the day, this really did involve shipping magnetic tapes to the fabrication plant and while the process is digital now, the name stuck around.&lt;/p&gt;&#xA;&lt;p&gt;Tapeout is a milestone because it marks the point where your idea leaves the world of simulation and code, and takes its first steps toward becoming a physical chip. For many hardware designers, it’s the most exciting part of the journey.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;introducing-tiny-tone&#34;&gt;Introducing Tiny-Tone&lt;/h2&gt;&#xA;&lt;p&gt;My contribution to Tiny QV is called &lt;strong&gt;Tiny-Tone&lt;/strong&gt;: a PWM-based audio tone generator written in &lt;a href=&#34;https://github.com/rsnikhil/Bluespec_BSV_Tutorial&#34;&gt;Bluespec SystemVerilog&lt;/a&gt;. The goal was simple create a small peripheral that could generate audible tones using just digital logic.&lt;/p&gt;&#xA;&lt;p&gt;This design felt perfect for tapeout: it’s compact, demonstrable, and educational. When the chips come back, I’ll be able to hook up a speaker and hear it play tones( if I’m able to afford it :D ).&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;understanding-pwm-pulse-width-modulation&#34;&gt;Understanding PWM (Pulse Width Modulation)&lt;/h2&gt;&#xA;&lt;p&gt;Imagine quickly flipping a light switch on and off. If it’s on half the time and off half the time, the &lt;em&gt;average&lt;/em&gt; brightness looks like 50%. If it’s on 90% of the time, it looks almost fully bright. That’s the basic idea behind &lt;strong&gt;PWM&lt;/strong&gt;: controlling the &lt;a href=&#34;https://en.wikipedia.org/wiki/Duty_cycle&#34;&gt;&lt;em&gt;duty cycle&lt;/em&gt;&lt;/a&gt;, the fraction of time the signal is “on” vs. “off.”&lt;/p&gt;&#xA;&lt;p&gt;For audio, we can do something similar. Instead of controlling brightness, the rapid on/off pattern controls how a speaker cone moves. If we switch fast enough, the speaker naturally smooths out the square wave, and what you hear is a steady tone.&lt;/p&gt;&#xA;&lt;p&gt;In &lt;strong&gt;Tiny-Tone&lt;/strong&gt;, I used PWM to generate these patterns at different frequencies. Changing the frequency changes the pitch of the tone, and adjusting the duty cycle changes its character. With just digital logic, you can make a speaker “sing.”&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://circuitdigest.com/sites/default/files/projectimage_tut/Pulse-Width-Modulation.jpg&#34; alt=&#34;What is PWM: Pulse Width Modulation&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;With Tiny-Tone, I can control the &lt;strong&gt;frequency&lt;/strong&gt; of the PWM signal, which changes the &lt;em&gt;pitch&lt;/em&gt; of the sound, and adjust the &lt;strong&gt;duty cycle&lt;/strong&gt;, which changes how the sound feels when it comes out of the speaker.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;PWM isn’t just for audio related operations, it’s everywhere. For example, the brightness of an LED is often controlled with PWM, and the speed of motors in drones or fans is set the same way.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;my-implementation&#34;&gt;My Implementation&lt;/h2&gt;&#xA;&lt;p&gt;I started by writing the &lt;a href=&#34;https://en.wikipedia.org/wiki/Register-transfer_level&#34;&gt;RTL&lt;/a&gt; in &lt;strong&gt;Bluespec SystemVerilog&lt;/strong&gt;, which is great for building modular hardware. Its rule-based approach and strong type system made it easy to organize the design cleanly.&lt;/p&gt;&#xA;&lt;p&gt;The &lt;strong&gt;Tiny-Tone&lt;/strong&gt; peripheral is essentially a small, configurable PWM generator that can be controlled from software. The design has two main parts:&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Tone Generator&lt;/strong&gt; – This module creates the PWM signal. You can enable or disable it and set the frequency at runtime. The output is a single digital line that toggles according to the programmed tone.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Peripheral Wrapper&lt;/strong&gt; – This exposes the generator to the rest of the SoC using a simple memory-mapped interface. Software can turn the tone on/off, change the frequency, and read back status, all through a few registers.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;I also wrote a &lt;strong&gt;Bluespec testbench&lt;/strong&gt; to make sure everything worked as expected. It exercised the registers, ran the PWM signal, and verified that enabling/disabling the tone behaved correctly.&lt;/p&gt;&#xA;&lt;p&gt;Finally, the design was &lt;strong&gt;compiled to Verilog&lt;/strong&gt; for Tiny Tapeout, wrapped in a top-level harness, and paired with a Python cocotb testbench for automated simulation. This made integration with the SoC straightforward and allowed for continuous verification.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;challenges-i-faced-and-how-i-fixed-them&#34;&gt;Challenges I Faced and How I Fixed Them&lt;/h2&gt;&#xA;&lt;p&gt;Every hardware design brings its own set of challenges, not just in writing RTL, but also in meeting real-world constraints like area limits, timing, and integration requirements. In my case, working with &lt;strong&gt;Bluespec SystemVerilog&lt;/strong&gt; added an extra twist: I had to convert my design to Verilog before it could be accepted into Tiny Tapeout.&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&#xA;&lt;h4 id=&#34;integration-with-tiny-tapeout&#34;&gt;Integration with Tiny Tapeout&lt;/h4&gt;&#xA;&lt;p&gt;Adapting the Bluespec-generated Verilog to fit the Tiny-QV SoC interface wasn’t just a drop-in task. I needed to carefully map ports and build a wrapper so that my peripheral played nicely with the rest of the system.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;h4 id=&#34;debugging-the-peripheral&#34;&gt;Debugging the Peripheral&lt;/h4&gt;&#xA;&lt;p&gt;One tricky bug showed up during cocotb testing. When I wrote a word (e.g., &lt;code&gt;0x82345678&lt;/code&gt;) to register &lt;code&gt;0&lt;/code&gt; and tried reading back the byte at that address, I got &lt;code&gt;0&lt;/code&gt; instead of the expected &lt;code&gt;0x78&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;After digging into the generated Verilog, I realized the problem: my Bluespec peripheral only supported &lt;strong&gt;byte writes&lt;/strong&gt; (&lt;code&gt;data_write_n == 2&#39;b00&lt;/code&gt;), but the testbench was doing a &lt;strong&gt;word write&lt;/strong&gt; (&lt;code&gt;data_write_n == 2&#39;b10&lt;/code&gt;).&lt;/p&gt;&#xA;&lt;h4 id=&#34;the-fix&#34;&gt;The Fix&lt;/h4&gt;&#xA;&lt;p&gt;The solution was simple once I understood the mismatch: I updated the test to use a byte write (&lt;code&gt;write_byte_reg&lt;/code&gt;) instead of a word write. Now the writes lined up with what the peripheral supported, and the test passed cleanly.&lt;/p&gt;&#xA;&lt;p&gt;This might sound like a small detail, but debugging it taught me a lot about how &lt;strong&gt;interfaces and toolchains can disagree&lt;/strong&gt; and how important it is to understand what your generated RTL actually supports.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;what-i-learned&#34;&gt;What I Learned&lt;/h2&gt;&#xA;&lt;p&gt;This project taught me a few valuable lessons:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Designing for &lt;strong&gt;tapeout constraints&lt;/strong&gt; is very different from simulating freely. Every gate, every bit of logic matters.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Writing in a high-level HDL (like Bluespec) is powerful, but translating to Verilog forces you to think about the details.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;The excitement of knowing your design will physically exist on silicon is unmatched :P&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Tiny-Tone is my first accepted tapeout design, and it won’t be my last. The journey of taking this design from idea to tapeout has been just as exciting as waiting for the day it comes alive on silicon. This journey has been equal parts challenging and rewarding and it marks the start of many more hardware adventures.&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>RISC-V: The Linux of Hardware</title>
      <link>https://anna-docs.netlify.app/blogs/riscv-linux/</link>
      <pubDate>Sun, 07 Sep 2025 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/riscv-linux/</guid>
      <description>&lt;h2 id=&#34;the-hidden-half-of-computing&#34;&gt;The Hidden Half of Computing&lt;/h2&gt;&#xA;&lt;p&gt;Most of us discover &lt;a href=&#34;https://homebrew.hsp-ec.xyz/posts/the-world-of-open-source!/&#34;&gt;FOSS&lt;/a&gt; through software: cool Linux distros, editors, frameworks and many other tools that make our life easier. But beneath all that is a world not many of us think about: the microchips that run our code. All this while, this world was locked away behind billion-dollar corporations and closed &lt;a href=&#34;https://en.wikipedia.org/wiki/Instruction_set_architecture&#34;&gt;Instruction Set Architectures&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;Say hello to &lt;a href=&#34;https://en.wikipedia.org/wiki/RISC-V&#34;&gt;RISC-V (Reduced Instruction Set Computer)&lt;/a&gt; — an open source Instruction Set Architecture(ISA) that’s doing to hardware what Linux did to operating systems. This blog is a quick introduction to what RISC-V is, why it matters, and how it fits perfectly into the FOSS spirit.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;so-whats-an-isa-anyway&#34;&gt;So What’s an ISA anyway?&lt;/h2&gt;&#xA;&lt;p&gt;We all speak different languages with our own unique grammar. Similarly, a processor has its own “grammar” called an &lt;strong&gt;Instruction Set Architecture (ISA)&lt;/strong&gt; — the rules that define how software talks to hardware.&lt;/p&gt;&#xA;&lt;p&gt;When you think “processor,” names like Intel’s x86 or AMD’s Ryzen probably come to mind. Maybe you’ve even heard of ARM chips in mobile phones and Raspberry Pi. But here’s the catch: all of these are &lt;strong&gt;proprietary&lt;/strong&gt;. That means if you want to design a chip with them, you’ll need to pay hefty license fees, sign NDAs, and basically fight uphill just to get started.&lt;/p&gt;&#xA;&lt;p&gt;Back in 2010, researchers at &lt;a href=&#34;https://www.sifive.com/blog/from-berkeley-lab-to-global-standard-risc-vs-15-ye&#34;&gt;UC Berkeley&lt;/a&gt; decided to change that. Their project: RISC-V — an open source, free and modular ISA. This means anyone can use it, extend it and guess what even add their own instructions! The entire script was flipped, making hardware innovation as open as software innovation.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://www.eetasia.com/wp-content/uploads/sites/2/2021/12/RISC-V-logo-1.jpg?w=600&amp;amp;h=442&amp;amp;crop=1&#34; alt=&#34;SiFive Unveils 64-Bit RISC-V Server Core - EE Times Asia&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;why-should-students-care-about-risc-v&#34;&gt;Why should students care about RISC-V?&lt;/h2&gt;&#xA;&lt;h3 id=&#34;1-foss-energy--the-same-spirit-as-linux&#34;&gt;&lt;strong&gt;1. FOSS energy → The same spirit as Linux&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;The openness of RISC-V has created ecosystems much like Linux did — thriving communities, student-led projects, multiple open-source processor cores, Discord servers buzzing with discussions, and more. It’s not just an ISA; it’s a culture you can join and shape.&lt;/p&gt;&#xA;&lt;h3 id=&#34;2-a-real-learning-playground--no-glass-walls&#34;&gt;&lt;strong&gt;2. A real learning playground → No glass walls&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Hardware design often feels like wizardry happening in corporate or research labs. But RISC-V opens the doors for everyone. Curious about how a processor works internally? You can:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Browse and study real RISC-V cores on GitHub: from tiny educational cores to ones capable of running Linux.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Simulate a RISC-V CPU using open-source tools like &lt;a href=&#34;https://en.wikipedia.org/wiki/QEMU&#34;&gt;QEMU&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://raw.githubusercontent.com/mortbopet/Ripes/refs/heads/master/resources/images/animation.gif&#34; alt=&#34;Ripes Simulation&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;Peek inside a RISC-V CPU: one instruction at a time, courtesy of&lt;/strong&gt; &lt;a href=&#34;https://github.com/mortbopet/Ripes&#34;&gt;&lt;strong&gt;Ripes&lt;/strong&gt;&lt;/a&gt;&lt;strong&gt;.&lt;/strong&gt; You’re not stuck just reading theory; you can &lt;strong&gt;play with the real thing&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;h3 id=&#34;3-structured-guidance--mentorship-and-learning-programs&#34;&gt;&lt;strong&gt;3. Structured guidance → Mentorship and learning programs&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;RISC-V isn’t just open; it’s supportive. The &lt;a href=&#34;https://riscv.org/&#34;&gt;RISC-V Foundation&lt;/a&gt; hosts mentorship programs, student contests, workshops, and provides online resources. Beginners can pair up with experienced developers, contribute to real cores, and learn in a guided environment which makes the learning curve far less intimidating.&lt;/p&gt;&#xA;&lt;h3 id=&#34;4-industry-shift--where-the-world-is-heading&#34;&gt;&lt;strong&gt;4. Industry shift → Where the world is heading&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;This isn’t just about tinkering. RISC-V is becoming a global standard. Tech giants like Intel, NVIDIA, Google, and Qualcomm are adopting it. That means demand for engineers who understand RISC-V is going to rise. As students, learning it now is like learning Linux in the early 2000s: the skills are future-proof.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;why-risc-v-resonates-with-me&#34;&gt;Why RISC-V Resonates with me?&lt;/h2&gt;&#xA;&lt;p&gt;My first introduction to RISC-V was at &lt;a href=&#34;https://hsp-ec.xyz/announcements/tilde-4.0&#34;&gt;Tilde&lt;/a&gt;, HSP’s flagship summer mentorship program where we were tasked with building a RISC processor in &lt;a href=&#34;https://en.wikipedia.org/wiki/Verilog&#34;&gt;Verilog&lt;/a&gt;. Although I wasn’t able to continue with the project, I was given access to vast resources that opened the door to the world of RISC. I started out with simple &lt;a href=&#34;https://training.linuxfoundation.org/training/introduction-to-riscv-lfd110/&#34;&gt;Linux Foundation courses&lt;/a&gt; and quickly found myself immersed in the subject, having already delved deep into Digital VLSI.&lt;/p&gt;&#xA;&lt;p&gt;Soon, I was diving into books and research papers to understand the architecture and design principles of RISC-V. At the same time, I was building &lt;a href=&#34;https://github.com/pranav0x0112/RISCape&#34;&gt;&lt;strong&gt;RISCape&lt;/strong&gt;&lt;/a&gt;, a 5-stage pipelined RISC-V processor. Reading the theory while implementing it side by side made the concepts click in a way no textbook alone could achieve.&lt;/p&gt;&#xA;&lt;p&gt;This hands-on approach showed me the real power of open architectures: students can explore, experiment, and actually &lt;strong&gt;make things work&lt;/strong&gt;, all without asking for permission. If it got me hooked, it can probably do the same for you: grab a core, start experimenting, and see where it takes you.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://i0.wp.com/makerstuffs.com/wp-content/uploads/2015/03/procc.png?resize=1024%2C720&amp;amp;ssl=1&#34; alt=&#34;RTL Design &amp;amp; Implementation of a RISC- Single Cycle Processor -Part I –  Maker Stuffs&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;closing-thoughts&#34;&gt;Closing Thoughts&lt;/h2&gt;&#xA;&lt;p&gt;RISC-V is more than just a processor architecture: it’s an open, collaborative ecosystem that mirrors the FOSS philosophy we see in software. From student-friendly cores to real-world applications, it’s shaping the way hardware can be explored, understood, and innovated upon.&lt;/p&gt;&#xA;&lt;p&gt;In the next post, we’ll dive into the tools and resources that make experimenting with hardware easier. From simulators to development frameworks and see how you can start building your own projects from scratch.&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>Aetheron: Bringing My Own SoC to Life</title>
      <link>https://anna-docs.netlify.app/blogs/aetheron/</link>
      <pubDate>Fri, 18 Jul 2025 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/aetheron/</guid>
      <description>&lt;h2 id=&#34;introduction&#34;&gt;Introduction&lt;/h2&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://github.com/pranav0x0112/Aetheron&#34;&gt;Aetheron&lt;/a&gt; is a small but complete RISC-V &lt;a href=&#34;https://en.wikipedia.org/wiki/System_on_a_chip&#34;&gt;System-on-Chip&lt;/a&gt;, built entirely in &lt;a href=&#34;https://github.com/rsnikhil/Bluespec_BSV_Tutorial&#34;&gt;Bluespec SystemVerilog&lt;/a&gt; and run in simulation. It features a pipelined CPU, memory-mapped peripherals, my own minimal TileLink interconnect, and can boot minimal bare metal C programs — all stitched together from scratch.&lt;/p&gt;&#xA;&lt;p&gt;But it’s more than just a collection of modules.&lt;/p&gt;&#xA;&lt;p&gt;I’ve always loved the idea of designing systems — not just writing code or building hardware in isolation, but understanding how they blend together. Fortunately, I had the privilege to attend a three-day workshop hosted by my seniors, &lt;a href=&#34;https://www.linkedin.com/in/devesh-bhaskaran/&#34;&gt;Devesh Bhaskaran&lt;/a&gt; and &lt;a href=&#34;https://www.linkedin.com/in/alfadelta10010/&#34;&gt;Abhiram Gopal Dasika&lt;/a&gt; where I was introduced to the world of &lt;strong&gt;Automotive SoC Design&lt;/strong&gt;. I decided I wanted to build something that felt &lt;strong&gt;real&lt;/strong&gt;: where the CPU actually boots a program, where peripherals respond to memory-mapped I/O, and where every instruction running in software maps to a transaction on a bus.&lt;/p&gt;&#xA;&lt;p&gt;&amp;quot;Aetheron&amp;quot; was born out of that drive.&lt;/p&gt;&#xA;&lt;p&gt;It started with just a CPU core, then quickly spiraled into a full-on SoC: with ROM, RAM, &lt;a href=&#34;https://en.wikipedia.org/wiki/Universal_asynchronous_receiver-transmitter&#34;&gt;UART&lt;/a&gt;, and a &lt;a href=&#34;https://starfivetech.com/uploads/tilelink_spec_1.8.1.pdf&#34;&gt;TileLink&lt;/a&gt; fabric to tie everything together. I didn’t want to reuse cores or plug in pre-built peripherals. This had to be something I understood fully — every wire, every rule, every hex file in the ROM image.&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Curious to know what exactly is a SoC? Click &lt;a href=&#34;https://prawns.dev/blogs/what-is-a-soc/&#34;&gt;here&lt;/a&gt; to read my blog about Introduction to SoCs.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;setting-the-vision&#34;&gt;Setting the Vision&lt;/h2&gt;&#xA;&lt;h3 id=&#34;what-i-wanted-to-build&#34;&gt;&lt;strong&gt;What I wanted to build&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;From day one, I wasn’t interested in just blinking LEDs or simulating a few instructions. My goal was clear: build a &lt;strong&gt;bootable SoC&lt;/strong&gt; that could run real software — not a demo, not hardcoded testbenches, but actual compiled C programs.&lt;/p&gt;&#xA;&lt;p&gt;I wanted:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;A pipelined &lt;strong&gt;RISC-V CPU&lt;/strong&gt; (RV32I) I could understand and modify.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;ROM&lt;/strong&gt; and &lt;strong&gt;RAM&lt;/strong&gt; memory regions with clear separation.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;A &lt;strong&gt;TileLink&lt;/strong&gt; interconnect, for clean and modular communication.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Memory-mapped peripherals like &lt;strong&gt;UART&lt;/strong&gt;, &lt;strong&gt;GPIO&lt;/strong&gt;, and &lt;strong&gt;Timer&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;A boot process where the CPU fetched code from ROM, copied payloads into RAM, and executed them like a real embedded system.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;In short: something you could imagine dropping into a real chip, even if it never left simulation.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;early-decisions-i-made&#34;&gt;Early decisions I made&lt;/h2&gt;&#xA;&lt;p&gt;One of the first choices was the instruction set. I went with &lt;strong&gt;RISC-V&lt;/strong&gt; because it&#39;s clean, open, and designed to be simple — perfect for a project like this. It made writing my CPU pipeline much more enjoyable and gave me a standard to work against.&lt;/p&gt;&#xA;&lt;p&gt;For the HDL, I chose &lt;strong&gt;Bluespec SystemVerilog (BSV)&lt;/strong&gt;. I already had experience with Verilog, but Bluespec’s rule-based semantics and powerful types made building a modular system much easier. Once you wrap your head around guarded atomic actions, you realize how expressive it is — especially for designing protocols like TileLink.&lt;/p&gt;&#xA;&lt;p&gt;I also went with &lt;strong&gt;TileLink&lt;/strong&gt; as the on-chip interconnect protocol instead of something like &lt;a href=&#34;https://developer.arm.com/documentation/102202/0300/What-is-AMBA--and-why-use-it-&#34;&gt;AMBA&lt;/a&gt;. TileLink’s open, light weight and fully-specified nature made it easier to reason about formally. Its decoupled, pipelined &lt;code&gt;a&lt;/code&gt;/&lt;code&gt;d&lt;/code&gt; channel design fit naturally into the rule-based model of BSV, and it scaled well as I added more peripherals.&lt;/p&gt;&#xA;&lt;p&gt;Finally, I decided early on that &lt;strong&gt;simulation-only was totally fine&lt;/strong&gt;. I wasn’t aiming to synthesize this on an FPGA. I just wanted correctness, modularity, and the ability to run and debug C code end to end. That freedom let me move faster and focus on the design, not timing closure or board quirks.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;the-first-steps&#34;&gt;The First Steps&lt;/h2&gt;&#xA;&lt;h3 id=&#34;designing-the-building-blocks&#34;&gt;&lt;strong&gt;Designing the building blocks&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;I began with the bare minimum: a &lt;strong&gt;CPU&lt;/strong&gt;, &lt;strong&gt;ROM&lt;/strong&gt;, &lt;strong&gt;RAM&lt;/strong&gt;, and &lt;strong&gt;UART&lt;/strong&gt; — all stitched together through a custom &lt;strong&gt;TileLink interconnect&lt;/strong&gt;. At this point, the SoC didn’t boot any real programs. It wasn’t even executing C yet. But my focus was on getting the &lt;strong&gt;pipeline running&lt;/strong&gt; in order to see actual instructions being fetched, decoded, and executed.&lt;/p&gt;&#xA;&lt;p&gt;The &lt;strong&gt;CPU design started as a stub&lt;/strong&gt; — a placeholder module that just returned hardcoded values. It helped me bring up the rest of the system without worrying about instruction execution yet. Once the rest of the SoC took shape, I &lt;strong&gt;replaced the stub with a proper 5-stage pipelined core&lt;/strong&gt; called &lt;a href=&#34;https://github.com/pranav0x0112/Specula&#34;&gt;&lt;strong&gt;Specula&lt;/strong&gt;&lt;/a&gt;. At the time, Specula was a relatively simple in-order RISC-V core. It would eventually evolve into something far more ambitious: a true &lt;strong&gt;Out-of-Order&lt;/strong&gt; processor. But for now, it was my way of getting real programs flowing through an instruction pipeline.&lt;/p&gt;&#xA;&lt;p&gt;The &lt;strong&gt;ROM&lt;/strong&gt; was modeled as a read-only memory block, used to hold the bootloader and payload at simulation time. The &lt;strong&gt;RAM&lt;/strong&gt; was a simple byte-addressable memory model, accessible via TileLink. And the &lt;strong&gt;UART&lt;/strong&gt;, while basic, was my only way to get output from inside the SoC — my single window into what the CPU was doing.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://github.com/pranav0x0112/Aetheron/blob/main/misc/full_rom_to_ram_boot.png?raw=true&#34; alt=&#34;full_rom_to_ram_boot.png&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;The full ROM → RAM boot process in Aetheron&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;h3 id=&#34;testing-with-assembly&#34;&gt;&lt;strong&gt;Testing with assembly&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;At this stage, I was manually writing tiny &lt;strong&gt;RISC-V assembly test programs&lt;/strong&gt;, compiling them into &lt;code&gt;.text&lt;/code&gt; and &lt;code&gt;.data&lt;/code&gt; sections, converting them into hex files, and loading them into ROM. No C yet — just handcrafted instructions to test branching, memory stores, and UART writes.&lt;/p&gt;&#xA;&lt;p&gt;This was also when I first got UART output working in my assembly code.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://github.com/pranav0x0112/Aetheron/blob/main/misc/uart_success.png?raw=true&#34; alt=&#34;uart_success.png&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;And just like that the CPU could &lt;em&gt;talk&lt;/em&gt; :D&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;roadblocks--debugging-era&#34;&gt;Roadblocks &amp;amp; Debugging Era&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;As with all systems design, just when things seemed stable — everything broke.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Up to this point, I had a functioning ROM, RAM, UART, and a pipelined CPU. My bootloader, written in RISC-V assembly, was executing correctly, and I could print characters over UART using simple &lt;code&gt;sw&lt;/code&gt; instructions. Things felt solid. It was time to try running a C program.&lt;/p&gt;&#xA;&lt;p&gt;That’s when it all began to crumble.&lt;/p&gt;&#xA;&lt;h3 id=&#34;1-the-case-of-the-silent-uart&#34;&gt;1. The Case of the Silent UART&lt;/h3&gt;&#xA;&lt;p&gt;I compiled a tiny C program, linked it with my custom script, and embedded the binary into ROM. But when I ran the simulation… nothing. No UART output. Just silence.&lt;/p&gt;&#xA;&lt;p&gt;I suspected a mapping issue. Was my C code writing to the wrong MMIO address? But &lt;code&gt;UART_ADDRESS = 0x40001000&lt;/code&gt; matched in both hardware and software. Everything checked out — yet nothing was printing.&lt;/p&gt;&#xA;&lt;p&gt;I turned to trace logs. I dumped every memory access, register write, UART state change. That’s when I noticed: the CPU wasn&#39;t even reaching &lt;code&gt;printf()&lt;/code&gt;. It was looping somewhere much earlier.&lt;/p&gt;&#xA;&lt;h3 id=&#34;2-memory-mapping--peripheral-routing&#34;&gt;2. Memory Mapping &amp;amp; Peripheral Routing&lt;/h3&gt;&#xA;&lt;p&gt;Maybe the hardware was at fault? I added debug prints in the TileLink interconnect and peripherals. I confirmed: writes to &lt;code&gt;0x40001000&lt;/code&gt; &lt;em&gt;were&lt;/em&gt; routed correctly to the UART. Address decoding wasn’t the issue.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://github.com/pranav0x0112/Aetheron/raw/main/misc/memory-map.png&#34; alt=&#34;Aetheron-Memory-Map&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;h3 id=&#34;3-toolchain--linker-script-confusion&#34;&gt;3. Toolchain &amp;amp; Linker Script Confusion&lt;/h3&gt;&#xA;&lt;p&gt;The Makefile, linker scripts, and &lt;code&gt;objcopy&lt;/code&gt; pipeline were fragile. I reviewed every line: memory regions, section assignments, symbol names. Using &lt;code&gt;readelf&lt;/code&gt;, &lt;code&gt;objdump&lt;/code&gt;, and &lt;code&gt;objcopy&lt;/code&gt;, I inspected each ELF and binary output. Slowly, I rebuilt a correct linker script that mapped ROM and RAM properly.&lt;/p&gt;&#xA;&lt;p&gt;But still — the program didn’t run.&lt;/p&gt;&#xA;&lt;h3 id=&#34;4-the-payload-that-never-was&#34;&gt;4. The Payload That Never Was&lt;/h3&gt;&#xA;&lt;p&gt;Finally, I suspected a deeper issue — not the code itself, but how it was getting into ROM.&lt;/p&gt;&#xA;&lt;p&gt;See, my bootloader was supposed to copy a &lt;code&gt;.payload&lt;/code&gt; section from ROM to RAM, then jump to it. But what if that section wasn’t even being included in the final ROM image?&lt;/p&gt;&#xA;&lt;p&gt;I checked the ELF file using &lt;code&gt;riscv64-elf-objdump -h&lt;/code&gt; and saw something weird: the &lt;code&gt;.payload&lt;/code&gt; section was listed, but with &lt;code&gt;VMA = 0x0&lt;/code&gt; and zero file offset. It looked like the section existed… but wasn’t actually backed by any data in the binary.&lt;/p&gt;&#xA;&lt;p&gt;The culprit was &lt;code&gt;objcopy&lt;/code&gt;. My Makefile used:&lt;/p&gt;&#xA;&lt;pre&gt;&lt;code class=&#34;language-bash&#34;&gt;riscv64-elf-objcopy -O binary -j .payload ...&#xA;&lt;/code&gt;&lt;/pre&gt;&#xA;&lt;p&gt;But that doesn’t extract the section properly if the linker never placed it right in the first place.&lt;/p&gt;&#xA;&lt;p&gt;At one point, my linker script had something &lt;em&gt;like&lt;/em&gt;:&lt;/p&gt;&#xA;&lt;pre&gt;&lt;code class=&#34;language-plaintext&#34;&gt;.payload : { *(.text .text.* .rodata .data .bss) }&#xA;&lt;/code&gt;&lt;/pre&gt;&#xA;&lt;p&gt;But that only works if the incoming &lt;code&gt;.o&lt;/code&gt; file explicitly labels those sections as part of &lt;code&gt;.payload&lt;/code&gt;. In my case, it didn’t. The payload data existed under normal sections (&lt;code&gt;.text&lt;/code&gt;, &lt;code&gt;.rodata&lt;/code&gt;, etc.), but nothing instructed the linker to collect them under &lt;code&gt;.payload&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;I rewrote the linker script to explicitly place the payload contents, added the &lt;code&gt;.payload&lt;/code&gt; symbol in the source to force section labeling, and rechecked everything with &lt;code&gt;objdump&lt;/code&gt;. This time the section showed up with the right address and size. The resulting &lt;code&gt;.bin&lt;/code&gt; was properly populated.&lt;/p&gt;&#xA;&lt;p&gt;I regenerated &lt;code&gt;rom.hex&lt;/code&gt;, ran the simulation… and there it was. My &lt;code&gt;rom.hex&lt;/code&gt; finally contained a working payload, and Aetheron executed its first C program.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;key-learnings&#34;&gt;Key Learnings&lt;/h2&gt;&#xA;&lt;p&gt;Looking back, building Aetheron taught me far more than just how to wire up peripherals or write linker scripts.&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Hardware/software co-design is real.&lt;/strong&gt; Designing the SoC and writing code for it in tandem helped me see how tightly coupled these layers are. Every software bug was a chance to inspect my hardware — and vice versa.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Debugging is a full-stack art.&lt;/strong&gt; From the ROM image to C code to UART signals, every layer matters. Sometimes the problem isn’t the code — it’s how your tools handle it.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Don’t underestimate simulation.&lt;/strong&gt; I didn&#39;t need an FPGA or fancy board. Just a solid simulation setup, trace dumps, and a good mental model were enough to build and boot real programs.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Most importantly, I learned to enjoy the grind — to sit with a problem, question every assumption, and slowly trace my way to a solution.&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Interested to read about my SoC Learnings? &lt;a href=&#34;https://github.com/pranav0x0112/prawns-stack/tree/main/SoC_learnings&#34;&gt;Click here&lt;/a&gt; :D, I try to keep it up-to-date.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;whats-next&#34;&gt;What’s Next&lt;/h2&gt;&#xA;&lt;p&gt;Aetheron is far from finished. There’s still a lot more I want to explore and build on top of it. One of the first goals is adding interrupt support, so peripherals like the Timer can trigger software events.&lt;/p&gt;&#xA;&lt;p&gt;And then there&#39;s a fun suggestion from one of my seniors &lt;a href=&#34;https://www.linkedin.com/in/joyenbenitto/&#34;&gt;Joyen Benitto&lt;/a&gt; where he mentioned I should try building a custom accelerator that sits on an AHB TileLink slave port. Maybe a memory-mapped matrix multiplier: write your operands to an address, and read back the result. That idea stuck with me. Now that the TileLink fabric and basic SoC infrastructure are in place, Aetheron feels like the perfect playground to try something like that.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;final-thoughts&#34;&gt;Final Thoughts&lt;/h2&gt;&#xA;&lt;p&gt;Aetheron was more than just a successful project as it reflects how I think, the systems I dream of, and the way I approach problems. It’s a culmination of goals, ideas, mistakes, and long nights chasing one more bug.&lt;/p&gt;&#xA;&lt;p&gt;I hope it also serves as a spark for others to build their own systems, question abstractions, and enjoy the messy, brilliant process of bringing hardware to life!&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>What is a System-on-Chip, Really?</title>
      <link>https://anna-docs.netlify.app/blogs/what-is-a-soc/</link>
      <pubDate>Fri, 18 Jul 2025 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/what-is-a-soc/</guid>
      <description>&lt;h2 id=&#34;introduction&#34;&gt;Introduction&lt;/h2&gt;&#xA;&lt;p&gt;You’ve probably heard the term “System-on-Chip” before. Maybe it popped out from our daily usage of Smartphones, Automotive Vehicles or even a Raspberry Pi board! It sounds important (it &lt;em&gt;is&lt;/em&gt; important), maybe even futuristic. But let’s rewind for a moment and ask the real question:&lt;/p&gt;&#xA;&lt;h3 id=&#34;what--is--a-system-on-chip-really&#34;&gt;What &lt;em&gt;is&lt;/em&gt; a System-on-Chip, really?&lt;/h3&gt;&#xA;&lt;p&gt;I’ve wanted to understand this for a long time. But textbook definitions never satisfied me—I didn’t just want to &lt;em&gt;use&lt;/em&gt; SoCs, I wanted to understand what made them &lt;em&gt;tick&lt;/em&gt;.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;what-is-a-soc&#34;&gt;What is a SoC?&lt;/h2&gt;&#xA;&lt;p&gt;At its core, a &lt;a href=&#34;https://en.wikipedia.org/wiki/System_on_a_chip&#34;&gt;System-on-Chip (SoC)&lt;/a&gt; is exactly what the name suggest: a complete computing system squeezed into a single chip of silicon. Unlike a general-purpose standalone processor that only handles computation and needs support from external memory or I/O, an SoC pulls everything together:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;a &lt;a href=&#34;https://en.wikipedia.org/wiki/Central_processing_unit&#34;&gt;CPU&lt;/a&gt; (or more than one)&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;memory (ROM, RAM, Flash memory)&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;peripherals (&lt;a href=&#34;https://en.wikipedia.org/wiki/Universal_asynchronous_receiver-transmitter&#34;&gt;UART&lt;/a&gt;, &lt;a href=&#34;https://en.wikipedia.org/wiki/General-purpose_input/output&#34;&gt;GPIO&lt;/a&gt;, &lt;a href=&#34;https://en.wikipedia.org/wiki/Serial_Peripheral_Interface&#34;&gt;SPI&lt;/a&gt;, &lt;a href=&#34;https://en.wikipedia.org/wiki/I%C2%B2C&#34;&gt;I2C&lt;/a&gt;, Timers… it just goes on)&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;communication buses (some well known ones like &lt;a href=&#34;https://developer.arm.com/documentation/102202/0300/AXI-protocol-overview&#34;&gt;AXI&lt;/a&gt; from the &lt;a href=&#34;https://developer.arm.com/documentation/102202/0300/What-is-AMBA--and-why-use-it-&#34;&gt;AMBA&lt;/a&gt; family)&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;interrupt controllers, clock sources, debug logic—you name it.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://cdn.discordapp.com/attachments/1389279773158805504/1395418456182231201/raw.png?ex=687a6035&amp;amp;is=68790eb5&amp;amp;hm=d690d5bf56f3f4a287d249e1e023c7b1b613984996d6efd4a745d96f282d74f9&amp;amp;&#34; alt=&#34;&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;It’s like shrinking an entire motherboard into a single chip.&lt;br&gt;&#xA;Power-efficient. Compact. Purpose-built. Almost like making a sandwich :P&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;so-is-it-the-same-as-a-cpu-or-an-mcu&#34;&gt;So is it the same as a CPU or an MCU?&lt;/h2&gt;&#xA;&lt;p&gt;This question comes up a lot, and it’s worth clarifying.&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;A &lt;strong&gt;CPU&lt;/strong&gt; is just the brain—the execution core. It can’t do anything meaningful on its own without external memory and I/O.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;An &lt;a href=&#34;https://en.wikipedia.org/wiki/Microcontroller&#34;&gt;&lt;strong&gt;MCU&lt;/strong&gt;&lt;/a&gt; (Microcontroller Unit) &lt;em&gt;is&lt;/em&gt; a type of SoC, but usually simpler and tailored for low-cost embedded tasks (like your microwave or TV remote).&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;An &lt;strong&gt;SoC&lt;/strong&gt; can scale far beyond that as it powers smartphones, SSD controllers, automotive systems, smartwatches… anywhere that needs tight integration and efficiency.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;So no, they’re not the same—but they &lt;em&gt;are&lt;/em&gt; related.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://sdmntprsouthcentralus.oaiusercontent.com/files/00000000-0d4c-61f7-bf8d-638a18a6fc2f/raw?se=2025-07-18T17%3A54%3A26Z&amp;amp;sp=r&amp;amp;sv=2024-08-04&amp;amp;sr=b&amp;amp;scid=cce6b697-1a5b-59e3-8ec9-6f6621b2f6c5&amp;amp;skoid=02b7f7b5-29f8-416a-aeb6-99464748559d&amp;amp;sktid=a48cca56-e6da-484e-a814-9c849652bcb3&amp;amp;skt=2025-07-18T03%3A21%3A15Z&amp;amp;ske=2025-07-19T03%3A21%3A15Z&amp;amp;sks=b&amp;amp;skv=2024-08-04&amp;amp;sig=iqW67AtdHtvebnWmWHNbv52Ji59OSLutgnNTPWosgrk%3D&#34; alt=&#34;&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;socs-in-the-real-world&#34;&gt;SoCs in the Real World&lt;/h2&gt;&#xA;&lt;p&gt;We use SoCs every day, often without realizing it.&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;The &lt;strong&gt;Snapdragon chip&lt;/strong&gt; in your Android phone? SoC.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;The &lt;strong&gt;Apple M1/M2/M3&lt;/strong&gt; in your MacBook? Massive SoC with powerful CPU/GPU/NPU/DRAM controllers.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;The &lt;strong&gt;ESP32&lt;/strong&gt; you play with in hobby electronics? Tiny Wi-Fi capable SoC.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;The &lt;strong&gt;Tesla FSD chip&lt;/strong&gt;? A custom automotive-grade SoC.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Even microcontrollers like the &lt;strong&gt;STM32&lt;/strong&gt; or &lt;strong&gt;RP2040&lt;/strong&gt; are SoCs — just on the smaller, embedded end of the spectrum.&lt;/p&gt;&#xA;&lt;p&gt;That’s the beauty: SoCs scale. From your watch to your laptop to your car’s engine control unit — it’s all the same fundamental idea, adapted to the problem at hand.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;&lt;img src=&#34;https://www.oceanlabz.in/wp-content/uploads/2020/04/7.png&#34; alt=&#34;ESP32 WROOM-32 C Type CP2102 USB Dual Core WiFi + Bluetooth 38 Pins -  OceanLabz&#34;&gt;&#xA;&lt;/figure&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;why-socs-fascinate-me&#34;&gt;Why SoCs Fascinate Me&lt;/h2&gt;&#xA;&lt;p&gt;What drew me in wasn’t just the formal textbook definition of a System-on-Chip. It was the magic of &lt;strong&gt;integration&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;To me, SoC design is the ultimate optimization problem. What used to be a sprawling mess of chips on a PCB is now a carefully crafted rectangle of silicon. There’s something deeply elegant about that. It&#39;s not just engineering—it’s compression, clarity, and control.&lt;/p&gt;&#xA;&lt;p&gt;But more than that, every SoC tells a story — a story about tradeoffs, constraints, and creativity. When you study one closely, you’re looking into the minds of the engineers who made it—what they prioritized, what they left out, and why.&lt;/p&gt;&#xA;&lt;p&gt;Somewhere along the way, that curiosity turned into obsession. And that’s how &lt;strong&gt;Aetheron&lt;/strong&gt; was born.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;whats-next&#34;&gt;What’s Next?&lt;/h2&gt;&#xA;&lt;p&gt;This blog was a gentle introduction to SoCs — their beauty, their complexity, their presence in our everyday lives.&lt;/p&gt;&#xA;&lt;p&gt;But this is just the start.&lt;/p&gt;&#xA;&lt;p&gt;If this sparked even a bit of curiosity, I think you’ll enjoy &lt;strong&gt;Aetheron&lt;/strong&gt;, my homegrown RISC-V SoC, built from scratch. It&#39;s simulated, not silicon — but it boots real C programs, features custom TileLink peripherals, and captures everything I’ve come to love about SoC design.&lt;/p&gt;&#xA;&lt;p&gt;See you there :)&lt;/p&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://prawns.dev/blogs/aetheron/&#34;&gt;→ &lt;em&gt;[Read Aetheron: Bringing My Own SoC to Life →]&lt;/em&gt;&lt;/a&gt;&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>Blogs</title>
      <link>https://anna-docs.netlify.app/blogs/index.html</link>
      <pubDate>Thu, 01 Jan 1970 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/blogs/index.html</guid>
      <description>&lt;p&gt;Listing of blog posts.&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>Guestbook</title>
      <link>https://anna-docs.netlify.app/guestbook/index.html</link>
      <pubDate>Thu, 01 Jan 1970 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/guestbook/index.html</guid>
      <description></description>
    </item>
    <item>
      <title>Pranav</title>
      <link>https://anna-docs.netlify.app/index.html</link>
      <pubDate>Thu, 01 Jan 1970 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/index.html</guid>
      <description>&lt;section class=&#34;home-intro&#34;&gt;&#xA;&lt;h1&gt;Hi, I&#39;m Pranav 👋&lt;/h1&gt;&#xA;&lt;p&gt;&#xA;  I’m an undergraduate electronics student drawn to digital hardware,&#xA;  processor design, and embedded systems.&#xA;&lt;/p&gt;&#xA;&lt;p&gt;&#xA;  I build open-source RISC-V cores, explore verification methodologies,&#xA;  microarchitecture, and performance-driven design.&#xA;&lt;/p&gt;&#xA;&lt;p&gt;&#xA;  Most of my work lives on &lt;a href=&#34;https://github.com/pranav0x0112&#34; target=&#34;_blank&#34;&gt;GitHub&lt;/a&gt;, and this site is where I write about what I learn. Feel free to sign my &lt;a href=&#34;/guestbook/&#34;&gt; guestbook&lt;/a&gt;!&#xA;&lt;/p&gt;&#xA;&lt;div class=&#34;home-contact&#34;&gt;&#xA;  &lt;p&gt;&#xA;    Reach me at &#xA;    &lt;a href=&#34;mailto:pranav.m1205@gmail.com&#34;&gt;pranav.m1205@gmail.com&lt;/a&gt;&#xA;  &lt;/p&gt;&#xA;  &lt;div class=&#34;contact-icons&#34;&gt;&#xA;    &lt;a href=&#34;https://github.com/pranav0x0112&#34; target=&#34;_blank&#34;&gt;&lt;i class=&#34;fab fa-github&#34;&gt;&lt;/i&gt;&lt;/a&gt;&#xA;    &lt;a href=&#34;https://www.linkedin.com/in/prawns/&#34; target=&#34;_blank&#34;&gt;&lt;i class=&#34;fab fa-linkedin&#34;&gt;&lt;/i&gt;&lt;/a&gt;&#xA;    &lt;a href=&#34;https://www.instagram.com/prawns_1205/&#34; target=&#34;_blank&#34;&gt;&lt;i class=&#34;fab fa-instagram&#34;&gt;&lt;/i&gt;&lt;/a&gt;&#xA;  &lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;/section&gt;&#xA;</description>
    </item>
    <item>
      <title>Herald DSP</title>
      <link>https://anna-docs.netlify.app/projects/herald.html</link>
      <pubDate>Thu, 01 Jan 1970 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/projects/herald.html</guid>
      <description>&lt;p&gt;A tiny DSP designed for constrained microcontrollers.&lt;/p&gt;&#xA;</description>
    </item>
    <item>
      <title>Gallery</title>
      <link>https://anna-docs.netlify.app/gallery/index.html</link>
      <pubDate>Thu, 01 Jan 1970 05:30:00 +0530</pubDate>
      <author>anna</author>
      <guid>https://anna-docs.netlify.app/gallery/index.html</guid>
      <description></description>
    </item>
  </channel>
</rss>
