Well this Sucks.

A project log for SmoothMove - A New Human Computer Interface

Small, Ergonomic, Portable and better than any other travel mouse

ChrisChris 08/26/2018 at 20:230 Comments

Pretty much sums up my experince since the last log. 

The good news is that I actually got a breakout board for the FPC/FFC connector! The bad news is that is pretty much the only good news. 

A (un)Beautiful Breakout Board
I ordered the 50 pin Adafruit breakout board from Amazon. With the HaD Prize deadline for Human Computer Interfaces mere days away, I had to limit myself only to what was available on Prime. So that is pretty much all I could find. There were many other suitable breakout board designs, i.e. only 12 pins and more breadboard friendly, but all of them would have taken weeks to get here. So I had to make do with what I could get. 

I received the breakout board a few days later and soldered the connector so I could  begin actually hooking up the trackpad for the first time. After working out the best way to mush everything onto a tiny breadboard, I tried to upload a standard "Hello, World!" program from the ESP-IDF, just to make sure that nothing was shorting or would be making smoke. I wanted to take baby steps with this project because I knew that something was going to go wrong. 

Sure enough, something went wrong. My first issue was that the pins that I needed to use for the trackpad connections aligned perfectly with the UART pins that had been broken out on the ESP32 dev board that I am using. Originally my plan was just to disconnect the trackpad when I was going to upload code, but then of course I wouldn't be able to log anything to the terminal for debugging purposes..... In the end I determined that it would be easiest to just jump the 2 pins interfering with the UART pins to another location on the breakout board. 

Besides the UART pins, I also needed to jump the GND pin as well as a few more GPIOs because of course out of all the GPIO pins that I needed to use, pins 34-39 on the ESP32 are input only. Long story short, here is what my breakout board looks like as of now. All bodged and jumped.

So you should be good to program, right?

I thought so too! I was very eager to try out the code that I wrote, and just as I suspected, I did have some issues.  I was getting various I2C errors and what not but I actually managed to figure them all out. Not too bad for my first time working with I2C with this lower level of abstraction. While I wasn't getting any errors, I couldn't actually figure out how to get any data out of the sensor. Like I said, I am still new to this stuff. 

The time was ticking to get this thing working though, so I broke down and tried to get the arduino code working.  In therory that was already working code that just needed the write connections to make the trackpad chooch. However I encountered another issue. I needed to add the ESP32 to the arduino IDE. That would have been pretty trivial, if I was on my normal x86 laptop. Unfortunately, the USB controller on my laptop fried itself so I have been using my Raspberry Pi as a temporary desktop to do my programming. To add insult to injury I then needed to figure out how to build the xtensa-esp32 toolchain for ARM, and then figure out how to make the arduino IDE look for that special build instead of letting itself try to automagically set itself up. What a joy.

But you got it figured out, right?

I did finally manage to get the code from the arduino IDE to compile (very slowly) and upload to my dev board. I double checked all my connections and made sure that everything was inorder. I checked out put from the serial port to see if I was receiving and data that made sense, and sure enough, I was not! 

Supposedly, when the trackpad has data that should be read it will pull the "DR_PIN" high. By monitoring this pin, you can determine whether or not there is data that needs to be handled. For some reason this pin was not doing anything. I tried all sorts of pull up and pull downs and nothing was working. 

After checking the datasheet, the operating voltage of the track pad is 2.5v - 3.6v. I thought that powering the trackpad off of the regulator on the esp32 dev board would be sufficient, unfortunately not. The voltage across the trackpad was hovering around 2 volts. 

I didn't have any linear regulators on hand so I figured that by powering the trackpad off of a half dead lipo would be sufficient. I accidently picked a fully charged one instead. Whoops.  I did not realize this until I checked the voltage across the trackpad and it said 4.1 voltsI am really really hoping that I didn't fry the board, but in all honesty the behavior of the sensor remained exactly the same before and after this little mishap. 

For now I am powering the trackpad off of another junk dev board that still has the 3.3v regulator funcitonion. It's not pretty, but in therory it should still work. 

Yet, no results. Nothing. Nada. No change.

I am honestly stumped. I have no idea why I am getting no results. Even after hooking up my tiny oscilloscope and monitoring the SCL and SDA lines I see nothing. There was a  single instance when I maybe saw a clock tick, but that was only once. 

So with that, what next?

I think that it might actually be worth forking over the money for the premade dev kit. That way at least I can experiment and build off of that. I have no idea if there is one key element that I am missing or if it many tiny issues that are causing my woes. I suppose that I should probably buy a new trackpad, just in case I fired the one one that I already have. Either way I really want this project to come to fruition. I know that it would personally be very helpful to me and would love to be able to provide these devices to others. 

I was hoping that by the time the HCI section of the HaD prize ended I would have an actual working prototype, but alas. All that I can hope for is that people see the potential for how cool this thing could be. I fully intend to keep throwing time and money at this thing until I can make it work. 

Please please please please, if you have any suggestions as to what may be the issue with my setup let me know. At this point any sort of progress would be welcomed.