You are browsing as a guest. Sign up (or log in) to start making projects!

alessandro_09

@alessandro_09

Joined June 5th, 2026

  • 10Devlogs
  • 2Projects
  • 1Ships
  • 15Votes
Just some guy who loves programming and want to learn everything :3
Open comments for this post

3h 15m 26s logged

Day 7 - A lot of changes

And there we are! After about.. a week from the last devlog and I’ve made some changes since then!

Vectors! Yay!

Now the entire code uses vectors instead of arrays!

At first I used arrays cause it was the only thing I knew, but I read some guides about vectors and I refactored the entire code to use them instead!

After doing this, I can easily implement merge sort and quick sort!

Problems

While reworking the code, I had quite some problems with the selection sort and insertion sort since it crashed the program when I tried to sort the values.
I tried everything, but once I found the problems, I didn’t know how to fix them.
So unfortunately, I had to use ChatGPT to help me fix them since I really didn’t know how.

(Every change I made with AI it’s tagged with the prefix //AI: in the comments of the code.)

I didn’t want to use AI cause I want to learn these things by myself and without any help of AI, after all I’m still learning and I said at first that this project it’s just a way for me to practice.
But I guess it’s fine to get help from time to time, I just need to not do it often and try by myself first!

That’s all for this devlog and see you in another devlog!
(Yeah, the screenshot is the same as the previous one since I didn’t change anything graphically, lol)

0
0
2
Open comments for this post

1h 12m 40s logged

Day 6 - I don’t know what to put…

Hey there, this is going to be another quick devlog..
I usually post devlogs as I make commits so, everytime I commit something to the repo I make a devlog and say what I did, lol

Anyway.. there we go.

Statistics!!

Yayyy! I’ve finally added statistics!
So now, every time you finish sorting a range of values, it shows how many comparisons and swaps the algorithm performed and how many array accesses it made!
It wasn’t hard to implement but for now it works only for bubble sort and selection sort! (I was lazy and didn’t want to add it yesterday lol).
And still isn’t quite complete.. cause I don’t know for what reason but if I compare the statistics with a normal implementation of the algorithm, my Selection sort appears to do one cycle more than it needs too.. So I have to check that out.

Other things

After adding the statistics I just cleaned up some code, added some comments so people can actually understand what everything does and then added a quick button to show/hide the text under the rectangles with a limit. The limit is there so that you can still see the text of the rectangles without them overlapping on each other.

0
0
3
Open comments for this post

1h 25m 31s logged

Day 5 - New algorithm

Hey there and there we are in another devlog! This is going to be quite short but whatever.

New algorithm

I added a new algorithm, the Insertion sort!
I tested it multiple times and I managed to get it to work in about an hour.
Then, I even fixed a bug where sometimes a value would disappear.. (I didn’t put a “=” , lol)

What’s next?

Next thing is going to be to add simple stats about the algorithm. Like I said in the previous devlog it’s going to be:

  • Comparisons
  • Swaps
  • Array accesses

Another thing I’ll work on is to add a way to show/hide the actual value of a rectangle. It will have a limit, cause when you decide to widen the quantity of values, they don’t have enough space to see the text of the value clearly.

Next algorithms

I won’t focus on them for now since I already implemented some starting algorithms. I first want to polish some code (It’s going to be bad anyway) and add these little features first..

The reason? Well, I wanted to add Quick sort and Merge sort but they’re quite hard to create in the style I need.. and I noticed that they might need vectors to work.. and they haven’t teached me vectors at school…

So first, I need to understand how vectors work in C++, THEN I’ll add Merge sort and Quick sort (Or I’ll just ignore them and ship the project anyway. I’ll definitely add them after shipping though)

(Oh yeah, I also need to fix how the rectangle change color when the sorting is active. It’s a bit rough now.. I need to make it better.)

Anyway see you in another devlog and thank you!

0
0
3
Open comments for this post

4h 42m 14s logged

Day 4 - A lot of changes

So.. It’s been a while.. (again) Unfortunately I started doing other personal things and forgot about this project but I still kept doing small fixes. In fact, I had a 12 day streak but unfortunately I lost it lol. Anyway.. yesterday I finally locked in again and finished what I needed to do!

New algorithm!

I finally added the Selection sort algorithm! It was a bit harder compared to the bubble sort cause I had some problems while porting it in this new style. Another reason is because of all the refactoring I did of the main code that I’m just about to introduce! ## Splitting files! Like I said in the beginning, this project is a way for me to get better at coding, learn sorting algorithms and even learn new approaches into coding that I haven’t learned at school! For this reason, I decided to learn more about header files and how to split the code on multiple files instead of having just one big .cpp file! As of now, the structure look like this!

VisualSort/
├── images/
│   └── image1.png
├── src/
│   ├── algorithms/
│   │   ├── bubbleSort.h
│   │   └── selectionSort.h
│   ├── main.cpp
│   └── main.h
├── .gitignore
├── CMakeLists.txt
└── README.md

So now I have the main.h for all the variables needed for the sorting algorithms and the main GUI to function.
Then, I have a folder called algorithms where I have all the header files of the algorithms I implemented! (I know that I should make a .h and .cpp file and that the header is only for declaration but I didn’t want to add more files since it’s a simple project).

Speed slider!

Now, I even added a slider bar to let the user choose the speed of the sorting algorithm! The slider changes the seconds of the delay between every step of the algorithm and it goes from a minimum of 0.1 sec (fastest) and a maximum of 2.0 (slowest).

Next features…

After all of this I think I’m gonna add atleast 1 or 2 new algorithms, a box to show a quick description of the algorithm and then some stats about the like:

  • Array accesses
  • Comparisons performed
  • Swaps performed
    (Of course the data will be equal to a normal implementation of the algorithm and not according to my way of implementation.)

Something first..

If you ask why I took 4h 36min to implement ONLY these features it’s because I’m not really quick at coding and everytime I tried to implement the Selection sort I always had problems.. and other than that I even had to refactor all the code to divide it into files unfortunately.

Anyway, that’s all and see you in the next devlog! Hoping that it will be soon. If I lock in it should be tomorrow maybe or I don’t know. Before saying goodbye, here’s a quick screenshot of how the software looks now!

0
0
2
Open comments for this post

4h 24m 27s logged

Day 3 - Getting somewhere!

It’s been a while since my last devlog. Since then, I spent all the time working on the delay between each swap of rectangles. I know that it sounds silly but I really didn’t know how to do it.. But now, I managed to solve it and now it works!

What was the problem?

The problem was that, to start the sorting algorithm, I would press a button and it would call the sorting function. But.. once it starts, it does everything in ONE frame, instead of waiting for the delay I set.
So once I understood my mistake, I rewrote the algorithm in the exact same way but in a step-by-step style, without using any kind of loops.
Now, thanks to this new approach, I managed to add a delay between the swaps!
Thanks to this, I even managed to add a simple animation when the sorting is completed!

Next features

The next features that I’m working to add is:

  • More algorithms (of course), but to add them I wanna do something special.. Since this project is a way for me to learn to code better.. I’ll add the other algorithms and the bubble sort in other files and I’ll call the actual functions inside the main.cpp. So they’ll become something like libraries. This is a way to maintain the code clean and even a way for me to learn how to connect multiple files between them!
  • A display box to show a quick description of how the algorithm works and even the pros and cons! (I don’t know if I can but I’ll try).
  • A way to compare stats of the sorting algorithms
  • A slider to choose the speed of the sorting algorithm
    Then I don’t know.. I thought of something else but I forgot.. lol.

Anyway thanks for reading this new devlog and see you onto the next one!

Here’s finally a quick video demonstration of the software in function!

0
0
2
Open comments for this post

3h 8m 21s logged

Day 2 - GUI and the first algorithm

Hey there! This is the second devlog of my project. I wanted to make it yesterday but I was busy, lol.

Yayyy GUI!

Anyway, I started implementing a reallyyy rough (I mean really rough) draft of the GUI of the software!
Of course, since I’m using the Raylib library, for the GUI I’m using the Raygui library! It was a bit hard to understand at first because of all the types of GUI available, but thanks to the tools offered by raysan5 (aka the creator of Raylib), I managed to find what I needed!

(Raysan5 is the real goat, y’all should definitely check him out and all of his work. Especially the raylib library if you want to code a game in the most spartan and raw way possible! Trust me, it’s a real piece of art this library.)

Of course, once I’m satisfied of how the code is and after implementing all the features I had in mind, I’ll improve the GUI.
That’s mainly because I want to focus first on cleaning the code, optimize it, add the algoritms I want and every feature that I had in mind. Only by then I’ll work on the GUI again, as of now, the positions of the controls on screen are random cause I still need to test them after all!

First algorithm!

After talking about the GUI, let’s talk about algoritms!The first one I implemented it’s the bubble sort! Quite easy to implement and it works well! Next time, I’ll try to add something else but I doubt cause I still need to do some things first, then I’ll work on adding as many algoritms as possible.

I’m going crazy.

Of course, when the software starts sorting, I’d like to add some kind of delay to see the rectangles swap places… I though it was easy.. Well.. It isn’t. I spent 1h 30mins just to try and this damn delay and it still doesn’t work. It’s a pain. I hate this. But I should be close to get it right.. Or at least that’s what I hope..
And of course, I shall use no AI to help me in this task and suffer through it. I need to learn on how to overtake this difficulties, so NO Ai and just raw searching on Google, checking out other people’s codes to see if I can apply something to my case, check examples by raylib and the docs, reddit’s posts and anything else that is available, except AI.

Anyway, thanks for everything and see you in another devlog!

(Yes I know, the screenshot is still useless but once I add this damn delay I’ll try and a quick timelapse of the software working)

0
0
2
Open comments for this post

20m 27s logged

Day 1 - Starting!

The Idea

  • Hey y’all! I’m starting this new project about a C++ software that
    makes it able to visualize sorting algorithms! As of now, I don’t know
    how many algorithms I’ll add, but I’ll try to add as many algoritms as I
    can.

Why?

  • During this year of high school we started learning C++ and we even
    got a quick look at Sorting algorithms. I’ve always been curious about
    them and always wanted to learn more about it but, I couldn’t notice the
    fact that they were hard to understand, especially for my classmates.
    But after I helped them personally by making them visualize on paper how
    the algorithm worked, they seemed to understand better. So, I decided
    to make a software to visualize them automatically through software!

What I’ll use

  • To create this software I’ll use CLion as IDE and C++ as the
    programming language. To make the GUI and everything I’ll use the Raylib
    library! It’s a really nice library that I started learning some time
    ago. I started by remaking Pong by myself without any help and now, I
    wanted to step up a bit and use it in a more complicated project!

See you!

This was pretty much everything. I already started writing some code but
it isn’t much. I just made the basics and they already need some fixing. This is a quick screenshot of the project as of now. I’ll definitely fix it up tomorrow. Anyway, thanks for
everything and see you in another Devlog!

0
0
3
Ship Pending review

I made my very own hackpad! By reviewing the provided guides and searching through the Internet, I managed to customize it a bit more too without copying the example made from the guide! I had various challenges since I never did 3D Modeling with Fusion 360 and never made a schematic and a PCB in my life. But thanks to this project I learned how to do it and I even liked it really much so I'll probably explore Hardware making further!
I'm really proud of the work I did and I hope to be able to build it physically as soon as possible so I can use it and even improve it further! One thing that I'm not so sure about is the firmware cause the documentation was pretty hard to follow.. But it should be good enough to work! Thanks for everything you do and for taking the time to review my project!

Video of Project → See source code →
Open comments for this post

2h 27m 35s logged

Day #3 Creating the firmware and adding the last files

I finally managed to export the case as .step files and loaded them onto the GitHub Repo!
Then, I started working on the firmware and was able to complete it!
I’m not sure that it works cause it was pretty hard to understand but in the end I managed at least to do something!
(Once I’m sure that everything is working I’ll probably add VIA support).

Then, I fixed somethings on the PCB cause I noticed that to use the button of the Encoder I had to wire it to the switch matrix, so I went into KiCad, added another column to the matrix and re-wired everything!

Anyway, this is probably the last Devlog for this project since I made everything I had to do.
So, thank you for everything and see you in another project!

0
0
4
Open comments for this post

4h 59m 21s logged

Day #2 Creating the case

I finally created the case for my Hackpad! It was probably the hardest thing ever, especially as someone who has never used Fusion 360 before. And honestly, I hate it pretty much. I even tried to export the 3D model as a .step file but it just keep crashing over and over.
Anyway, other than that I:

  • Added more cats onto the PCB as decoration
  • Adjusted and fixed some things on the schematic
  • Adjusted and re-routed every track on the PCB

It was a rough day because of Fusion 360 that kept crashing.. But whatever, see you in another devlog!

0
0
4
Open comments for this post

2h 49m 25s logged

Day #1 Creating the schematic and the PCB

I’m making my very first macropad from scratch!

Since this was my first time creating a schematic and routing a PCB, it was a bit chaotic but I managed to get it done at the end!

It wasn’t that hard actually, especially thanks to the guides given by the Hack Club!

What I did today:

  • Created the schematic and then routed all the wires on the PCB.
  • Loaded the 3D models of the various footprints
    -Decorated the PCB with some silly cats (I love them)
  • Created a GitHub repository with all the files and made the first commit
  • Started writing the readme file. It’s still incomplete and I’ll modify it while I continue the project.

That was all and see you all in another Devlog!

0
0
5

Followers

Loading…