During 2023, I did VCE Systems Engineering, In this class, we got the opportunity to work on a project of our choosing. I had an old raspberry pi 3 lying around and I wanted to use it to build a cyberdeck.
Some constraints/requirements were that
The steps taken to complete this project were as follows
Before staring to build anything, I wanted to conduct some researsh of my own to explore some possible designs, I also decided to research some screens to evaluate my options.
This cyberdeck is built inside a Nintendo Gameboy carry case. Is has a 60 percent mechanical keyboard, a built-in mouse and it has 4 usb ports.
The small and compact form factor allows it to be carried around easily as it doesn’t take up much room.
It has built-in speakers and it features an upside down dissambled mouse that you could control by sliding your thumb over it.
This cyberdeck uses a raspberry pi 3 inside a pelican case. It has an array of I/O ports and switches for networking activities. The bulk of the cyberdeck is in the screen, this means that it needs a large stable surface to be operational.
This is a cyberdeck that is used as a lighting controller, the large form factor allows for many peripherals to be included. It can fit multiple keyboards along with dials and switches, and It can even fit a large mousepad and mouse.
https://www.reddit.com/r/cyberDeck/comments/u6mxjy/portable_dmx_lighting_controller/
These small cyberdecks are perfect for a wrist mounted form factor. I really like the exposed cables, circuit boards, screws and led lights, It reminds me of the cyberpunk aestetic.
It could also work as a wrist mounted display that doubles as a controller similar to a pipboy from fallout.
https://www.reddit.com/r/cyberDeck/comments/1081t3x/purple_green_orange_blue_oh_what_colors_for_a/
This screen has a resolution of 1024x600 and is 10.1 inches corner to corner so it will fit within the size constraint. It has a 5v micro-usb port for power and a mini-HDMI port for signal, and it costs around $050
This 3.5-inch display is a display that sits on top of the raspberry pi and connects to it via the GPIO pins and its resolution is 480x320px. It costs around $027.50
This is a widescreen 12.6-inch 1920X515 LCD Screen. The benefit of a wide screen is that two windows can be placed side by side for productivity.
It costs $0170 after tax and shipping.
https://www.amazon.com/gp/product/B08FJ33247/ref=ewc_pr_img_1?smid=A1D3XK588INFI6&psc=1
This design allows for 3 power banks to be included inside to allow for a longer period of use. The design is similar to a traditional laptop as the screen is separate from the base where everything else is held.
The three power banks plug into each other and charge each other so the one that is directly plugged into the raspberry pi will remain above zero percent until all of the power banks run out of charge.
This design is more compact because it only uses one powerbank. Everything is stacked on top of each other to reduce its footprint, this will help it fit in tighter spaces. Due to this, the screen needs to be thin and wide so it can fold down. The non traditional form factor makes it standout against other laptops.
This final design is modeled after design 1. There is an acrylic mid layer that holds the keyboard and Arduino controller on top of it. The acrylic midlayer sits on a ledge. Underneath the midlayer, there are two powerbanks and the raspberry pi.
The lid holds the lcd screen and the display driver board behind it. The screen will be held in place by glue and it will have clips to match the aestetic of the case.
All of the ports can be accessed from the back and the side. When the cables are connected, it will have the steampunk look of exposed pipes (except with usb cables).
Design 1 was chosen as it allows room for multiple powerbanks, this will give it a larger battery life.
Another benefit of design 1 is that it leaves plenty of room to change and add things if required, this is not present in design 2.
I created a physical model to allow for placing and moving components to see how they fit and to get an idea of what it feels like to use.
I arranged the components as per the first design.
I moved the keyboard closer to the screen as it felt awkward to use in its old position.
Due to this, I had to relocate the raspberry pi, The raspberry pi had to be in the base as the lid needed to be as light as possible, so it didn’t tip. The raspberry pi also needed to be in the corner to allow access to all the ports while being close to the screen, this would eliminate any loose cables that could get caught.
I found a parametric box that I liked, and I downloaded it. As it is carametric, it allows for the dimensions of the box to be easily changed. I changed The inner depth and width to 170mm and 250mm respectively. I changed the bottom height to 25mm initially and the lid height to 20mm for a start. I picked these measurements due to the size of the keyboard and the lcd screen, I chose a rough estimate was for the inner heights of the boxes as they could be changed later.
I foude a free model of a raspberry pi that I liked and I downloaded it. It came with a case that could be easily toggled off, I removed it as it was not needed. The 3D model of the raspberry pi only had one USB port in the middle instead of 2, the dual USB port on the right was deleted and duplicated and put where the single one was.
Later I found out that this model was inaccurate and I had to modify the 3d printed case, but I did not know this at the time.
I imported the raspberry pi model into the main project and positioned it in place. I places some blocks in the shape of the ports to allow a cutout to be extruded into the side of the box.
I created a sketch at an angle to extrude the holes with a chamfer in a direction to allow me to slide the raspberry pi into place.
Once again, as this model was inaccurate, none of this mattered in the end, although I can still use this technique in other projects.
I created a 3D model of the screen and its controller board according to caliper measurements of the physical device.
I modified the lid piece to hold the screen about a centimetre away from the bottom of the lid, this allows space for the controller board to sit behind it, and leaves room for the ribbon cable to sit comfortably without it folding and creasing, this would sever the commection and make it unusable.
I extruded holes in the side of the lid to allow the cables to be connected.
I also desiggned clips to hold the screen in place.
I created a model of a powerbank that I had lying around, I imported into the model but it was taller than the raspberry pi ports. I would have had to make the case taller to accomodate.
I found a smaller powerbank online, I modelled it and imported it into the cyberdeck. I extruded holes for the ports and I created rails to hold it in place.
I designed a ledge for the acrylic midlayer to sit on. I integrated it as close as possible to the raspberry pi, this reduced its vertical height.
I also modeled the layer of acrilic.
I created a model of the vortex core 40 keyboard so it could be imported it into the model. It just fit within the size requirements of the case, this was good because the box size was set to be only a few millimetres wider than the keyboard.
I created a model for the base of the Arduino controller. I added chamfers along all of the edges to match the aesthetic of the main box. I extruded holes for the switches, joystick pins and Arduino pins with a 0.2mm clearance. I found models online for the keycaps, switches and Arduino but I had to model the joystick myself.
I combined three bread boards into one large one, this allowed for multiple power rails and multiple button rows.
I connected the buttons to one digital pin each with a resistor and LED to ground (the LED acts as diodes as there were none available at the time), I connected the other side of the buttons to a 5v power rail.
I used The LEDs as diodes, they also helped indicate when a button was pressed.
I wired up the buttons up to an Arduino UNO and wrote code to print the pin number of the pressed button into the serial monitor.
I attempted to get the Arduino UNO to work with the keyboard library, this would allow it to send key presses to the computer, however, the Arduino UNO does not have the ATMEGTU4 chip that is required to do this.
I desoldered the original pins on the joystick and soldered new ones that were facing down, this allowed it to be placed flat onto the breadboard without it sticking out.
As the Arduino UNO dit not support the keyboard library, I ordered an Arduino micro as it had the right hardware (ATMEGTU4 chip) to do what I wanted it to do.
I wrote code to allow the buttons to send key presses to the computer via usb, it also allowed the joystick to move the mouse.
I was facing some issues where the keyboard would spam inputs randomly at times when I wan not using it, I decided to google button inouts on an arduino. The proper way was to connect one side of the button to ground, the other side to the digital pin, to set the pin to an “input pullup” and to test for digitalRead() to return low for a closed circuit. This removed the need for resistors and LED’s and would made the circuit simpler and easier to solder later on.
I took this as a chance to switch out the old breadboards with new ones. The old ones had damaged rows from screw holes and multiple 5v and two ground rows in the middle which made it confusing to wire. I also had unidentical breadboards as they were from different sets, this was annoying as some of the boards didn’t clip together and some of the power rails had breaks in the middle.
I looked for a set of identical breadboards that continous power rails. I put one set of power rails in the middle, three on the top side and two on the bottom side. I used the middle one for power and ground, I used the two on the bottom side to carry the signal of the bottom three buttons as it had four lanes available and I used the three on the top side to carry the signal of all six buttons as it had six lanes available.
After I rewired the breadboard, I had issues with the analogue joystick values.
Firstly, the joystick would not return any values, I fixed this issue by wiring the ground of a joystick to the unused ground pin on the Arduino. After some googling, it turns out that you should not use digital and analogue input on the same ground pin.
After this, I had issues where the program would freeze after a few seconds, I fixed this by placing a resistor between the joystick and the new ground pin.
I now had a problem where the values of the joystick would range between 200 and 600 with a resting point around 425 instead of a range between 0 and 1023 and a resting point of 512. This was not ideal as it now had a lower resolution and also because the resting point was not in the centre of the two values. This meant that the mouse would move quicker in one direction than the other. I graphed the ranges and resting points so I could visualise this.
I suspected that this was due to the resistor in the circuit. I tried some other resistor values but it was the same just with slightly different values.
I connected the positive pin of the joystick to a different 5v pin and I swapped the ground resistor for a regular wire, this stopped the crashing issues, but there was still a different range of joystick values.
In the end, I decided that the issue of the joystick values was not a major problem as the program it still worked. I was glad that the resistor were removed, this would make the soldering easier later on.
I graphed the values on top of each other. The green represents the expected value, the blue represents the values before the resistor was removed, the red represents the values with the resistor and the purple represents the values after I connected the 5V to a different pin
The x-axis represents movement in the x-axis on the joystick while the y-axis represents the movement on the y-axis of the joystick.
The dot represents the resting point of the joystick and the boundaries of the boxes represents the upper and lower limit of the joysticks.
The resting points and upper and lower limits were affected by the power supplied to the arduino controller, this varied based on where it was plugged into, a desktop computer or the raspberry. A faulty usb connection could also limit the power being supplied. To counter this, the controller sets the current point as the resting position on statrup, this happens when it is plugged in or when the reset button is pressed.
These errors in the joystick code will result in the cursor moving at a higher speed in one direction when compared to the opposite direction. This could be fixed with code that has different speeds for different directions, or a non linear scale factor, this speed difference was only about 30%, but it was barely noticeable.
Once The low-profile joystick arrived, I desoldered the upright facing pins and soldered new ones were facing down for. I like to use a drill press vice when soldering as it keeps the component in place, as it is portable, it allows me to move it anywhere on the desk (as opposed to a bench mounted vice), Its weight also prevents the whole assembly more moving around the table.
I 3D printed the base of the Arduino controller in red PLA, I printed it with no raft and a 0.3mm layer height, it took about an hour and twenty minutes to print.
The print had some elephant foot issues at one of the sides, this was not a big deal in terms of appearance as it was difficult to spot.
Due to the large layer height causing print inaccuracy, the slots for the Arduino pins were narrower in some places and they were a little bit shorted than expected, I cut out the narrow parts with a stanley knife, continously checking with the arduino untill it fit.
The switches clicked into place nicely and the joystick fit without a problem.
I snapped and cut a solderable breadboard so it would fit over the Arduino pins. Next, I placed the controller upside down, in a drill press vice, to keep it sturdy.
I used brown wire to connect the bottom pins of the switches to each other, and then to ground.
I soldered the top pins of the switches to their corresponding digital pins.
A note to self is to take precaution when soldering deviced from the bottom, I had to resolder most of the circuit as I did it back to front, This includes knowing which direction that it is flipped, horizontally or vertically. some of the wiring could be kept but most had to be redone.
I also learnt that I should be careful when soldering close to the edge of the case, as I accidentally burnt the edge. This was okay it is not visible from the top, but it could have easily gone south.
Next, I connected positive and negitive from the joystick to the Arduino. I connected The X and Y pins to the analogue pins on the Arduino, I had to use different pins as originally planned as some of my previous cable routing had covered up the pins.
Everything worked as intended, except for a blob of solder connecting the X and Y signals, causing them to read the same value.
I downloaded some flat keycaps and printed them in white PLA with a 0.08mm layer height, it took about an hour to print. I had some trouble fitting the keycaps into the switches, but after pushed hard enough, they fit.
I asked the school technitian to cut a piece of steel to size, I used this as a weighted back plate, this covered up the wiring on the back, it added weight which helped dampen the sound, it reduced rattle and it also prevented the stiffness of the cable from moving the controller. Adding weight is common technique in creating mechanic keyboards.
I friction fit the steel into place, this allowed it to be removed to access the wiring if I ever needed to, There was nothing stopping it from being pressed further into the case. I fixed this with some laser cut acrylic pieces to hold it in place. I also placed some laser cut acrylic underneath the joystick as it was only being held in place by its pins at the top, this caused it wobble and bend and touch the case.
I added rubber feet to the bottom on the case on the steel weight to stop it from sliding around on the surface that it sits on.
Although the switches clipped into place, they still could be pushed out (this happened multiple times while soldering), due to this I superglued them into place.
After a couple of days, four of the six key switches stopped working, this is because the superglue covered the metal contact point and prevented the switch from closing the circuit. These four switches had to be desoldered and replaced with spares.
I sliced the models for the base and the lid with a 0.3mm layer height and no raft. According to the slicer, the print would take 16-18 hours. This was too long.
I removed the bottom of the boxes to reduce print time, this could later be replaced with acrylic. As the acrylic was 3mm thick, the box walls also needed to be 3mm thick. The walls were originally 2.4mm thick.
I changed the wall thicklness parameter to 3mm. This worked pretty well but the holes for the ports on the back of the case had to be recut.
This reduced the print time down to five and a half hours and seven hours for the base and lid respectively.
I printed the base and lid over two days, I reduced the print time by half an hour on both by changing the infill from 15% to 10%. I changed the print speed was changed from 60mm/s to 70mm/s on the base whish also decreased print time.
After I removed the brint from the bed, I removed the support material with a pair of longnose pliers and a drill bit.
I asked the school technitian to cut a piece of Acrylic to use for the bottom of the base and lid. I glued it inin place with a hot glue gun.
He also cut out some more acrylic for me to use as the midlayer, this just sits in place as it needs to be removable.
As the model of the raspberry pi was incorrect, I had to cut the usb port holes larger as they were too low. I used a soldering iron and a pair of flush cutters to do this, As the print took five and a half hours, I did not want to wait that long. I also had to cut a section out of the midlayer for the same reason, this was okay as the keyboard covers it
After I fit the raspberry pi into the side of the case, I screwed it into the two stand offs that were integrated into the 3d printed case, they were on the side closest to the lid. The other two were removed when I swapped out the bottom for acryllic. I could have added 2 standoffs in the acryllic but they were not necessary as the other two were holding it in place.
I glued the lcd screen and controller board in place and used a straightened metal rod to act as a hinge pin that covered both hinges, I bent it down at both ends to prevent it from being pulled out.
I put the acrylic midlayer in place, and put the keyboard and Arduino controller on top of it.
The mini-HDMI to HDMI ribbon cable was too short to reach both the raspberry pi and the screen without causing stress on the cable and without risk of the cable folding. I ordered a slightly longer cable to fix this issue. The display cables also weren’t able to be pushed in far enough. I had to melt and cut out plastic to allow the cables to fully sit within the ports
The lid was getting stuck and would not shut completely when I tried to close it.
I removed the rubber section of the joystick and replaced with a piece of laser cut acrylic. This allowed enough clearance for the screen to shut without being touched. With help from the school technitian, we engraved a pattern into the top of the acrylic joystick to provide grip.
The screen kept falling out of the lid, I glued it glued back into place, but it kept falling out, the hot glue had trouble sticking to the aluminum case of the lcd screen.
I 3d printed screen clips to fit over the corners of the screen and I glued them to the inside of the lid.
Next, I plugged in everything to see if it worked.
The screen did not work straight away, it turned on but it turned off after a few seconds, I tested it with another computer, and it still didn’t work. I tested the raspberry pi with a projector and it worked fine.
I had a look on google, and it turns out that there is a hdmi_safe setting on the raspberry pi in the config.txt file, it was was disabled by default. When enabled, the raspberry pi boots with maximum HDMI compatibility. This resolved the issue, however the screen was a low resolution and distorted.
There is a setting called headless resolution, and it was set to 640x480, I changed it to 1024x768 as it was the closest option to the screen resolution.
I then set the appearance setting to small screen.
One of the requirements was that the cyberdeck had to fit inside a backpack, to meet this requirement, I aimed was to limit the base of the cyberdeck to be no larger than an A4 sheet of paper. I tested to fit on top of an A4 and A3 sheet of paper along with fitting inside a 32L and 19L backpack.
I conducted these tests to ensure that the cyberdeck was portable and could be carried around.
The final dimensions of the cyberdeck were 209mm x 274mm x 73mm fitting within the size requirement and meeting the constraint.
The cost of this project was around $400, the biggest expenses were the keyboard, the screen and the cables.
It was tricky to get cables that were exactly the right orientation and length, I found some on Ali Express.
Most laptop screens will cost around the $50 mark. Another route is to get a screen from an old laptop, and you can then buy a driver board online for around 20 to 30 dollars.
I love the keyboard that I used for this project. It is a 40 percent layout that uses additional function keys to access the number and function rows.
| Item | Amount | Cost per unit | Total |
| Vortex core 40 (keyboard) | 1 | $138.65 | $138.65 |
| Screen | 1 | $049.67 | $049.67 |
| Raspberry pi | 1 | $035.00 | $035.00 |
| Powerbank | 2 | $038.00 | $076.00 |
| Arduino nano | 1 | $023.95 | $023.95 |
| Key switches | 6 | $001.45 | $008.72 |
| Cables | 1 | $052.73 | $052.73 |
| Total: | $400.97 |