Status Report #8

Ethan:

This week I continued work on the wireless system, however our focus pivoted to the high level systems required to make the headphones work. I discussed this with my teammates at length to make sure we were all on the same page and could code together. 

Unfortunately, my responsibilities during the carnival season, as well as my 349 lab partner dropping has had a decidedly adverse effect on the amount of work I got done last week. I am behind on wireless optimizations, and my current tests still put me at a maximum of 600,000 bytes per second. While that number meets (and exceeds) the bandwidth requirements of our project, it is not fast enough for the latency requirements. We have have an effective bandwidth an order of magnitude higher than the bandwidth required for a single stream because as we make more hops, our maximum ELS (effective link speed) goes down. 

Given the pending date for demos, I plan this week to pivot my focus to making sure the Audio playback is smooth and (hopefully) integrating the software with the physical hardware that should arrive sometime this week. 

Michaela:

Though I was fairly ambition in my plans for this week in my last status report, there were a few unexpected occurrences that deterred me from accomplishing all that I wanted to do.  We have decided as a group that rather than printing the headphones now, we will wait until all the components are assembled and testing is done, as this might effect our budget and thus lower the allocated printing budget. After discussing the higher level software more with Ethan, we have come up with a system that will run on top of the scheduler of the ESP32 in order to properly pass along resources to our necessary operations and run them as efficiently as possible.  For this reason, I reworked the FSM and UI code a bit and started working on creating the necessary aspects of this system, such as the tags that will be assigned to each scheduled task. Other than that, due to issues arising involving Buggy filming and overestimating my energy level after these days of work, I was unable to complete much else. With this winding down and the final in lab demo approaching, I am hoping to have this code and test cases prepared by the end of next week.

Winston:

This week, per Prof. Tamal’s request, I updated the layouts of PCBs with stricter design rules, bumping minimum clearances from 3.5mil to 5mil, minimum trace width from 3.5mil to 6mil, and minimum distance between drill and copper from 0.2mm to 0.25mm. More than 2000 traces have to be moved manually; these more stringent design rules are largest satisfied, with few exceptions, and thus minimize the critical area in these boards.

The endeavour to implement firmware continues. The push in schedule is compensated by pulling more time out of Carnival to work on this project.

Team:

As a team, we are currently trying to prepare for the inevitable debugging that will need to take place when we integrate our components. Overall, we are trying to build test cases and scenarios, such that we can mitigate the issues that will arise once this occurs.

Moreover, as a team, we set ourselves a soft deadline for the completion of the software system to be the time that hardware is shipped and assembled, which is expected to be Apr 21.

Status Report #7

Ethan:

This week, I made a major push to finish up the network routing code that had been demoed at the interim demo on Monday. I initially implemented a layer 2 packet switching system, but unfortunately as my implementation was nearing completion I discovered that layer 2 switching was not possible with the current revision of the ESP32 wifi chip we were using. I spent Friday rewriting the network stack to route packets on the layer 3 level instead of the layer 2 level. The other big thing I worked on was network throughout optimization. Because of the tight timing requirement involving networking packets the networking code had to be profiled, and benchmarked, The current networking code takes approx. 500 micro seconds to process a packet with max MTU (1024 bytes), which is not fast enough.

The current networking stack is slightly behind schedule, but since we are readjusting scope to a static mesh configuration right now all that needs to be done is it needs it’s performance to be tuned. This week, I hope to finish those optimizations and rewrite the audio driver we used during there demo. However between 349, secure coding and my spring carnival responsibilities I am not convinced I will be able to direct the same energy into capstone I did last week. There are a lot of important projects currently vying for my attention. 

Michaela:

Along with working on my reading assignment this week. I added the last final touches to the headphone can 3D model by adding Winston’s boards. We are looking to have a print done by the end of next week. Additionally, I have begun writing the comprehensive list of all the tasks/modules we will be utilizing for our high level software. This includes the inputs and outputs, runtimes, related tasks, and general functionality. With that, I also created the files for our basic fsm and related UI which will be controlled by many of these modules. Next week, I hope to finish this list and begin writing the rest of the modules. Given that next week is Buggy and I am one of the individuals in charge of the filming crew, I expect that the week will be fairly busy, but I am optimistic that I can still accomplish all of my goals.

Winston:

