Fredt - Self Playing Guitar
A self-playing acoustic guitar that performs with no human involvement. The system can independently fret any string at any fret, allowing it to play full melodies and chords. This enables the guitar to perform any song acoustically under computer control.
Created by
gustavbecker8
Tier 1
12 views
0 followers
gustavbecker8
added to the journal ago
Still prototyping...
I just changed some stuff. No major progress:
I superglued the rod and string together with the adapter I printed. This turned out not to work. The superglue just came off. Will still see how I will fix it.
Tested fretter2. Measurements was off. It was fixed and I also 3d modelled fretter3. They were printed together. Measured again. Fretter2 was now right, but fretter3 was wrong size. Adjustments was made and will be printed on the next print.
Test fitted small bearings in main holder. Worked like tested.

3D designed and made sure the big boy servo holders are ready. I also printed them. Then I added heated inserts for screws to holder the servos in. This actually came out supprisingly well.


I had some issues on putting the guitar in when the arm of the fretters was on. It was in the way. I added to the gantry shell 3d print a slot so that I can move it out of the way. Will still see how well this works. Hopefully it works.

gustavbecker8
added to the journal ago
Closer and closer
First I started with the first final assemblies! Very exciting. I added the stepper motors to the stepper holders.
Then I added the limit switches and wired it up. Took FOREVER...


I 3d modelled + printed angles to lift the whole guitar 4 cm higher since the lowest DIN rail is too close to the ground the allow the gantry to move freely. The print did not work... The steppers ended up being too heavy and just made the whole thing tip. So new idea. BOX. I taped two boxes to the main support structures. Works like a champ. I know this sounds quick and simple. But you do not understand how long the print took to figure out and get the angles correct just for it not to work. So please appreciate my beautifull box idea.

I fixed the dimentions of the fretting finger. It was too long. And printed it. Lastly I made a simple rig for the pcb for the picking servos to sit on. It turned out well although my measurements were a bit off, but it will do.

gustavbecker8
added to the journal ago
More Progress
I ran a full fit test to see what fits and what doesn't. To just have a better idea of how everything fits together. The fretter (2) head didn't have the right measurements. I remeasured the fretter head and fixed it on the 3D model. This is now fixed I must just print. I must still make fretter head 1 and 3. (Outer string + inner string)



I remodelled the larger servo holder to accommodate all 6 servos. So far I just had a single holder for testing purposes. The full 6 version will be printed tomorrow.

The gantry system had a huge flaw that I have avoided the whole time even tho I knew about it. The fretter head was never constraint in the rotational axis. I finally fixed it by creating a slot in the housing and adding a pin to the rod and string connector. This was printer and tested and worked.



I redesigned the picks holders that fasten the picks to the servo's to make it more accessable and fit better. It is also now fastened by a screw, not just friction. The were also made shorter to give more way for the plastic of the pick to flex.


gustavbecker8
added to the journal ago
Tinkering with the build
I am almost completely done with the picking system. It still needs some adjusting with the picks itself. The sizing was wrong, but it should be a quick fix. For the picks I use an ice cream holder's plastick.
I made a video and everything how it is playing but it seems like blueprint doesn't allow to upload videos. Which makes sense.
Anyway, here is the code I used to tinker around. It kinda plays the intro to "Nothing else matters". But without being able to puch frets it sounds a bit bland.
Here is a short vid that shows some playing:
20260505_212739
#include <Wire.h>
#include <Adafruit_PWMServoDriver.h>
Adafruit_PWMServoDriver pwm = Adafruit_PWMServoDriver();
// Your calibrated values
int sideA[6] = {350, 350, 350, 350, 335, 365};
int sideB[6] = {400, 400, 400, 400, 385, 415};
int currentStates[6] = {0, 0, 0, 0, 0, 0};
void setup() {
Serial.begin(9600);
pwm.begin();
pwm.setPWMFreq(50);
for(int i = 0; i < 6; i++) {
pwm.setPWM(i, 0, sideA[i]);
}
Serial.println("Ready. Type 'm' for Metallica Intro, 's' for Strum.");
}
void loop() {
if (Serial.available() > 0) {
char input = Serial.read();
if (input == '\n' || input == '\r') return;
if (input == 's') {
executeStrum(20);
}
else if (input == 'm') {
playMetallica();
}
else if (input >= '0' && input <= '5') {
toggleString(input - '0');
}
}
}
void toggleString(int s) {
if (currentStates[s] == 0) {
pwm.setPWM(s, 0, sideB[s]);
currentStates[s] = 1;
} else {
pwm.setPWM(s, 0, sideA[s]);
currentStates[s] = 0;
}
}
void executeStrum(int speed) {
for (int i = 0; i < 6; i++) {
toggleString(i);
delay(speed);
}
}
// The Metallica "Nothing Else Matters" Sequence
void playMetallica() {
Serial.println("Playing Metallica...");
int notes[] = {0, 3, 4, 5, 4, 3}; // E, G, B, e, B, G
int timing[] = {333, 333, 333, 333, 333, 320}; // Delay after each note (ms)
for (int o = 0; o < 8; o++) {
for (int i = 0; i < 6; i++) {
toggleString(notes[i]);
delay(timing[i]);
}
}
}


gustavbecker8
added to the journal ago
Some hiccups
I cutted 1 new DIN rail. So for now I have 2 with the right length. I don't want to cut all of them at once. Cos I'm lazy.
I printed the left side, but due to my printing bed accidentally melting itself the print lifted itself off the bed. In my attempt to save the print. I superglued the print to the bed.
The print finished well and measurements wasn't off by too much due to the bending.

But after the print I had enough and decided to solder the bed's wires to itself, because the connector is not rated for the amount of amps the cable pulls. (Common Anet A8 problem)
The soldering took a while since my soldering iron is quite crap. I did buy a new one but don't know where it is.

After the soldering it took me ages to finally recalibrate the bed leveling, etc of the printer. But now when I print, the first layer is completely messed up and weird. But at least the bed is hot. You remember that I said that I superglued the part to my bed? Well turns out, the superglue cannot be removed then. I know nailpolishremover works, but I don't have any. So I am stuck...
Look at this horrible first layer. Wants to make me cry.

I also added some material to the bottom of the servo holder so that it doesn't damage the guitar. The other servo's were also added.


