Engineering Designs and Prototype Solutions: Winter Term

In the fall we worked on establishing initial ideas for the housing units for the different MCUs. The MCUs were the deciding factor as they were the largest elements and had major impacts on the battery size. From the initial work it was determined that for the Seeed MCU it would be possible to use the polycase boxes and work the electronics into the predetermined size restrictions or design a custom box, but for the Teensy MCU we knew that we would need to design a custom box in order to accommodate the larger battery that is needed to power the Teensy. This meant that going into the winter term we had a better idea of the general size requirements needed for each box. Early in the winter term it was decided that it would be best to focus on one of the MCUs at a time, we decided to work with the Teensy 4.1 MCU first as we knew it would work for our purposes, where with the Seeed there were still several unknowns.  

  1. Electronic Housing Unit
    1. Specific for the Teensy 4.1 MCU

For the Teensy, as said above, a custom box was required to fit all of the necessary electronic components. The first round of the prototype for the winter term can be seen in Figure 1. This design stayed similar to a design used in the fall, with the insert and the shell.  The insert and shell feature for this housing unit allows for the electronics to easily be access but also provides a sturdy design if the box were to drop. This prototype was used to help map out where the next features of the housing unit would be added. This allowed us to see several different variations of where things could roughly be located without printing out several versions.  

3D printed housing device
Figure 1. Prototype for the Teensy Box. The dimensions are roughly 3.5 x2 x 1 in.

Once there was a rough idea for where everything would be located, we printed a version of the shell that included the screw holes for the PCB, SD card slot and wire slot and a omnetics connector holder, seen in Figure 2. From this prototype it was determined that the ventilation holes should be along the bottom of the box, to help reduce potential risk of water getting on the electronics if someone spilled water on themselves while wearing the device, and that the box needed to be slightly larger to fit the final dimensions of the PCB.  

Back side and top view of the housing box
Figure 2. (left) The back of the insert that has slots for the SD card and wires. (right) Top view of the box that shows the screw holes and wire connector holder. The dimensions are roughly 2.75 X 1.65 X 1 in.

For the next iteration there was more of a complete sense of what the final box could look like, see figure 3 and 4. In figure 4, you can see that we 3D printed a model of what the final PCB could look like, this helped in the design process to begin to visualize a full device.

Technical drawing of the electrical housing unit featuring the Teensy with all dimensions
Figure 3. Drawing of Prototype of the insert for the housing device for Teensy board, dimensioned to fit the final PCB board.
Actual electrical housing unit, overhead and side view
Figure 4. The print from the sketch in figure 3. The dimensions are roughly 2.75 X 1.65 X 1 in.

After this device was created, it was decided to remove the back wall of the shell, just from looking at the insert it was determined that the insert could serve as the back wall alone. Along with this change, prototyping for the battery table began. Figure 5 shows the next prototype.  

Prototype electrical housing units
Figure 5. (Left) Prototype slightly put together with the insert and new shell. (Right) test build of the box using the 3D printed PCB and table. The dimensions are roughly 2.75 X 1.65 X 1 in.

This prototype allowed for us to begin to see what the whole device could look like. It also helped us catch some flaws with the box. The largest of which being that there needed to be more space in the box to allow for the omnetics connector wires to have space to flex, see Figure 6 

Prototype with omnetics connector
Figure 6. Test build of electronics showing the omnetic connector wires

The next prototype has a larger footprint which allows for more space for the wires, and no longer has the holder for the omnetics connector. Upon test building it was noted that it would be far too difficult to remove the connector if needed. Another major change is that one wall of the insert has been removed. This change makes it significantly easier to attach the bioamplifer and mount the PCB into the insert, see figure 7. Another new addition is the holes to allow for the OLED screen to mount into the shell. The main goal with this is to have the buttons on the screen be reachable but not stick out so far that they can easily be accidentally pressed.  

Prototype PCB and omnetics connector inside and OLED screen inside prototype
Figure 7. Test build with the PCB, bioamplifier and omnetics connector (right). Shell with OLED screen. Dimensions are 3.6 x 2 x1.23 in.

This box gave ample space for the wires to flex but did not have enough room for the battery to connect or to access the port which allows for the Teensy to be plugged into a computer. From this we determined we could shift the mounting holes for the PCB over slightly to create enough room for these ports, see figure 8.  

PCB mounted into housing box with Teensy
Figure 8. Shifted mounting holes to give some more space for battery connection and added small wall to help keep wires in place. Dimensions are 3.6 x 2 x1.23 in.

From this prototype, it was determined that more space would be needed to attach the connector cable for the teensy to a computer, and the slot that allows for the screws for the screen to not block the insert sliding would need to be deeper. Some edits were also made to the shell, mainly thickening the boarder on the opened wall to help maintain the structure of the box.  


