In this section, we will build our setupapi_parser.py to parse the setupapi.dev.log file on Windows 7. Equipped with only modules from the standard library, we will open and read a setupapi.log file, identify and parse relevant USB information, and display it to the user in the console. As mentioned in the introduction, we will use an iterative build process to mimic a natural development cycle. Each iteration will build upon the previous while we explore new features and methods. We encourage the development of additional iterations, and there are challenges at the end of this chapter to compliment this.
Introducing our script
Overview
Before developing any code, let's identify the requirements and features our script...