HomePage

About Me

My name is Karlo Koelewijn, a Medior developer with experience since 2018.
On my previous game-dev study on GLU (Grafish Lyceum Utrecht Niv. 4) i learned C#, PHP, and SQL.
I choose to Learn C++ for my advanced elective course because it looked interesting to learn a deeper language and how processors work.
I had a slight interest in micro-controllers before starting at Fontys, I also enjoy reading manga and don't find it strange when I catch myself reading through documentation of projects or libraries.
In my free time I also play game (solo and multiplayer) from multiple genres.
After learning some networking coding on GLU i got myself a raspberry pi and dove into the rabbit-hole known as a homelab, and currently have a few pi's and my own mail-server.

Click here for CV (update incoming)

how am i hosting this?

This website is hosted on a raspberry pi running a nginx docker image.
which is accessed through an reverse proxy on my VPS (virtual private server).

Skills

  • C
  • C++
  • CMake
  • Make
  • git
  • basic circuit design
  • autodesk
    • inventor
    • fusion 360
  • C#
  • php
  • Flutter

why no graphs here? because they rarely make sense


projects

Titles and images redirect to the project page
left and right arrow key to flip through the pages in order

Visual Studio TaskList Viewer Unity/C#

img

A Unity Tool for developers to keep track of todo-comments in their Unity project.
Editor tool for Unity 2018+

Reviews

Thank you! 5/5★
by kazNoTabi

An incredibly powerful tool! One of the best freebies! 5/5★
by HoloMikeyz

Thanks for usefull asset. 5/5★
by SooNice


guiBase Library (C++)

img library for creating cross-platform gui apps
using glfw and vulkan to render imgui
this allows the user to focus on making something without having to focus on specific platform or toolkit quirks