I assembled the first actual gantry that I might use in the final build. While I was assembling it, I noticed a few things:
Holes for heated inserts was too small
Screw heights were too big
These things were fixed in the 3d model on Fusion.

gustavbecker8
added to the journal ago
Create baseplate for electronics
I wanted something to fix the elctronics to, to make it more stable and not let it accidentally break.
I made this baseplate, but I only put 2 supports per pcb, 4 would have been better. But it is too late now and the print took too long. But for now this will work.



The stepper drivers also needed an housing. I just made a structured brace where I atrach them with heated inserts. The heated inserts gave some problems, since it kept getting stuck to my soldering iron and then pulling out a whole blob of plastic. But I was able to manage and it turned out pretty decent.



Really happy with my progress. Currently busy printing the other half of the guitar neck part. (The one I accidentally switched the plug of)
gustavbecker8
added to the journal ago
String picking and servo holder
The new screws and super glue I ordered had arrived, so I don't have to be worried about having too little screws anymore. I added the string picking mechanism hardware. It was a weird complex design, but it works. The design took quite a while to work with the guitar as well. It holds the 90g servos with a perfect offset for the strings.
The servos fitted perfectly first try into the print! (Very rare to happen)



Next I wanted to print a single housing to test the servo for pulling the fretter down. I modified my design. The print thankfully went smooth and the servo fitted. I didn't like how the servo just sat loosely in the housing, so I changed that by adding 2 screws. It isn't neccessary now, so I didn't have to print it, but for my next print it will have the updates.


gustavbecker8
added to the journal ago
Printed and it's starting to take shape!
I 3d printed the guitar holder and it came out good. This was now after my failed print. (I accidentally switched the power off of the printer while printing)
I also 3d modeled some changes to the guitar head holder side as well as print that. It actually came out pretty good. I had to change the size of the DIN rail due to it being a bit longer than I anticipated. Very happy with the overall progress.



Through all this I was still on a mission to finish the gantry. After every print I find something that doesn't work. Was a very tedius and frustrating job. I think most of the things are tuned now. I will add some pictures of the wrong measurements and then the correct ones as well to show the difference. This is due to my printer tolerences that are massive. One day I will have a really good printer..




gustavbecker8
added to the journal ago
Finished the designs holding guitar neck
I have been working through engineering study breaks and almost finished the guitar neck holder part.
First I accidentally designed it without fitting with the actual guitar I will be using. So some of the stepper motor hold part would interfere with the actual guitar. This is fixed now after a lot of grinding and head scratching.
These parts will have to be printed in halves because of their size and my printer capabilities.
I tried printing the first half today, but accidentally switched my printer off in the process while starting with some of the hardware code of the project. As you can imagine this was after 4 hours of printing. I was sooooo mad, frustrated and just down. Will try the print again tomorrow.
I also ordered some extra screws and heated inserts on my own budget since I initially ordered too little.



gustavbecker8
added to the journal ago
Refining the gantry system
The gantry system I designed in the previous journal entry was too wide and thick. Had some unneccessary holes and space.
I decided to tweak the design to merge the gantry part and the linear-bearings-holder-housing. This was a ton of effort since I, AGAIN, messed up the tolerences due to my beautiful printer printing not the best. Don't get me wrong, I love the printer and it is an honor to have a printer.
But it broke me when the printer tangled itself on one of the prints and broke the whole filament holder. It threw the whole thing onto the floor. I picked it up fixed it best I can, and started a new print. Just to come back and see the heated bed burnt its own power supply cable. This is a common issue with the Anet A8's. I knew about it and it has happend to be me before, but it is still not nice when it happens. Had to restart that same print again.
At the end I got a working design, but the printing orientation was the next issue. My printer can't print supports without fusing them to the part and basically make it impossible to remove. I got some sort of way to get a decent print, but will have to sort something out for next time, because this is not working.
Sorry about all the complaints, I am really happy with my progress and the part is now almost ready to move on to the rail and stepper housing. (Very excited for this)
I the attachments you can see the thickness comparisons of the old one and the new ones.





gustavbecker8
added to the journal ago
Creating the actuator
Next in line was the actuator that will pull down on the string.
This is a bit harder when my printer can't print the correct tolerences so I had to get really specific and make sooo many prototypes.
This also had to be redesigned since I decided on using 2 linear bearings in stead of 1 for the rod pulling down to keep it straight. I started with seperate bodies. This worked better since I only had to print the one side if it didn't fit.
At first I designed it to not have a placement for the spring, but is neccessary, because else the spring sits too loosly.
Everything is held together with M3 screws and heated inserts. It works amazing. Although I kinda ordered too little. I will probably buy more later in the future.
This was a very excited checkpoint in this journey, because it was my first time holding a part of the project and seeing it work. Very excited!







gustavbecker8
added to the journal ago
I received the parts!
The parts finally arrived from Temu.
I checked and everything was there. Thank you to BluePrint for actually holding up to their side of the deal.
Now it's time to print and build!
First I started with the gantry and how it will work. I had to make quite a few changes to the original design since I went from a 4 wheel system to a 3 wheel system.
I also really had some trouble with my 3D printer. It doesn't print the same tolerences and really frustrates me when you need a part that depends on .1mm tolerence. Hopefully after this project I will have enough tokens to get a new 3D printer!
I printer about 20 different designs for the wheels to roll smoothly over the rail. Very frustrating. But got it at the end. The dimentions and tightness of the wheels had to be changed the whole time. The bearing-fit tolerances was also a struggle. But at the end we got there and the gantry runs smooth enough.






CAN ⚡🚀
approved Fredt - Self Playing Guitar ago
Tier approved: 1
Grant approved: $284.00
Awesome project, I cannot wait to see it built
gustavbecker8
added to the journal ago
Programming base structure
I have been brain storming about how this coding structure will work.
I will use a live timer and then match each note with the live timer to keep it in the right rhythm.
Some planning I did in class

