RAW/Pi, My Pocket Zero Terminal Tin
Posted: Fri May 25, 2018 11:26 pm
Howdy. I've been puttering around the discord for a few weeks now, but not really done much on the forums. My project is coming along enough by this point that I should probably make a post documenting what I'm doing. Partly to share, and partly to help myself remember what I'm doing!

So I want a pocket linux terminal with a real keyboard. This all started when Ben Heck made a BASIC computer with an xbox 360 chatpad. Realizing that the chatpad can be used as an input device for things other than calling people in call of duty gay kinda blew my mind. I did some googling for "raspberry pi pocket" and discovered the MintyPi and Sudomod in general.
I thought a mint tin would be perfect, as previously I was thinking of making the case out of MDF or engraving plastic, which would be far too thick. However, the Xbox 360 Chatpad (hereby known simply as "chatpad") is far too large for an Altoids tin. So I went to the dollar store to see if there were any somewhat larger tins lying around. All I found were some disgusting cinnamon mints in a box the same size as Altoids. I tried Target, maybe there'd be some gamer merch tins or something like that. Nothing there.
Finally I went to Amazon, searched for "mint tin" and "metal tin" and bought some tins that are waaaaay too large and didn't have a hinge, despite being advertised as hinged. I also went to an antiques store, and found this near perfect vintage first aid tin, but it was just a bit too small on the sides, and the chatpad keyboard pushed it out slightly.

Finally I went to ebay and also searched for "metal tin" and "mint tin" and came across these RAW rolling tobacco tins. 4.5"x2.5"x1". Perfect size!

Hooray for size! Not hooray for styling. Can't stand this tin, really. I think I'm gonna take some acetone to the paint and relabel it as RAW/Pi.
So next up was to get the keyboard working. The chatpad has a little PIC microcontroller and communicates over serial. There is an existing driver for raspberry pi from newsdownload, but after piddling with it for 3 hours and having zero signs of success, I gave up and instead tried my Arduino Micro clone. That doesn't have enough serial ports, so I tried this library which comes with an example for Arduino Leonardo, which I used with an Aideepen BadUSB Beetle, which is in essence an entire Arduino Leonardo on a PCB barely bigger than the ATMega CPU. This worked perfectly first time!
Now that I knew what I needed, I could design a bracket in Illustrator to hold everything in place, which ended up being this:
After that I exported the actual frame pieces individually as SVGs, then imported them into Tinkercad.
So the USB ports go in the big beefy brackets in the middle, the hub in the bracket on the right, the Leonardo in the bracket on the left, and the power circuit on top of it. Finally the Pi goes in upside down on the fat screw posts, the battery sits in the cutout in the top, and the xbox chatpad screws into the smaller posts on the outside.
A lovely Sudomod member (who goes by @chedda on discord) is printing this design for me tonight. Once it arrives I can see how it all comes together.
Things I've noticed I did wrong,
I just realized I have no way to disassemble my device once the baseplate is stuck down. The screws for the chatpad go in from the bottom, and if the baseplate is stuck to the bottom of the tin, there's no way at all to get the chatpad screws out, which means the rest of the assembly can't really be disassembled. I'm going to have to change this for V2, somehow. Not sure how, though. Perhaps making the screw posts for the chatpad also screw in from above, somehow.
Other things I haven't mentioned yet: I'm using a 3.5" or 4.0" screen. I've got a generic Arduino 3.5" 320x480 screen coming tomorrow from Amazon, and I'll see if I can get it up and running, and what kind of interface it even has, SPI or parallel. In either case, it'll be coming up on a simple 28AWG ribbon from the Pi's GPIO.
I think I'll squeeze a USB DAC in somewhere, as I have a free port on the USB hub that isn't being used. This is mainly a terminal and probably won't ever boot into a window manager, but it'd be nice to have sound if I feel like it.
That's all, folks! Stay tuned for the next part.

So I want a pocket linux terminal with a real keyboard. This all started when Ben Heck made a BASIC computer with an xbox 360 chatpad. Realizing that the chatpad can be used as an input device for things other than calling people in call of duty gay kinda blew my mind. I did some googling for "raspberry pi pocket" and discovered the MintyPi and Sudomod in general.
I thought a mint tin would be perfect, as previously I was thinking of making the case out of MDF or engraving plastic, which would be far too thick. However, the Xbox 360 Chatpad (hereby known simply as "chatpad") is far too large for an Altoids tin. So I went to the dollar store to see if there were any somewhat larger tins lying around. All I found were some disgusting cinnamon mints in a box the same size as Altoids. I tried Target, maybe there'd be some gamer merch tins or something like that. Nothing there.
Finally I went to Amazon, searched for "mint tin" and "metal tin" and bought some tins that are waaaaay too large and didn't have a hinge, despite being advertised as hinged. I also went to an antiques store, and found this near perfect vintage first aid tin, but it was just a bit too small on the sides, and the chatpad keyboard pushed it out slightly.
SpoilerShow


SpoilerShow


So next up was to get the keyboard working. The chatpad has a little PIC microcontroller and communicates over serial. There is an existing driver for raspberry pi from newsdownload, but after piddling with it for 3 hours and having zero signs of success, I gave up and instead tried my Arduino Micro clone. That doesn't have enough serial ports, so I tried this library which comes with an example for Arduino Leonardo, which I used with an Aideepen BadUSB Beetle, which is in essence an entire Arduino Leonardo on a PCB barely bigger than the ATMega CPU. This worked perfectly first time!
SpoilerShow
SpoilerShow

SpoilerShow

A lovely Sudomod member (who goes by @chedda on discord) is printing this design for me tonight. Once it arrives I can see how it all comes together.
SpoilerShow

I just realized I have no way to disassemble my device once the baseplate is stuck down. The screws for the chatpad go in from the bottom, and if the baseplate is stuck to the bottom of the tin, there's no way at all to get the chatpad screws out, which means the rest of the assembly can't really be disassembled. I'm going to have to change this for V2, somehow. Not sure how, though. Perhaps making the screw posts for the chatpad also screw in from above, somehow.
Other things I haven't mentioned yet: I'm using a 3.5" or 4.0" screen. I've got a generic Arduino 3.5" 320x480 screen coming tomorrow from Amazon, and I'll see if I can get it up and running, and what kind of interface it even has, SPI or parallel. In either case, it'll be coming up on a simple 28AWG ribbon from the Pi's GPIO.
I think I'll squeeze a USB DAC in somewhere, as I have a free port on the USB hub that isn't being used. This is mainly a terminal and probably won't ever boot into a window manager, but it'd be nice to have sound if I feel like it.
That's all, folks! Stay tuned for the next part.