works on:

  • linux
  • windows
  • mac (untested as i don't own one)

stm32 cmsis car

cmsis-img

using a nucleo f303re and cmsis c++ code to drive a car.
it drives forward to keep a set distance from an obstacle.


Discord Bot C#

Bot Img
github page
Discord bot written in C# from scratch with the Discord.Net api


Game of Life console C++

img A C++ project displaying Conway’s Game of Life in the Console.


SerieList Editor

img Simple program to offline keep track of where you are in a series.
it can also pull info about the series from OMDB


Visual Studio TaskList Viewer

img unity asset store

A Unity Tool for developers to keep track of todo-comments in their Unity project.
works on both gameplay and Editor scripts, inside a custom Unity Editor window.

you can decide for yourself how you plan to use it, it works on both game-play scripts and editor scripts and won't be taken along when you make your build.

how to use

inside any .cs file inside the project.

//! (Important Comment, Will appear above all comments of that file)

//? (Question Comment, Appears underneath the //! and signifies a Question for yourself/others

//TODO (TODO comment, Appears underneath the //? and signifies a task or reminder)

reviews

kazNoTabi Thank you! 5/5★

previously, I was searching using the Grep, but with this asset, the hassle has been reduced.

HoloMikeyz An incredibly powerful tool! One of the best freebies! 5/5★

I have a lot of assets. This one assets is near the top of my list in terms of productivity.
All the TODO items you wrote in code are in a list for you to peruse.
This one tool has really brought the ability to focus on the task needed to ship code. Well done!

SooNice Thanks for usefull asset 5/5★

Really like it.

guiBase Library

img

git repo

I made this library to simplify making gui apps in c++.
it uses GLFW and dearImGui with vulkan rendering.
this allows the user to focus on making an application without having to worry about most cross-platform nicknacks.

the included example shows a working example of how to setup your cmake project, entrypoint and layers.
each layer is meant to be its own window, below is a minimal example.

class exampleLayer : public guiBase::Layer {
public:
    exampleLayer() = default;

public:
    // void onAttach() override {
    // }

    void onUpdate() override {
        if (ImGui::Begin("example")) {
            ImGui::Text("%s", "example text");
        }
        ImGui::End();
    }

    // void onDetach() override {
    // }

private:
};

I have been using this library for multiple personal projects and in combination with other libraries without issue

cmsis car

TLDR -> Source Code

My Nucleo car in C++ CMSIS

This project had the goal to drive the nucleo car with the following challenges.

using 2 servos (using pwm) pid controller (distance control) ultra sonic distance sensing (using i2c) MCP (manual control pannel) uart control

de intent behind this project is to learn CMSIS level programming on Arm Cortex cores. this was done as part of my HBO-ICT tech embedded systems developer. it continuously drives forward until it detects a obstacle with the distance sensor.

page-gif

class diagram

all diagrams can be found here (github also allows you to zoom in on each diagram)

classDiagram
  class CarSystem {
    <<active>>
    +CarSystem(osMessageQueueId_t id, IDistanceSensor& sensor, ManualControlPanel& MCP, MotorController& controller)
    +Setup() bool
    +Update()
    -osMessageQueueId_t queueId //distance queueId
    -SensorMsgData data
  }
  class MotorController {
    <<active>>
    +MotorController(osMessageQueueId_t id, uint8_t minDist, IMotor& leftMotor, IMotor& rightMotor, IFeedbackSensor& leftSense, IFeedbackSensor& rightSense)
    +Setup()
    +Loop()
    +SetSpeed(uint16_t speed)
    +SetDistance(uint8_t distance)
    -osMessageQueueId_t queueId
    -uint8_t minDetectDistance
    -IMotor* motorLeft
    -IMotor* motorRight
    -IFeedbackSensor* senseLeft
    -IFeedbackSensor* senseRight
    -Pid pid
  }
  class IMotor {
    +Setup() bool
    +IsReversed() bool
    +SetSpeed(int8_t value)
  }
  class ServoMotor {
    +ServoMotor(NucleoPin pinMotor, HardwareTimer& timer, uint8_t ccChannelNum, bool reversed)
    -NucleoPin motorInputPin
    -HardwareTimer tim
    -bool isReversed
    -uint8_t ccrChannel
    -uint8_t maxSetSpeed = 100
    -uint8_t servoIdleValue = 1500
  }
  class ManualControlPanel {
    <<active>>
    +ManualControlPanel(osMessageQueueId_t btnId, IButton& btn0, IButton& btn1)
    +Setup()
    +Loop()
    +SetPid(Pid& p)
    -HandleSelectedBtn(BtnMsgData data)
    -CallBtnAction(BtnMsgData data, IButton btn)
    -osMessageQueueId_t queueId
    -IButton but1
    -IButton but2
    -Pid* pid
  }
  class IBtnIRQ {
    +HandleIRQ()
    +SetupIrq()
  }
  class IButton {
    +shortPress() action
    +LongPress() action
  }
  class Button {
    +Button(NucleoPin inputPin, IRQn_Type irq, osMessageQueueId_t id, Action actionShort, Action actionLong)
    -NucleoPin btnPin
    -osMessageQueueId_t id
    -IRQn_Type irq
    -volatile bool triggered
    -volatile uint32_t startTime
    -volatile BtnMsgData data
    -Action shortPressCallback
    -Action longPressCallback
  }
  class IDistanceSensor {
    +GetDistance() uint8_t
  }
  class HC_SR04_DistSensor {
    +HC_SR04_DistSensor(NucleoPin& echo, NucleoPin& trigger, HardwareTimer tim)
    +Setup(uint32_t prescaler, uint32_t arrValue, uint32_t outputCCValue, const uint8_t outputChannel, const uint8_t inputChannel1, const uint8_t inputChannel2) bool
    -NucleoPin* echoPin
    -NucleoPin* triggerPin
    -HardwareTimer timer
  }
  class Pid {
    +PID(int16_t min, int16_t max, float kp = 8.1f, float ki = 10.71428571f, float kd = 1.5309f)
    +Calculate(float target, float lastTarget) int16_t
    +ResetValues() void
    +updateKP(float val) void
    +updateKI(float val) void
    +updateKD(float val) void
    +GetKP() float
    +GetKI() float
    +GetKD() float
    -int16_t min
    -int16_t max
    -float tau
    -int16_t error
    -int16_t prevError
    -int16_t prevMeasurement
    -float timeSec
    -float proportionalOut
    -float integratorOut
    -float differentiatorOut
    -float output
    -float kp
    -float ki
    -float kd
    -float defaultKp
    -float defaultKi
    -float defaultKd
  }
  class IFeedbackSensor {
    +Setup() bool
    +Update()
    +GetSpeed() float
  }
  class FeedbackSensor {
    +FeedbackSensor(NucleoPin& inputSignal, HardwareTimer timer)
    -CalcDeg(int32_t curDuty) int32_t
    -CalcRpm(float delta, int32_t time) float
    -NucleoPin InputSignalPin
    -float speed
    -float delta
    -uint32_t curTime
    -uint32_t curDuty
    -uint32_t angleCur
    -uint32_t angleLast
  }
  class PinMode {
    <<enum>>
    digital_input
    digital_input_pullup
    digital_output
    altMode
  }
  class NucleoPin {
    +NucleoPin(GpioTypedef* block, uint8_t pinNr, PinMode mode)
    +NucleoPin(GPIO_TypeDef* block, uint8_t pinNr, AltModeValue val)
    +SetAltMode(AltModeValue value)
    +Setup() bool
    +Write()
    +Read() bool
    +GetPinNr() uint8_t
    +GetPinBlock() GPIO_TypeDef*
    -GpioTypedef block
    -uint8_t pin
    -PinMode mode
  }
  class AltModeValue {
    uint64_t value;
    uint32_t low;
    uint32_t high;
  }
  class HardwareTimer {
    +HardwareTimer(TIM_TypeDef* timer);
    +Init(uint32_t prescaler, uint32_t arrValue, uint32_t outputCCValue, const uint8_t outputChannel, const uint8_t inputChannel1, const uint8_t inputChannel2) bool
    +SetTimerEnable() void
    +SetPrescaler(const uint8_t prescalerDivider) void
    +SetEnablePeripheralClock() void
    +SetEnableCCModex(const uint8_t channel, const uint8_t ccxs, const uint8_t ocxm) void
    +SetEnableCCx(const uint8_t channel, const uint8_t ccxe, const uint8_t ccxp, const uint8_t ccxnp) void
    +SetCCRxRegister(const uint32_t CCRvalue, const uint8_t registerNo) void
    +SetAutoReload(const uint32_t ARRvalue) void
    +SetSlaveModeResetFP1() void
    +GetCaptureCompareRegister1() uint32_t
    +GetCaptureCompareRegister2() uint32_t
    +GetCaptureCompareRegister3() uint32_t
    +GetCaptureCompareRegister4() uint32_t
    +GetTimerCount() uint32_t
    -TIM_TypeDef* timer;
  }
  class BtnMsgData {
    +int butNr
    +int duration
  }
  class SensorMsgData {
    +uint8_t distance
  }

  ManualControlPanel o-- BtnMsgData
  BtnMsgData --o Button
  CarSystem o-- MotorController
  NucleoPin o-- AltModeValue
  CarSystem o-- ManualControlPanel
  ManualControlPanel o-- "2" IButton
  IBtnIRQ <|.. IButton
  IButton <|.. Button
  CarSystem o-- SensorMsgData
  MotorController o-- "2" IMotor
  MotorController o-- "2" IFeedbackSensor
  MotorController o-- Pid
  MotorController o-- SensorMsgData
  IMotor <|.. ServoMotor
  CarSystem o-- IDistanceSensor
  IDistanceSensor <|.. HC_SR04_DistSensor
  IFeedbackSensor <|.. FeedbackSensor
  HC_SR04_DistSensor o-- NucleoPin
  FeedbackSensor o-- NucleoPin
  ServoMotor o-- NucleoPin
  Button o-- NucleoPin
  NucleoPin o-- PinMode
  FeedbackSensor o-- HardwareTimer
  HC_SR04_DistSensor o-- HardwareTimer
  ServoMotor o-- HardwareTimer

Discord Bot C#

img

I got curious how bots worked in discord so i made my own using the Discord.Net api and a C# console window.
It has a few simple and some other more complex commands, It was a bit of a challenge to decipher the api but after some careful reading i got it to work.

Seeing it has been a few years since i last looked at the code, it is currently not working due to discord having updated their API.

git page

Bot Commands

  • No
    • tell the bot no, it responds with awh.

  • Wisper
    • resend the message after the command as the bot.

helpModule

  • H
    • prints a help message explaining how to use a command.

    • help-img

voiceChatModule

  • All
    • prints a list of all users in all voice-chats in the discord server

  • Status
    • prints a list of every user in the voice-call the user is in.

diceRollModule

  • Roll
    • dnd dice roller. roll a n sided dice: d20

    • dnd dice roller. roll a n sided dice m number of times: 3d6

Game of Life Console

img

To long didn’t read -> Source Code

This project was a throwaway at first until a friend told me to upload it to my portfolio to show my capabilities in C++ after a few weeks of learning the language.
I kept this as simple as I could, considering I didn’t plan to show it off in the first place and was trying to get it to work.
I used a frame buffer technique I saw on YouTube by Javidx9 using the ‘Windows.h’ and the WriteConsoleOutputCharacter macro.

Below are screenshots of a run

frame 2 img-f2

frame 3 img-f3

SerieList Editor

cover img

A utility program for keeping track of where you are with your series offline. while being fully offline it does offer OMDb info pages that do require web access.

offline

offline-img
Using a JSON file it keeps track of all the data. you can type in the title, select which season and episode you are in with a simple dropdown menu and you can leave a note for yourself typing in where you were in the episode or even what you thought of it.

online

online-img
When you click the “Display Online Info button” (assuming you don’t have a typo in the title field) it opens a new window that displays the poster, title, description, age rating, type (series/movie), amount of seasons, IMDB rating and the description. You can press the button on the bottom of the Online window to open its IMDB page.

TODO