New box design with "GI Guys" engraved
Figure 9. New box design with different platform for bioamplifier. Dimensions are 3.6 x 2 x1.23 in.

Once this prototype was printed it was noted that the screws from the OLED screen mount would dig into the battery, to avoid this a new design for the shell was made which allowed for the screws to be flush with the rest of the shell, see figure 10 

New prototype with PCB and Teensy mounted and OLED screen displayed
Figure 10. Prototype insert with PCB mounted inside (Left). Shell with raised OLED screen mount (Right). Dimensions are 3.6 x 2 x1.23 in.

This prototype allowed for us to mount the screen and have it not interfere with the rest of the box. With the next print a slight iteration was made to give the screen a touch more space in the raised area.  

From this prototype we determined that even though the screw holes had been shifted over there was still not enough room to attach the cable to the Teensy, which is important in case something were to go wrong with the Teensy and we needed to bug fix. So, a hole was cut out of the side of the box that mirrored the SD card slot, see figure 11. These holes left the electronics at risk for exposure to liquids if they were spilled onto the device, so to minimize this risk plug were also printed out where if we needed access to the slots, we can open them but while the device is in use the box can be sealed up.  

Slots in prototype for connectors and SD card
Figure 11. Image showing slot with plug in for connector cable (left). Image showing SD card slot with plug in (right).
    1. Specific for the Seeed XIAO ESP32S3 MCU

During the term it was decided for time’s sake it would be in the best interest to focus on the Teensy, and get a complete device for that, and then turn to the Seeed. Currently, there are two main paths with housing device for the seeed. The polycase boxes or making a custom circular one that could go with the circular OLED screen. 

  1. User Interface

Since we decided to focus on the Teensy first, we decided to implement the user interface with the Adafruit Featherwing 128 x 32 OLED screen. This specific OLED proved advantageous because of it offers a small profile, contains 3 on-board user buttons, and has been used before in similar projects. The user interface was implemented for the purposes of handling user text input for file naming, and for displaying real time voltage signals to ensure proper functionality at the beginning of studies. To achieve the former, we developed an Arduino IDE script and protocol that allows the user to input a set of eight characters on at a time, as pictured below. 

OLED plugged into a breadboard and displaying "File name:"
Figure 12. File naming screen

Users can toggle through an array that includes all letters and numbers 0-9, as well as the dash and underscore characters, using buttons A and B. The user can confirm their selection with the C button, and similarly confirm the entire file name upon completion. After this, the OLED displays the standby screen until the user presses the A button to beginning the recording and live voltage display. The voltage signal is displayed via a continuously updating cartesian graphing function defined in the IDE script. The inputs of the function can be chosen to control both axis (time and signal value) and their intervals. The display frequency can also be changed by modifying the size of the delay() call to the appropriate amount. An example of the OLED displaying real time accelerometer data using the aforementioned graphing function is shown below.  

OLED graphing a signal
Figure 13. OLED displaying a real time signal
  1. PCB design prototyping
    1. With Teensy 4.1

In the beginning of winter term, we met with Lui Blomberg to gain an overview of how to use Eagle electronic design automation (EDA) software to develop a printed circuit board (PCB). We decided to begin designing a PCB that included the Teensy 4.1 MCU because it was a reliable option and had fewer issues with the software coding. The previous Eagle file from the current colonic monitoring device’s PCB was utilized and edited (see Figure 14) we placed the current device’s Teensy 3.6 MCU with the newer Teensy 4.1. Additionally, we opted for surface mounted capacitors to minimize width of the housing unit. Preliminary routing can be seen in Figure 15. 

Schematic depicting old device's PCB
Figure 14. Previous PCB utilized for inspiration and to use for components
Preliminary schematic for new PCB
Figure 15. Preliminary routing with updated Teensy 4.1 and surface mounted capacitors

The preliminary routing featured the chosen MCU (Teensy 4.1), SMD capacitors, transceiver, and bioamplifier, but was lacking the electrode, OLED, battery, and accelerometer connectors.  

Ultimately, we decided to opt for the full Omnetics Intan headstage (Figure 16), which will plug into a 12-pin adapter that will be surface mounted onto our PCB. Although this takes up more space in the device, it was a more cost-effective choice since there were spare headstages available, and it also allowed for more simplistic routing because the bioamplifier no longer needed to be surface mounted to the PCB. 

Omnetics Intan connector
Figure 16. Omnetics Intan full headstage
Preliminary routing of new PCB which includes Omnetics connector mating piece
Figure 17. Addition of the Omnetics Intan connector, took out bioamplifier

Additionally, some pins on the transceiver were changed to decrease the amount of overlap in routing and simplify routing (Figure 18). 

