Hardware requirements

Just as we discussed in the previous chapters, we want to think through the hardware requirements that are necessary to support our test harness. We want requirements that will be general enough so that we don't tie our hands in the design process but also enough so that we have breadcrumbs that lead us in the right direction. For our test harness, which will test our pushbutton project modules from Chapter 3, Writing a MicroPython Driver for an I/O Expander, before we develop our hardware requirements, we need to review the hardware that we designed, which can be seen here:

From reviewing our hardware diagram, we can see that there are several hardware requirements that we want to define, as follows:

  • The test harness shall be capable of recording the output signals on X1, X2, and X3 for manual review and verification.
  • The test harness shall monitor I2C communication on X9 and X10.
  • The test harness shall replace the CH0 pushbutton's input with an I/O line that can be controlled by the test harness.

As you can see from these requirements, we are specifying a few high-level needs for our test harness so that it can interface with our device. We could go much further by removing the RobotDyn I/O expander and using something like an Aardvark to directly interface on the I2C bus and then simulate the RobotDyn chip. This would allow us to then simulate various fault conditions and see how our system responds to those faults. These could include faults such as the following:

  • A non-responsive slave device
  • An invalid response
  • I2C bus errors

We can make our test harness as sophisticated or as simple as we want based on our application needs. For us, just making sure that we can communicate with a device and read the input values correctly is about as much as we need for this project.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.238.20