The PCB, the corresponding SMD stencil, and electronic components have been ordered. There are 90 different parts that need to be ordered and will be 344 discreet components to be soldered onto the 4 pieces of PCBs.

Here are the finalized CAD and CAM files:

Left Main Left Side Right Main Right Side Panelized
Schematics Download Download Download Download
Layout Download Download Download Download (Original)

Download (Rasterized)*

Download
3D Model Download Download Download Download
Gerber Files Download Download Download Download (Original)

Download (Rasterized)*

Download

* The hatch pour in rasterized version is replaced by ~800 segments of wires of assorted lengths. As such, the rasterized version allows for edits like rotation, but is much slower to load.

Other than panelizing the PCBs and preparing the BOM for production, I also shifted gears and started the work on software. In particular, I started to work on the firmware for MGC3130, our gesture sensor.

I will continue to focus on the firmware in the coming week or two, until the ordered parts arrive.

Team:

As a team we further discussed what we would need to eliminate from our project in order to narrow the scope. These are the items we identified in order to do that:

1. Statically configure the mesh
2. Eliminate feedback topology in active noise cancellation (set initial filters for all of runtime)
3. Use breakout boards instead of PCB (our budget allows for both)

Additionally, we worked together to reach a consensus on how our high level software will look. Specifically, we discussed the role of the scheduler and the various tasks that will be run on it. We also discussed generally what modules we would be creating to be run as these tasks and how we plan on relating it to the other aspects of the project, such as the hardware and the networking.

Status Report #6

Ethan:

This week, my main focus was preparing for the demo. In order to do that, I had to do a lot of work to finish the v0.1 of the networking stack. For the networking stack, this week I implemented routing link tables as well as converting the existing IPv6 code to use no dynamically allocated buffers. This also involved rewriting several previously buffer heavy implementations of networking functions with zero copy replacements. In some areas of the code, dynamic message sizes forced a worst case stack allocation to avoid a buffer overflow. As as result, while incoming packets are only bounded by the static Wi-Fi buffer, outgoing packets are artificially bound to a maximum MTU of 1200. This will probably change going forward, but more improvements are needed to the network stack first.

The network stack is also unstable, and crashes if it gets too many packets.

In addition, my other main focus was bringing the software to a point where it was able to be demoed. This required first working on the networking stack, and bringing to a point where it can talk with other IPv6 complaint devices in a minimal direct link. Full packet routing is still being implemented, and is not yet ready. For the demo, I worked on researching how linear PCM packets are processed, as well as working on a demo that used the IPv6 stack to forward audio from a target computer to the headset. Our next goal is to implement routing, so that the headsets can relay audio to each other.

We also need to continue to improve our audio playback protocols and buffer systems. Currently the audio playback is choppy, because even small variations in packet delivery time can cause the DAC hardware to miss it’s deadline. This is very noticeable for even small interruptions. In order to address this, we are working to develop a packet buffering and synchronization scheme to make the headphones more tolerant to jitter in packet arrival times.

I ended this week by completing the first audio demo, and testing it tonight. As mentioned earlier, it does not sound very good, and more refinement is needed for demo day.

Michaela:

This week I actually went back to the enclosure design to edit the formation of the cans to better fit the new form of the PCBs. I also began implementing the RLS algorithm in Python with receiving PCM packets and removing generated noise. I struggled more than expected with the implementation, so I went back to the original algorithm and went over it in writing. This allowed me to be more clear on what I need to accomplish. My goal is to still complete this before the demo period on Monday, as well as add the models from Winston once they are all complete.

***

***

***

***

***

Winston:

This week, I focused on working on the layout of the boards, making sure that they:

  1. respect the dimensions set forth by Michaela along with reasonable placement of M4 screw holes,
  2. all PCB designs combined fit within a 100mm x 100mm square, for lower manuefacturing costs, and
  3. FPC, USB-C, and JST-PH connectors are arranged in a physically realizable manner, accounting for headroom for jumpers.

In terms of design decisions, I fused the previously top and bottom PCBs into one main PCB, which eliminated the need of FPC connectors and reduced the number of screw holes required. However, the trade-off in this decision is that the PCBs would take up more real estate. Fortunately, the four boards (namely main and side, left and right) still satisfy the second aforementioned constraint.