import time
import threading
def run_timer():
# We use a shared start time so other functions can calculate elapsed time too
start_time = time.perf_counter()
while True:
elapsed_ms = (time.perf_counter() - start_time) * 1000
# \r keeps the print on one line; we add spaces to clear old text
print(f"Time: {elapsed_ms:.2f} ms ", end="\r")
time.sleep(0.01) # 10ms sleep is usually enough for display
def read_file():
song_array = []
try:
with open("tabs.txt", "r") as file:
cum_val = 0
for line in file:
parts = line.strip().split('|')
if len(parts) == 3:
duration = int(parts[2])
cum_val += duration
row = [int(parts[0]), int(parts[1]), duration, cum_val]
song_array.append(row)
return song_array
except FileNotFoundError:
print("Error: tabs.txt not found.")
return []
if __name__ == "__main__":
tabs_2d = read_file()
# --- START THREADING HERE ---
# We create a thread to run the timer function
timer_thread = threading.Thread(target=run_timer, daemon=True)
input("Press Enter to start the program and timer...")
timer_thread.start() # This starts the background loop
# ----------------------------
if tabs_2d:
# Note: I fixed the loop logic here (iterating through elements, not indices)
for note in tabs_2d:
print(f"\nProcessing Note: String {note[0]}, Fret {note[1]}")
time.sleep(note[2]/1000)
gustavbecker8
added to the journal ago
Working on the code
Worked on some code to simulate the idea I have to sort and work with the guitar tabs.
Ended up not working perfectly, but somewhat. Gave me a good starting point.
Will be using fingerstyle GuitarPro (.gp5) files of the songs to get the tabs. It will then be converted and prepared to be used in with the arduino or raspberry pi. Yes, I am thinking of maybe switching to raspberry pi since it can actually store a textfile for the song data.
import guitarpro
import numpy as np
import pygame
import math
import time
import os
# -------------------------
# Audio Setup
# -------------------------
SAMPLE_RATE = 44100
VOLUME = 0.4
pygame.mixer.init(frequency=SAMPLE_RATE, size=-16, channels=1)
# Standard tuning (Hz)
STRING_TUNING = {
1: 329.63, # E4
2: 246.94, # B3
3: 196.00, # G3
4: 146.83, # D3
5: 110.00, # A2
6: 82.41 # E2
}
# -------------------------
# Sound Generation
# -------------------------
def plucked_string(frequency, duration):
t = np.linspace(0, duration, int(SAMPLE_RATE * duration), False)
# Rich harmonic tone
wave = (
np.sin(frequency * 2 * np.pi * t) +
0.5 * np.sin(2 * frequency * 2 * np.pi * t) +
0.25 * np.sin(3 * frequency * 2 * np.pi * t)
)
# Exponential decay envelope
envelope = np.exp(-4 * t)
wave *= envelope
# Normalize
mono_audio = wave * (32767 * VOLUME / np.max(np.abs(wave)))
mono_audio = mono_audio.astype(np.int16)
stereo_audio = np.column_stack((mono_audio, mono_audio))
return pygame.sndarray.make_sound(stereo_audio)
# -------------------------
# GP Playback
# -------------------------
def play_gp_file(filename, mode):
song = guitarpro.parse(filename)
tempo = song.tempo
seconds_per_beat = 60.0 / tempo
print(f"Tempo: {tempo} BPM")
if mode == 1:
# PLAY ALL TRACKS TOGETHER
for measure_index in range(len(song.tracks[0].measures)):
for track in song.tracks:
measure = track.measures[measure_index]
for voice in measure.voices:
for beat in voice.beats:
beat_duration = beat.duration.time / 960.0
duration_seconds = beat_duration * seconds_per_beat
for note in beat.notes:
string_number = note.string
fret = note.value
base_freq = STRING_TUNING[string_number]
freq = base_freq * (2 ** (fret / 12.0))
plucked_string(freq, duration_seconds).play()
time.sleep(duration_seconds)
else:
# PLAY TRACKS ONE AFTER ANOTHER
for track in song.tracks:
print(f"\nPlaying track: {track.name}")
for measure in track.measures:
for voice in measure.voices:
for beat in voice.beats:
beat_duration = beat.duration.time / 960.0
duration_seconds = beat_duration * seconds_per_beat
for note in beat.notes:
string_number = note.string
fret = note.value
base_freq = STRING_TUNING[string_number]
freq = base_freq * (2 ** (fret / 12.0))
plucked_string(freq, duration_seconds).play()
time.sleep(duration_seconds)
# -------------------------
# Run
# -------------------------
def choose_play_mode():
print("\nPlayback Mode:")
print("1. Play all instruments together")
print("2. Play instruments one after another")
choice = int(input("Select mode: "))
return choice
def choose_song():
folder = "songs"
files = [f for f in os.listdir(folder) if f.endswith((".gp3", ".gp4", ".gp5"))]
if not files:
print("No supported GP files found in songs folder.")
return None
print("\nAvailable Songs:")
for i, file in enumerate(files):
print(f"{i + 1}. {file}")
choice = int(input("\nSelect song number: "))
return os.path.join(folder, files[choice - 1])
if __name__ == "__main__":
selected_file = choose_song()
if selected_file:
mode = choose_play_mode()
play_gp_file(selected_file, mode)
String tuning to simulate the sound of a guitar.

gustavbecker8
submitted Fredt - Self Playing Guitar for ship review ago
gustavbecker8
added to the journal ago
More bugs to fix...
I got more suggestions about what to fix before I can get the funds for it.
I uploaded all the different parts and made a demo video to show how it works. This should be everything now, hopefully.

zsharpminor âš¡
requested changes for Fredt - Self Playing Guitar ago
Okay, this is insanely cool. I made a very similar project (self-playing violin) at prototype and it wasn't quite as impressive. I have one final request before this can be approved - could you please show how the guitar is going to finger itself, I.e. how the fretting mechanism will actuate the string with enough force? At Prototype, I used TPU gaskets on a custom part - that's still unclear to me based on your repo. Otherwise, please upload each individual part as a .step file, thanks!
gustavbecker8
submitted Fredt - Self Playing Guitar for ship review ago
gustavbecker8
added to the journal ago
Fixing errors
I got feedback to remove 3D printer filament and get the table format correct by my BOM.
Only after changing the comma to a full stop in excel was the error fixed.
Everything should be right now, I hope.