Transceiver showing all connections
Figure 18. Transceiver before changing pins (left) vs after (right)

Finally, connectors for a battery, OLED screen, and accelerometer were added and routed. The last touches included addition of a ground plane as a path to dissipate surges in electrical energy, addition of mounting drill holes, and drawing the outline of the PCB. 

    1. With XIAO ESP32S3

After ordering the PCB with the Teensy MCU, we began routing the PCB with the XIAO MCU. This time, the PCB was easier to organize and route after having experience with the first PCB. The new difficulties of this PCB centered around the ESP32S3’s limiting feature of only offering one ground, one voltage in, and one 3.3V pin. On the Teensy MCU, routing was often simpler due to having access to multiple options. A preliminary layout of the PCB with XIAO’s routing can be seen in Figure 19. The advantage of this PCB compared to the PCB with the Teensy MCU is its size; the dimensions of the PCB shown in Figure 19 are 45.21mm x 40.89mm, while the PCB with the Teensy has dimensions of about 65mm x 41mm (Figure 21).

Figure 19. PCB featuring XIAO ESP32S3

Final Design:

  1. Electrical Housing Unit
    1. Overview

Our final design is a ABS plastic box that houses electronics that will collect the data required for colonic monitoring. The electronic housing device is 3.6 x 2 x1.23 3.6 x 2 x1.23 in. A drawing of the final product can be seen in Figure 20.

Technical drawing for the new electrical housing unit
Figure 20. Drawing of Final Design. The dimensions are in inches and the scale is 2:1.
    1.  Material
      1. Housing Unit

The housing unit is made of white ABS plastic. Throughout both terms, several materials were considered, including TPU 95, PLA, and ABS. Ultimately the decision to use ABS came from the support that were required to print the design successfully. With so many fine details, the device required dissolvable supports rather than printed supports. Given the 3D printers that were available, this meant that the best option for materials for the housing unit was ABS plastic.  

      1. Table and slot plugs

The table and slot plugs are printed out of PLA. The table could use printed supports and did not need dissolvable supports and the plugs did not require any supports to be printed so PLA made the most sense for the material.  

    1. Details for insert

The insert is where the PCB will be mounted. Its dimensions were specially set based off of the size of the PCB and the required space around the omnetics connector and access to the battery plug.  

The insert has holes that allow for the attachment of the buttons that connect to the chest strap and an additional hole that allows for one to push the PCB off of the mounts if needed. This additional hole was added after it was discovered that the PCB and sometimes get stuck to the screw holes and a gentle push is all that is needed to loosen it.  

A wall of the insert has been removed to allow access to the electronics from the side. This means that those working on the electronics can access the board from both above and the side, this makes working with small parts, like screws or bioamplifier much easier.  

Another wall has a locking mechanism button and slots around the button, these slots allow for the button to press inwards slightly. This action of slightly pressing in is what releases the locking mechanism so the insert can be removed.  

The two smaller side walls have slots in them for the SD card and connector cable. The slots are large enough to allow for easy access to the SD card a lot and access port.  

The back side wall has a half circle with a rectangle cut out where the wires from the omnetics connector will slide into, the other half of the circle is on the shell and when they are closed it makes a rounded slot for the wires to come out of.  

    1. Details for shell

The shell is made to the dimensions where it will fit snuggly around the insert. The edges are rounded to make them softer if they were to press into the user.  

The various features along the sides of the shell align with the features on the insert. Along the top wall there is the hole that aligns with the locking mechanism button,  this hole allows a user to push into the locking mechanisms and release it. Along the bottom wall there are venting holes. These holes will help with airflow in the box and help reduce the temperature in the box. There is also a piece that sticks out along the back side wall that matches with the hole in the insert to create a complete circle to make a wire port.  

There is a raised area on the front of the shell that houses the OLED screen. This raised area allows for the screen and the screws needed to mount the screen will be flush with the bottom of the top of the shell. Because the electronics are tightly packed into the housing unit, it is essential for screws to be out of the way as to not interfere with the sliding feature of the housing unit.  

    1. Mounting features

The housing unit box will be mounted to a Polar chest strap. The housing unit will have the male connectors for the PRYM snaps while the chest strap comes with the female connectors. The decision to use these snaps came after several attempts to use a belt loop, but ultimately the decision was made that while the belt loop was convenient it could press into the user if they were sitting for large periods of time.  

  1. PCB design
    1. Featuring Teensy MCU

The final design of the PCB with the Teensy MCU can be seen in Figure X6. Compared to the previous PCB, the new PCB takes up much less space and features slightly different components. 

Side-by-side comparison of old PCB and new
Figure 21. Final PCB w/ Teensy MCU (left) compared to previous PCB dimensions (right)