This is an artistic rendering of the left, main PCB, showcasing the USB Type-C receptacle, surface-mount speaker driver, and ESP32-WROOM module.
This is a realistic rendering of the left, side PCB, showcasing the tiny MEMS microphone. The red area designates the need for headroom, as wires will be soldered directly to those pads.
This is the 3D model of the right, side PCB, featuring the cross-hatched electrode for in-air gesture sensing.

I also generated 3D models of the PCBs, utilizing the 3D models built previously.

I started designing the augmentation that needs to be made to the FreeRTOS event scheduler, which would constitute to our software architecture. I wanted to focus on implementing some of the firmware, but the team has agreed on the importance of our architecture and thus the switch in work priority.

I will focus on implementing the aforementioned architecture next week.

Team:

In terms of team work, we had a meeting with Professor Tamal to discuss our current schedule. Since we are behind progress, especially in terms of our PCB, we have come up with a Plan B in case it does not work or does not arrive in a reasonable time.

Below we have listed the outline for this plan, the ways it is different from our previous implementation, and the block diagram for this proposed plan.

Status Report #3

Ethan:

This week I focused on the design document. My team and I met after the presentation, and discussed the feedback we got as wall as what changes in direction we wanted to make to our design documents. We realized that our presentation wasn’t good because while it did an excellent job of explaining each individual part, it made little mention of the overarching goals of the project as a whole. A large part of this week was spent figuring out how to reorganize and present our project in a meaningful way. I wrote the draft for the mesh portion of the design document, which will be finalized tomorrow.

Michaela:

This week I worked on material for the design document. Mainly this has been taking the information from our presentation, along with the notes we received afterwards, to provide a complete overview of the design of our project from high to low-level. One of the major things we worked on together is discussing how to best layout the design holistically, rather than individual pieces. This included creating an explicit chart of relative areas/aspects of the headphones, features, metrics, and verification we wanted to hit for the project as a whole, rather than individual pieces. This way, we can explicitly state why we are doing and including certain things in our overall design. Another thing I worked to do is to create a list of buzzwords we used during the presentation, so that we could be sure to properly define them in when discussing them in the design document.

Finally, I worked on writing the actual design document.

Winston:

I focused on the design review presentation last Sunday; since then, I started to work with my teammates on the corresponding report, trying to re-organize the information at hand per the feedback with regard to our presentation. In particular, I was in charge of drafting the outline of the report according to the consensus from our discussion, since both Ethan and Michaela are quite preoccupied by the production of Lunar Gala.

In terms of hardware design, I started the layout of the schematics and the corresponding enclosure design. I found out that one side of the headphones is about 60mm thick (including cushion, audio driver, acoustic foam, electronics, and thickness of enclosure). The dimension is shown diagrammatically as follows:

Therefore, as a team, we decided to move the inductive charging receiver coil (which is reduced in size in the diagram above for clarity – it is actually 36mm in diameter). Specifically, it would be moved to the center of the headband. As a result, I cannot maintain the symmetry between the two sides of the headphones and thus have to put different components into each side.

We will further discuss how to reorganize our schedule to accommodate this unexpected change in hardware design.

Team:

We decided to organize the design report by features and high-level needs and wants, instead of by hardware, firmware, software, or algorithm areas. In particular, the breakdown is as follows:

High-Level Requirement Features Competing Metrics
Good Sound Quality Low-noise circuitry
  • Circuit complexity
  • Component area
  • Performance
  • Power consumption
Active noise cancellation
  • Algorithm run time
  • Performance
  • Circuit complexity
Passive noise isolation
  • Volume
  • Performance
Audio Sharing Effectiveness and robustness
  • Latency
  • Recovery from non-root failure
  • Effective link speed
Ease to set up
  • User test
Usability Long battery life
  • Playback time
  • Multi-playback time
  • Standby time
Intuitive UI (gesture control)
  • User test
Fast USB charging
  • Thermal performance
  • Component area
  • Performance
Wireless charging
  • Coil area
  • Performance
Basic Functionality Bluetooth audio
  • Performance
  • Power consumption
Physical enclosure
  • Size
  • Comfort

One prominent risk is the major revamp needed in hardware design due to the relocation of charger coil and thus the basic design principle of symmetry between the two sides of our headphones. We will resolve this by tomorrow.