Iamalive 🚀
requested changes for Fredt - Self Playing Guitar ago
Awesome work! Love the amount of polish you've got on this :) Two small things and you should be good to go: please fix your BOM(right now it looks like it isn't formatted correctly :( ) and take out the filament, as we don't allow grants to be spent on shop items.
gustavbecker8
submitted Fredt - Self Playing Guitar for ship review ago
gustavbecker8
added to the journal ago
Setting up for Submission
After figuring out what I wanted to achieve with the software I finished with a basic script to test if everything would work by playing happy birthday on the guitar. I don't know if it will work since I had no way of testing it.
The script was written in the Arduino IDE.
Before I could submit I first still had to upload everything to my GitHub. I have never used GitHub before and I really didn't know what I was doing, but ChatGPT was a life saver here.
I got everything uploaded and ready for submission. I also wrote my ReadMe.

Just for one last time, here are some images of the complete CAD model:



gustavbecker8
added to the journal ago
Finish small details
I forgot to add the electronics to the CAD model.
The models were all found on GrabCAD.com. Amazing website.
I couldn't find any 3D models of the 12v to 5v Buck converter (xy-3606) that I wanted to use so I had to skip that.
But after adding everything and making some holder for them, since they can't just sit there freely, it came out looking quite nice.
I also had to add the limit switches to the CAD model as well as the schematics diagram, since I also forgot about that.


This is the holder for the tb6600 stepper drivers. They are a bit larger than I thought they would be.

The software was something that I was avoiding for a while now since it is such a hard thing to do without being able to test the code. But I start with it so long.
gustavbecker8
added to the journal ago
Finished the BOM
I just finished the BOM. This project came out to be a bit more expensive than I thought it would be.
I don't know if they will approve it, but I sure hope so.
I really want to see this idea come to life.

