3 Steps to Reading New Code

Man writing some code

Approaching Code For The First Time

Whether you are approaching a code base for the first time or you are doing a code review for another developer, reading code may be like reading another “language”. In school, you get extensive instruction on how to write code, but rarely hear about how to approach a large code base for the first time. And then you enter the “real world” and learn that reading code is as essential a skill as writing.

A lot of our new engineers see codebases that are significantly larger than what they were presented with during their undergraduate work. This can certainly be overwhelming. Organizing it all in your head is often impossible in active codebases. We share three tips with our new engineers to make new code less intimidating.

Step 1: Look for the Documentation

When you are looking at a new codebase, the first place to look is a README file. This text file is typically located in the root folder of the codebase. There are a few things that this document should include to make the process easier for the reviewer:

  • What tools you need installed to compile this code
  • How you can run the code or the context it is used in
  • What the code is doing
  • What different blocks are doing

Step 2: Look for Entry Points

Next, you will want to identify your entry points and programs that will be most beneficial to your review. We suggest you open up your code, in an IDE or another editor that understands the declarations, can do syntax highlighting, and can do code folding, so you can squeeze the code down into just the headers and stay high level. If you’re in C, the entry point is usually going to be your main() function in a main.c file. If you’re using the Arduino framework, the setup() and loop() functions in the INO file are the entry points. Python will have the package name and the entry point will often be in a file with the same name. You will find either a main function or code will start executing from the top of the file. If you’re in C sharp, you’ll find a Main() or OnStartup() function in either an Application.cs or Program.cs file.

If you’re in C++ or C, start in your header files, just see what things are being called and avoid getting mired down in details of how exactly each function is implemented.

Step 3: Take a 10,000 foot view

Once you have found the entry point, identified the main function and/or the top files, now you can see where the code is going. Taking notes in the form of a sketch or diagram block helps this process, and can also help to identify how things relate to each other visually.

When you are looking at code for the first time because you’re going to start developing with others, taking a look through the recent history and active branches in the repo can help you understand the code as well. This will give you insight on where active work is happening, what others are watching for, what is changing. Looking through this history may even provide you hints on what parts of the code are most important.

What To Ignore As Long As You Can

While reviewing code, there may be a temptation to fix all the things you see. Perhaps because they are not the way you would do them or you could recommend a better way. This is where we encourage you to pause. Here are a few things you can ignore.

In short, anything that can be caught or fixed by automated processes are better reviewed by those processes. If you don’t have these in place, we have some articles discussing the how and why of automation, too!

Reading code is as important as knowing how to write it. While this is not a skill that is taught, it can absolutely be valuable to your team and clients. And if you have questions about an embedded project you’re working on, consider reaching out! At DojoFive, we have talented engineers on hand ready to help you with all aspects of your EmbedOps journey. We are always happy to help with interesting problems that need solving. You can reach out at any time on LinkedIn or through email!

Discover why Dojo Five EmbedOps is the embedded enterprise choice for build tool and test management.

Sign up to receive a free account to the EmbedOps platform and start building with confidence..

  • Connect a repo
  • Use Dev Containers with your Continuous Integration (CI) provider
  • Analyze memory usage
  • Integrate and visualize static analysis results
  • Perform Hardware-in-the-Loop (HIL) tests
  • Install the Command Line Interface for a developer-friendly experience

Subscribe to our Monthly Newsletter

Subscribe to our monthly newsletter for development insights delivered straight to your inbox.

Interested in learning more?

Best-in-class embedded firmware content, resources and best practices

Old maps piled on top of each other

Artifacts – They’re useful for firmware too!

Artifacts. What should you save, and what should you leave? As I am currently working with Gitlab, I’ll be talking a bit about how Gitlab uses them, but it can still apply to other repository platforms! What are artifacts? Artifacts are files or directories that are a result of one of your CI/CD pipeline stages. They can be in the form of output files, configuration files, reports, or any other resource you may want to get out of the process.

Read More »
A Guide to Assessing Security Risk in Embedded & IoT Devices

A Guide to Assessing Security Risk in Embedded & IoT Devices

In 2025, a stack-based buffer overflow vulnerability (CVE-2025-24132) was found in the Apple AirPlay SDK. For third-party smart speakers and receivers, this vulnerability allowed proof-of-concept zero-click remote code execution (RCE) that made it possible for attackers to overwrite memory and execute malicious code on many devices. An unpatched code injection vulnerability in AVTECH IP cameras (CVE‑2024‑7029) enabled a Mirai botnet variant in 2024.  In both cases, vulnerabilities gave attackers access to important security infrastructure. This illustrates the need for ongoing

Read More »

The CLI’s Essential ‘Verbose’ Option

For those creating their own CLI tool If you have played around with any command line interface tools, such as Particle CLI or Git UI, you’ll notice that they oftentimes will have a verbose or -v option with their commands. This allows you to change log levels within the program, outputting as little or as much as you desire. This example CLI tool makes use of the Click library for Python. If you are having trouble getting started, check out

Read More »