Final Project - Low poly - Lightsword

Final Project - Low poly - Lightsword

Tools and Programs used in Final Project:

For my final project i had several ideas, but wasn't sure what to pick in the end. I had anxiety thinking what i was even able to create and ended up with those two ideas in the end from which i had to pick one

First i thought about a glove which could be used as an input for a PC. The basic idea was to use the hand itself to point at the screen and use different fingers for different commands

My second idea was to create a sword which could be used just as decoration or even cosplay. But mostly because it's just cool to have a glowing sword.

In the end i wasn't sure if the glove idea was maybe too complicated for me and since i had to also prepare for other projects and other exams i decided for the sword project because designing is one of my strenghts and i have way more fun designing the body of the project than doing too complicated programming and electronics.

So i decided for the sword. The next step was to decide how i want to design and realise it.

For inspiration i looked at some pop culture swords online and first decided to recreate the master sword from the "The Legend of Zelda" games.

After some time tinkering with sketches i realised, that recreating the sword would take very long and wasn't the savest way to approach the project.

Next i had to decide what parts i want to use to realise it. Since i wasn't sure how big of a board i would need i just used the Atmega 328p so i had enough pins to savely attach everything i need without having to find out later that it won't fit.

Now i had to think What parts would be best suited for which of the needed tools i had to use. I broke the whole sword up in the following parts:

After thinking how to realise the parts i decided on the following:


I started designing and milling the board, when i still wasn't 100% sure what tools i was going to use in my project. Like i stated before, i took one with a lot of pins so definitely enough pins to realise the project./p>

First i downloaded the Satshakit-128-master from Github and used it as my base. I added the needed VCC and GNDn capacitors, the crystal and the needed pins for programming and for input and output devices.

For more detailed workflow how to design your own board look at my documentation from week 6 here

The Bord circuit diagram


The Board layout


After milling and soldering all the parts i came out with this


When i first tried to burn the bootloader though i had several problems first.

Since it's not so easy to solder the microcontroller onto the board without moving it all the time i had a short circuit. So i had to check the connectivities first. I found out that the VCC and GND were connected because of the slight moving of the microcontroller while soldering

I had luck getting it off without doing too much damage to the board. Still i had to fix 2 thin parts with soldering because the copper came out just a little bit.

Now my board was fixed and i was able to burn the bootloader using an arduino.

<4>Input and Output Hardware

For Input i decided for a distance sensor. The sensor is connected with VCC, Ground and 2 digital pins for Trigger and Echo. The sensor works in the way that the Trigger sends of sonic waves and the echo reads those waves. With the code that will follow shortly you can see the calculation.

The Output is a LED strip. The LED strip is connected with 3 pins. One for VCC, one for Ground and one for the digital pin on the board. It's fairly easy to connect.

The Code

Here is my complete code.

First i wrote the part, so that my board can use the distance sensor. After that i implemented the LED part in the if statement inside the loop. Before that i had to install the Library for the LED strip and write the lines to use the library in the setup.

For the Sensor i picked the pins 10 and 9. For the LED the pin 8. All of those pins are digital pins. Everytime i tried something out i uploaded the code anew with an arduino

For more detailed code work look into my documentation of assignment embedded programming here


As for the Power Source i took a 9 Volt battery and connected it through an Volt Regulator so i get an ouput of 5 Volt. The Regulator has 3 pins. The left pin uses the pin of the battery to get the input

The middle pin is the ground. Both the board and the battery have to be connected here. The last pin on the right is the regulated voltage that goes into a VCC pin on the board.


Here you can see that the code and the hardware is working. The light stay for 10 seconds before turning off again.


Sword Body design to 3D Print and Lasercut

First i created a sketch and extruded the parts to create the body of the sword


I thought i could use slicer to slice the blades parts into smaller parts, but the amount of parts would have been too great. The design of the hilt and hand guard was fine though, so i exported them into their own projects so i could load them up in cura.

Here are the 2 parts in Cura ready for 3D printing. For more detailed explanation what setting i used check out my documentation about 3D printing here

Swordhilt in Fusion 360


Swordhilt in Cura


Handguard in Fusion 360


Swordhilt in Cura


The very first prints were a success. Here's what it looked like


Since the most stress would be on those parts i thought i'd rather glue these parts together so it won't fall off and break some parts, that would have been the worst case.


After the hilt and handguard was done i went back to the blade. This time i designed it like a box but with a triangle on the top for the tip. I put in joints so the construct holds itself.


Then i created the kerf and all neccessary steps to cut the plexiglass.

For more detailed steps to design and cut with a lasercutter look into my documentation in lasercutting here

Here are the Parts assembled.


Sadly even tho i followed the kerf that was written in a note in the fablab, the parts of the blade still were not stable enough. Because of that i had to use a hotglue pistol to further stabilize the blade

After the final assemble, here we got the final product. You can see the working sword in action in the video right under here!




Hand Guard stl

Hilt stl

blade dxf

Circuit diagramm .sch

Board Layout .brd