I also made a mistake on my schematic diagram, but it was an easy and quick fix.
gustavbecker8
added to the journal ago
Finished the schematics
I just finished the schematics. A lot of work went into it since I first had to figure out how to do it. (I've never done it before) Did it on Fritzing. Works like a dream.
Did it wrong the first time and had to start again.

This diagram is quite small. I don't know how to show it to you more clearly.
Now all that is left is the BOM, adding electronics to CAD model, coding software, creating readme file and setting up Github. (I don't know how to work with GitHub, so I'll have to figure that out still)
gustavbecker8
added to the journal ago
Finishing off CAD model
I added the GT2 belts and stepper gear headers.
The guitar also has to be able to stand level some how. So I though of making the whole design based on it laying down. I add support for the guitar head side and neck side.
The stepper holders that were seperate was not working properly with the stand I had in mind so I merged it.





Must still add electronics in the CAD.
gustavbecker8
added to the journal ago
Everything is standing
I started with the idea to just create the holders for the stepper motors and rails, but boy it was far from just that.
I started with the attachment that will hold the rails closest to the guitar head. This part will also hold the MR105 bearings that will be used to loop die GT2 belt back to the steppers.

After that I moved on to the tail of the guitar where the servos would be.
A mistake I made earlier was to accidently download a Nema 14 stepper model in stead of a Nema 17 stepper motor. I first had to fix that. Find a new one, download and import.
The way to house the steppers were pretty complex and a real head scratcher. But I got something that should work.


I don't have the proper 3D printer to actually start with this project, but hopefully I can figure something out.
gustavbecker8
added to the journal ago
Started with Final CAD!
For the final CAD design I needed an acoustic guitar CAD model. The one I downloaded wasn't perfect and not completely to the size of my guitar. The guitar's strings were incorrect sizes and widths. I had to restring the guitar in CAD.
The pick playing servo mount was measured incorrectly and I had to fix it.

After a very long debugging session I found the mistake.
The guitar strings gave some new problems again, so I had to fix it again.
The picking servo holder was also too close to eachother which I moved apart.
My servo holes was also too narrow. Had to widen them.
The picks I created were too short and couldn't reach the actual strings.
I created the 6mm shafts in CAD and added them.
I still don't have any mounts for the stepper motors and the DIN rails. I don't feel comfortable doing it in CAD. Would want to do it when it is here and printed out.

I added the MG996R servo holder and servos to final build. These servos will pull the thin stainless steel cable that will go through the PTFE Teflon tube and actuate the string push mechanism.

This is the picking system with the SG90 servos.





Some pictures of what the final build would look like.
gustavbecker8
added to the journal ago
Progress log 1
For this progress log I started by making my object more realistic compared to the basic 3D model that was just for the idea.
I cleaned up files structures and seperated the different components in their own files.
Next on my design requirements I made a holder for the MG996R servos since they would work with PTFE Teflon tube with a stainless steel wire running through to create a bowden cable. Not sure yet where this box will be put at the end.

Next I had to create the pick that will be used for the SG90 servo's to interact with the strings. This will definitely not be the final design since I have no idea how this shape and hardness will interact and sound when strumming with it.

Lastly I created a structure that will hold the SG90 servos that will do the strumming in place. This will make a bit more sense when I create a final full assembly. I will use two of these and sandwich them together. The long legs will have soft ends that will press on the guitar. The whole thing will be strapped onto the guitar.


gustavbecker8
added to the journal ago
New idea, New design
I redesigned again with a completely different approach. In stead of moving the whole servo to press the strings, what about I use those cable mechanisms that a bike's brakes use. A bowden cable. Then I can keep the servo statically on the side and just use their movement through PTFE Teflon Tube with a stainless steel wire running through it. This idea came from Kuzma self playing guitars. Have to give credit where it is due.
But before I will explain that, I had to create a completely new gantry system to keep everything as close to the guitar as possible since the further it is away from the strings the more the 3D prints can flex.

This is the new gantry system. It uses 4 bearing on a generic DIN Rail. I could've used 3 bearings, but chose 4 to make it more stable.
The string pressing mechanism is a bit tricky, but after some brain storming I came to a better design.


I decided on using a 6mm hardend steel rod with 6mm linear bearings for the main part pulling down. This will reduce flex. The rod is not shown in the 3D design to make it easier to understand.

I added everything together to make an assembly for others to understand better. (Without the 6mm steel rods)
I added the guitar neck + strings with somewhat accurate measurements to better visualize the size.

I
gustavbecker8
added to the journal ago
New CAD design
I had to restart my CAD design process since the servos was too weak. The kept keeping it as cheap as possible since I haven't heard of hackclub yet.
I tried implementing a rail with a bearing linear workaround since linear bearing are more expensive than normal bearing. Now I can design with more confidence since I now I will have enough money to build it.
The new design use MG996R servos. They are much larger and I had to change the design completely. I am trying to use the whole 360 of the guitar neck since that would be space effecient. This design is far from done. Just want to make an update journal entry so long.

gustavbecker8
added to the journal ago
Starting CAD design
I started my CAD design with a rough idea of what I want. It came out alright, but soon after I realized a few issues.
Firstly, the servos I intended on using was not near the amount of power I needed. I wanted to use the generic 9g servos to press the strings for chords, but the strings are too tight for that weak servo. I has to start over with the design since the stronger servo are much larger.
Secondly, the design uses linear rails and bearings. I initially thought of using on rail per string per servo, but that will not work due to it still be able to rotate. This issue must still be figured out and fixed.
Thirdly, money. I have to try optimise my design to save money. I don't have much and don't want to waste it.

gustavbecker8
started Fredt - Self Playing Guitar ago
1/10/2026 8:35 PM - Starting CAD design
I started my CAD design with a rough idea of what I want. It came out alright, but soon after I realized a few issues.
Firstly, the servos I intended on using was not near the amount of power I needed. I wanted to use the generic 9g servos to press the strings for chords, but the strings are too tight for that weak servo. I has to start over with the design since the stronger servo are much larger.
Secondly, the design uses linear rails and bearings. I initially thought of using on rail per string per servo, but that will not work due to it still be able to rotate. This issue must still be figured out and fixed.
Thirdly, money. I have to try optimise my design to save money. I don't have much and don't want to waste it.

1/10/2026 8:47 PM - New CAD design
I had to restart my CAD design process since the servos was too weak. The kept keeping it as cheap as possible since I haven't heard of hackclub yet.
I tried implementing a rail with a bearing linear workaround since linear bearing are more expensive than normal bearing. Now I can design with more confidence since I now I will have enough money to build it.
The new design use MG996R servos. They are much larger and I had to change the design completely. I am trying to use the whole 360 of the guitar neck since that would be space effecient. This design is far from done. Just want to make an update journal entry so long.

1/12/2026 - New idea, New design
I redesigned again with a completely different approach. In stead of moving the whole servo to press the strings, what about I use those cable mechanisms that a bike's brakes use. A bowden cable. Then I can keep the servo statically on the side and just use their movement through PTFE Teflon Tube with a stainless steel wire running through it. This idea came from Kuzma self playing guitars. Have to give credit where it is due.
But before I will explain that, I had to create a completely new gantry system to keep everything as close to the guitar as possible since the further it is away from the strings the more the 3D prints can flex.

This is the new gantry system. It uses 4 bearing on a generic DIN Rail. I could've used 3 bearings, but chose 4 to make it more stable.
The string pressing mechanism is a bit tricky, but after some brain storming I came to a better design.


I decided on using a 6mm hardend steel rod with 6mm linear bearings for the main part pulling down. This will reduce flex. The rod is not shown in the 3D design to make it easier to understand.

I added everything together to make an assembly for others to understand better. (Without the 6mm steel rods)
I added the guitar neck + strings with somewhat accurate measurements to better visualize the size.

I
1/14/2026 - Progress log 1
For this progress log I started by making my object more realistic compared to the basic 3D model that was just for the idea.
I cleaned up files structures and seperated the different components in their own files.
Next on my design requirements I made a holder for the MG996R servos since they would work with PTFE Teflon tube with a stainless steel wire running through to create a bowden cable. Not sure yet where this box will be put at the end.

Next I had to create the pick that will be used for the SG90 servo's to interact with the strings. This will definitely not be the final design since I have no idea how this shape and hardness will interact and sound when strumming with it.

Lastly I created a structure that will hold the SG90 servos that will do the strumming in place. This will make a bit more sense when I create a final full assembly. I will use two of these and sandwich them together. The long legs will have soft ends that will press on the guitar. The whole thing will be strapped onto the guitar.


1/17/2026 - Started with Final CAD!
For the final CAD design I needed an acoustic guitar CAD model. The one I downloaded wasn't perfect and not completely to the size of my guitar. The guitar's strings were incorrect sizes and widths. I had to restring the guitar in CAD.
The pick playing servo mount was measured incorrectly and I had to fix it.

After a very long debugging session I found the mistake.
The guitar strings gave some new problems again, so I had to fix it again.
The picking servo holder was also too close to eachother which I moved apart.
My servo holes was also too narrow. Had to widen them.
The picks I created were too short and couldn't reach the actual strings.
I created the 6mm shafts in CAD and added them.
I still don't have any mounts for the stepper motors and the DIN rails. I don't feel comfortable doing it in CAD. Would want to do it when it is here and printed out.

I added the MG996R servo holder and servos to final build. These servos will pull the thin stainless steel cable that will go through the PTFE Teflon tube and actuate the string push mechanism.

This is the picking system with the SG90 servos.





Some pictures of what the final build would look like.
1/18/2026 - Everything is standing
I started with the idea to just create the holders for the stepper motors and rails, but boy it was far from just that.
I started with the attachment that will hold the rails closest to the guitar head. This part will also hold the MR105 bearings that will be used to loop die GT2 belt back to the steppers.

After that I moved on to the tail of the guitar where the servos would be.
A mistake I made earlier was to accidently download a Nema 14 stepper model in stead of a Nema 17 stepper motor. I first had to fix that. Find a new one, download and import.
The way to house the steppers were pretty complex and a real head scratcher. But I got something that should work.


I don't have the proper 3D printer to actually start with this project, but hopefully I can figure something out.
1/19/2026 2:25 PM - Finishing off CAD model
I added the GT2 belts and stepper gear headers.
The guitar also has to be able to stand level some how. So I though of making the whole design based on it laying down. I add support for the guitar head side and neck side.
The stepper holders that were seperate was not working properly with the stand I had in mind so I merged it.





Must still add electronics in the CAD.
1/19/2026 2:30 PM - Finished the schematics
I just finished the schematics. A lot of work went into it since I first had to figure out how to do it. (I've never done it before) Did it on Fritzing. Works like a dream.
Did it wrong the first time and had to start again.

This diagram is quite small. I don't know how to show it to you more clearly.
Now all that is left is the BOM, adding electronics to CAD model, coding software, creating readme file and setting up Github. (I don't know how to work with GitHub, so I'll have to figure that out still)
1/19/2026 5 PM - Finished the BOM
I just finished the BOM. This project came out to be a bit more expensive than I thought it would be.
I don't know if they will approve it, but I sure hope so.
I really want to see this idea come to life.

I also made a mistake on my schematic diagram, but it was an easy and quick fix.
1/21/2026 4:11 PM - Finish small details
I forgot to add the electronics to the CAD model.
The models were all found on GrabCAD.com. Amazing website.
I couldn't find any 3D models of the 12v to 5v Buck converter (xy-3606) that I wanted to use so I had to skip that.
But after adding everything and making some holder for them, since they can't just sit there freely, it came out looking quite nice.
I also had to add the limit switches to the CAD model as well as the schematics diagram, since I also forgot about that.


This is the holder for the tb6600 stepper drivers. They are a bit larger than I thought they would be.

The software was something that I was avoiding for a while now since it is such a hard thing to do without being able to test the code. But I start with it so long.
1/21/2026 4:19 PM - Setting up for Submission
After figuring out what I wanted to achieve with the software I finished with a basic script to test if everything would work by playing happy birthday on the guitar. I don't know if it will work since I had no way of testing it.
The script was written in the Arduino IDE.
Before I could submit I first still had to upload everything to my GitHub. I have never used GitHub before and I really didn't know what I was doing, but ChatGPT was a life saver here.
I got everything uploaded and ready for submission. I also wrote my ReadMe.

Just for one last time, here are some images of the complete CAD model:



1/27/2026 - Fixing errors
I got feedback to remove 3D printer filament and get the table format correct by my BOM.
Only after changing the comma to a full stop in excel was the error fixed.
Everything should be right now, I hope.

2/4/2026 - More bugs to fix...
I got more suggestions about what to fix before I can get the funds for it.
I uploaded all the different parts and made a demo video to show how it works. This should be everything now, hopefully.

2/15/2026 - Working on the code
Worked on some code to simulate the idea I have to sort and work with the guitar tabs.
Ended up not working perfectly, but somewhat. Gave me a good starting point.
Will be using fingerstyle GuitarPro (.gp5) files of the songs to get the tabs. It will then be converted and prepared to be used in with the arduino or raspberry pi. Yes, I am thinking of maybe switching to raspberry pi since it can actually store a textfile for the song data.
import guitarpro
import numpy as np
import pygame
import math
import time
import os
# -------------------------
# Audio Setup
# -------------------------
SAMPLE_RATE = 44100
VOLUME = 0.4
pygame.mixer.init(frequency=SAMPLE_RATE, size=-16, channels=1)
# Standard tuning (Hz)
STRING_TUNING = {
1: 329.63, # E4
2: 246.94, # B3
3: 196.00, # G3
4: 146.83, # D3
5: 110.00, # A2
6: 82.41 # E2
}
# -------------------------
# Sound Generation
# -------------------------
def plucked_string(frequency, duration):
t = np.linspace(0, duration, int(SAMPLE_RATE * duration), False)
# Rich harmonic tone
wave = (
np.sin(frequency * 2 * np.pi * t) +
0.5 * np.sin(2 * frequency * 2 * np.pi * t) +
0.25 * np.sin(3 * frequency * 2 * np.pi * t)
)
# Exponential decay envelope
envelope = np.exp(-4 * t)
wave *= envelope
# Normalize
mono_audio = wave * (32767 * VOLUME / np.max(np.abs(wave)))
mono_audio = mono_audio.astype(np.int16)
stereo_audio = np.column_stack((mono_audio, mono_audio))
return pygame.sndarray.make_sound(stereo_audio)
# -------------------------
# GP Playback
# -------------------------
def play_gp_file(filename, mode):
song = guitarpro.parse(filename)
tempo = song.tempo
seconds_per_beat = 60.0 / tempo
print(f"Tempo: {tempo} BPM")
if mode == 1:
# PLAY ALL TRACKS TOGETHER
for measure_index in range(len(song.tracks[0].measures)):
for track in song.tracks:
measure = track.measures[measure_index]
for voice in measure.voices:
for beat in voice.beats:
beat_duration = beat.duration.time / 960.0
duration_seconds = beat_duration * seconds_per_beat
for note in beat.notes:
string_number = note.string
fret = note.value
base_freq = STRING_TUNING[string_number]
freq = base_freq * (2 ** (fret / 12.0))
plucked_string(freq, duration_seconds).play()
time.sleep(duration_seconds)
else:
# PLAY TRACKS ONE AFTER ANOTHER
for track in song.tracks:
print(f"\nPlaying track: {track.name}")
for measure in track.measures:
for voice in measure.voices:
for beat in voice.beats:
beat_duration = beat.duration.time / 960.0
duration_seconds = beat_duration * seconds_per_beat
for note in beat.notes:
string_number = note.string
fret = note.value
base_freq = STRING_TUNING[string_number]
freq = base_freq * (2 ** (fret / 12.0))
plucked_string(freq, duration_seconds).play()
time.sleep(duration_seconds)
# -------------------------
# Run
# -------------------------
def choose_play_mode():
print("\nPlayback Mode:")
print("1. Play all instruments together")
print("2. Play instruments one after another")
choice = int(input("Select mode: "))
return choice
def choose_song():
folder = "songs"
files = [f for f in os.listdir(folder) if f.endswith((".gp3", ".gp4", ".gp5"))]
if not files:
print("No supported GP files found in songs folder.")
return None
print("\nAvailable Songs:")
for i, file in enumerate(files):
print(f"{i + 1}. {file}")
choice = int(input("\nSelect song number: "))
return os.path.join(folder, files[choice - 1])
if __name__ == "__main__":
selected_file = choose_song()
if selected_file:
mode = choose_play_mode()
play_gp_file(selected_file, mode)
String tuning to simulate the sound of a guitar.
2/17/2026 - Programming base structure
I have been brain storming about how this coding structure will work.
I will use a live timer and then match each note with the live timer to keep it in the right rhythm.
Some planning I did in class

import time
import threading
def run_timer():
# We use a shared start time so other functions can calculate elapsed time too
start_time = time.perf_counter()
while True:
elapsed_ms = (time.perf_counter() - start_time) * 1000
# \r keeps the print on one line; we add spaces to clear old text
print(f"Time: {elapsed_ms:.2f} ms ", end="\r")
time.sleep(0.01) # 10ms sleep is usually enough for display
def read_file():
song_array = []
try:
with open("tabs.txt", "r") as file:
cum_val = 0
for line in file:
parts = line.strip().split('|')
if len(parts) == 3:
duration = int(parts[2])
cum_val += duration
row = [int(parts[0]), int(parts[1]), duration, cum_val]
song_array.append(row)
return song_array
except FileNotFoundError:
print("Error: tabs.txt not found.")
return []
if __name__ == "__main__":
tabs_2d = read_file()
# --- START THREADING HERE ---
# We create a thread to run the timer function
timer_thread = threading.Thread(target=run_timer, daemon=True)
input("Press Enter to start the program and timer...")
timer_thread.start() # This starts the background loop
# ----------------------------
if tabs_2d:
# Note: I fixed the loop logic here (iterating through elements, not indices)
for note in tabs_2d:
print(f"\nProcessing Note: String {note[0]}, Fret {note[1]}")
time.sleep(note[2]/1000)
3/20/2026 9:25 PM - I received the parts!
The parts finally arrived from Temu.
I checked and everything was there. Thank you to BluePrint for actually holding up to their side of the deal.
Now it's time to print and build!
First I started with the gantry and how it will work. I had to make quite a few changes to the original design since I went from a 4 wheel system to a 3 wheel system.
I also really had some trouble with my 3D printer. It doesn't print the same tolerences and really frustrates me when you need a part that depends on .1mm tolerence. Hopefully after this project I will have enough tokens to get a new 3D printer!
I printer about 20 different designs for the wheels to roll smoothly over the rail. Very frustrating. But got it at the end. The dimentions and tightness of the wheels had to be changed the whole time. The bearing-fit tolerances was also a struggle. But at the end we got there and the gantry runs smooth enough.






3/20/2026 9:37 PM - Creating the actuator
Next in line was the actuator that will pull down on the string.
This is a bit harder when my printer can't print the correct tolerences so I had to get really specific and make sooo many prototypes.
This also had to be redesigned since I decided on using 2 linear bearings in stead of 1 for the rod pulling down to keep it straight. I started with seperate bodies. This worked better since I only had to print the one side if it didn't fit.
At first I designed it to not have a placement for the spring, but is neccessary, because else the spring sits too loosly.
Everything is held together with M3 screws and heated inserts. It works amazing. Although I kinda ordered too little. I will probably buy more later in the future.
This was a very excited checkpoint in this journey, because it was my first time holding a part of the project and seeing it work. Very excited!







3/20/2026 9:46 PM - Refining the gantry system
The gantry system I designed in the previous journal entry was too wide and thick. Had some unneccessary holes and space.
I decided to tweak the design to merge the gantry part and the linear-bearings-holder-housing. This was a ton of effort since I, AGAIN, messed up the tolerences due to my beautiful printer printing not the best. Don't get me wrong, I love the printer and it is an honor to have a printer.
But it broke me when the printer tangled itself on one of the prints and broke the whole filament holder. It threw the whole thing onto the floor. I picked it up fixed it best I can, and started a new print. Just to come back and see the heated bed burnt its own power supply cable. This is a common issue with the Anet A8's. I knew about it and it has happend to be me before, but it is still not nice when it happens. Had to restart that same print again.
At the end I got a working design, but the printing orientation was the next issue. My printer can't print supports without fusing them to the part and basically make it impossible to remove. I got some sort of way to get a decent print, but will have to sort something out for next time, because this is not working.
Sorry about all the complaints, I am really happy with my progress and the part is now almost ready to move on to the rail and stepper housing. (Very excited for this)
I the attachments you can see the thickness comparisons of the old one and the new ones.





4/11/2026 - Finished the designs holding guitar neck
I have been working through engineering study breaks and almost finished the guitar neck holder part.
First I accidentally designed it without fitting with the actual guitar I will be using. So some of the stepper motor hold part would interfere with the actual guitar. This is fixed now after a lot of grinding and head scratching.
These parts will have to be printed in halves because of their size and my printer capabilities.
I tried printing the first half today, but accidentally switched my printer off in the process while starting with some of the hardware code of the project. As you can imagine this was after 4 hours of printing. I was sooooo mad, frustrated and just down. Will try the print again tomorrow.
I also ordered some extra screws and heated inserts on my own budget since I initially ordered too little.



5/1/2026 3 PM - Printed and it's starting to take shape!
I 3d printed the guitar holder and it came out good. This was now after my failed print. (I accidentally switched the power off of the printer while printing)
I also 3d modeled some changes to the guitar head holder side as well as print that. It actually came out pretty good. I had to change the size of the DIN rail due to it being a bit longer than I anticipated. Very happy with the overall progress.



Through all this I was still on a mission to finish the gantry. After every print I find something that doesn't work. Was a very tedius and frustrating job. I think most of the things are tuned now. I will add some pictures of the wrong measurements and then the correct ones as well to show the difference. This is due to my printer tolerences that are massive. One day I will have a really good printer..




5/1/2026 4 PM - String picking and servo holder
The new screws and super glue I ordered had arrived, so I don't have to be worried about having too little screws anymore. I added the string picking mechanism hardware. It was a weird complex design, but it works. The design took quite a while to work with the guitar as well. It holds the 90g servos with a perfect offset for the strings.
The servos fitted perfectly first try into the print! (Very rare to happen)



Next I wanted to print a single housing to test the servo for pulling the fretter down. I modified my design. The print thankfully went smooth and the servo fitted. I didn't like how the servo just sat loosely in the housing, so I changed that by adding 2 screws. It isn't neccessary now, so I didn't have to print it, but for my next print it will have the updates.


5/2/2026 - Create baseplate for electronics
I wanted something to fix the elctronics to, to make it more stable and not let it accidentally break.
I made this baseplate, but I only put 2 supports per pcb, 4 would have been better. But it is too late now and the print took too long. But for now this will work.



The stepper drivers also needed an housing. I just made a structured brace where I atrach them with heated inserts. The heated inserts gave some problems, since it kept getting stuck to my soldering iron and then pulling out a whole blob of plastic. But I was able to manage and it turned out pretty decent.



Really happy with my progress. Currently busy printing the other half of the guitar neck part. (The one I accidentally switched the plug of)
5/3/2026 - Some hiccups
I cutted 1 new DIN rail. So for now I have 2 with the right length. I don't want to cut all of them at once. Cos I'm lazy.
I printed the left side, but due to my printing bed accidentally melting itself the print lifted itself off the bed. In my attempt to save the print. I superglued the print to the bed.
The print finished well and measurements wasn't off by too much due to the bending.

But after the print I had enough and decided to solder the bed's wires to itself, because the connector is not rated for the amount of amps the cable pulls. (Common Anet A8 problem)
The soldering took a while since my soldering iron is quite crap. I did buy a new one but don't know where it is.

After the soldering it took me ages to finally recalibrate the bed leveling, etc of the printer. But now when I print, the first layer is completely messed up and weird. But at least the bed is hot. You remember that I said that I superglued the part to my bed? Well turns out, the superglue cannot be removed then. I know nailpolishremover works, but I don't have any. So I am stuck...
Look at this horrible first layer. Wants to make me cry.

I also added some material to the bottom of the servo holder so that it doesn't damage the guitar. The other servo's were also added.


I assembled the first actual gantry that I might use in the final build. While I was assembling it, I noticed a few things:
Holes for heated inserts was too small
Screw heights were too big
These things were fixed in the 3d model on Fusion.
5/5/2026 - Tinkering with the build
I am almost completely done with the picking system. It still needs some adjusting with the picks itself. The sizing was wrong, but it should be a quick fix. For the picks I use an ice cream holder's plastick.
I made a video and everything how it is playing but it seems like blueprint doesn't allow to upload videos. Which makes sense.
Anyway, here is the code I used to tinker around. It kinda plays the intro to "Nothing else matters". But without being able to puch frets it sounds a bit bland.
Here is a short vid that shows some playing:
20260505_212739
#include <Wire.h>
#include <Adafruit_PWMServoDriver.h>
Adafruit_PWMServoDriver pwm = Adafruit_PWMServoDriver();
// Your calibrated values
int sideA[6] = {350, 350, 350, 350, 335, 365};
int sideB[6] = {400, 400, 400, 400, 385, 415};
int currentStates[6] = {0, 0, 0, 0, 0, 0};
void setup() {
Serial.begin(9600);
pwm.begin();
pwm.setPWMFreq(50);
for(int i = 0; i < 6; i++) {
pwm.setPWM(i, 0, sideA[i]);
}
Serial.println("Ready. Type 'm' for Metallica Intro, 's' for Strum.");
}
void loop() {
if (Serial.available() > 0) {
char input = Serial.read();
if (input == '\n' || input == '\r') return;
if (input == 's') {
executeStrum(20);
}
else if (input == 'm') {
playMetallica();
}
else if (input >= '0' && input <= '5') {
toggleString(input - '0');
}
}
}
void toggleString(int s) {
if (currentStates[s] == 0) {
pwm.setPWM(s, 0, sideB[s]);
currentStates[s] = 1;
} else {
pwm.setPWM(s, 0, sideA[s]);
currentStates[s] = 0;
}
}
void executeStrum(int speed) {
for (int i = 0; i < 6; i++) {
toggleString(i);
delay(speed);
}
}
// The Metallica "Nothing Else Matters" Sequence
void playMetallica() {
Serial.println("Playing Metallica...");
int notes[] = {0, 3, 4, 5, 4, 3}; // E, G, B, e, B, G
int timing[] = {333, 333, 333, 333, 333, 320}; // Delay after each note (ms)
for (int o = 0; o < 8; o++) {
for (int i = 0; i < 6; i++) {
toggleString(notes[i]);
delay(timing[i]);
}
}
}

5/8/2026 - More Progress
I ran a full fit test to see what fits and what doesn't. To just have a better idea of how everything fits together. The fretter (2) head didn't have the right measurements. I remeasured the fretter head and fixed it on the 3D model. This is now fixed I must just print. I must still make fretter head 1 and 3. (Outer string + inner string)



I remodelled the larger servo holder to accommodate all 6 servos. So far I just had a single holder for testing purposes. The full 6 version will be printed tomorrow.

The gantry system had a huge flaw that I have avoided the whole time even tho I knew about it. The fretter head was never constraint in the rotational axis. I finally fixed it by creating a slot in the housing and adding a pin to the rod and string connector. This was printer and tested and worked.



I redesigned the picks holders that fasten the picks to the servo's to make it more accessable and fit better. It is also now fastened by a screw, not just friction. The were also made shorter to give more way for the plastic of the pick to flex.


5/9/2026 - Closer and closer
First I started with the first final assemblies! Very exciting. I added the stepper motors to the stepper holders.
Then I added the limit switches and wired it up. Took FOREVER...


I 3d modelled + printed angles to lift the whole guitar 4 cm higher since the lowest DIN rail is too close to the ground the allow the gantry to move freely. The print did not work... The steppers ended up being too heavy and just made the whole thing tip. So new idea. BOX. I taped two boxes to the main support structures. Works like a champ. I know this sounds quick and simple. But you do not understand how long the print took to figure out and get the angles correct just for it not to work. So please appreciate my beautifull box idea.

I fixed the dimentions of the fretting finger. It was too long. And printed it. Lastly I made a simple rig for the pcb for the picking servos to sit on. It turned out well although my measurements were a bit off, but it will do.

5/11/2026 - Still prototyping...
I just changed some stuff. No major progress:
I superglued the rod and string together with the adapter I printed. This turned out not to work. The superglue just came off. Will still see how I will fix it.
Tested fretter2. Measurements was off. It was fixed and I also 3d modelled fretter3. They were printed together. Measured again. Fretter2 was now right, but fretter3 was wrong size. Adjustments was made and will be printed on the next print.
Test fitted small bearings in main holder. Worked like tested.

3D designed and made sure the big boy servo holders are ready. I also printed them. Then I added heated inserts for screws to holder the servos in. This actually came out supprisingly well.


I had some issues on putting the guitar in when the arm of the fretters was on. It was in the way. I added to the gantry shell 3d print a slot so that I can move it out of the way. Will still see how well this works. Hopefully it works.
