Recent posts
CNC machining / laser cutting setup on the SnapMaker 2.0
I recently got a SnapMaker 2.0 A350T and I love it. I always forget how to set up the machine for CNC machining and laser cutting, so here goes… CNC machines have two different coordinate systems, which have the same orientation, but different origins: Machine coordinates: These are the physical / machine coordinates of the…
Diamondback Mission 1C / 2C tips / hacks
Recently I’ve rediscovered mountain-biking and bought a used Diamondback 2019 Mission 1C. I love the bike so far and will document some hacks / improvements I’ve done on that bike (and possibly others) here. Cable clipsDerailleur hanger / dropout replacementLevel Link bearing / frame protector Cable clips This is pretty general. I’ve designed some 3D-printed…
Building you own Kodi-flavored Ubuntu Desktop with Cubic
I was experimenting with my HTPC setup and was looking for a “one-click-install” Kodi distribution for x86 PCs. …But there was only one… WTF?! Though Libreelec is looking good, at this point it is just not “there” in terms of availability of packages etc. and it was in beta. I wanted a snapcast server for…
Simple Game Boy Advance micro USB / USB-C Li-ion battery power supply aka the “CheapJuice”
Don’t be mistaken, the CleanJuice v1.1 or Retro Modding Rechargeable Battery Pack Game Boy Advance USB-C power supply are well-thought-out solutions. They’re almost “drop-in”, need minimal modifications to the GBA and keep the battery compartment intact so you can still use AAs. But they’re also relatively expensive, especially if you don’t live in the US.…
Installing the Linux Nvidia driver in secure boot mode / Manually enrolling a platform key in BIOS
My Asrock Fatal1ty X470 AC BIOS is broken or does not work correctly in conjunction with my Nvidia GTX 1660 Ti, as I can’t see the screen to enroll a platform key. This is necessary if you want to install e.g. the proprietary Nvidia driver with secure boot on. I read some threads here, here…
Coreboot for the Lenovo T420 / T420i with Ivy Bridge support
Usually I tend to decline offers for old laptops, because I have too many projects anyway, but when a friend offered me a broken T420, I thought “Hmm, good opportunity to try out Coreboot…”. Because, why not?! The laptop The device arrived in a sad state: It was dirty, had old stickers on it, its…
All posts
- CNC machining / laser cutting setup on the SnapMaker 2.0I recently got a SnapMaker 2.0 A350T and I love it. I always forget how to set up the machine for CNC machining and laser cutting, so here goes… CNC machines have two different coordinate systems, which have the same orientation, but different origins: Machine coordinates: These are the physicalContinue reading “CNC machining / laser cutting setup on the SnapMaker 2.0”
- Diamondback Mission 1C / 2C tips / hacksRecently I’ve rediscovered mountain-biking and bought a used Diamondback 2019 Mission 1C. I love the bike so far and will document some hacks / improvements I’ve done on that bike (and possibly others) here. Cable clips Derailleur hanger / dropout replacement Level Link bearing / frame protector Cable clips ThisContinue reading “Diamondback Mission 1C / 2C tips / hacks”
- Building you own Kodi-flavored Ubuntu Desktop with CubicI was experimenting with my HTPC setup and was looking for a “one-click-install” Kodi distribution for x86 PCs. …But there was only one… WTF?! Though Libreelec is looking good, at this point it is just not “there” in terms of availability of packages etc. and it was in beta. IContinue reading “Building you own Kodi-flavored Ubuntu Desktop with Cubic”
- Simple Game Boy Advance micro USB / USB-C Li-ion battery power supply aka the “CheapJuice”Don’t be mistaken, the CleanJuice v1.1 or Retro Modding Rechargeable Battery Pack Game Boy Advance USB-C power supply are well-thought-out solutions. They’re almost “drop-in”, need minimal modifications to the GBA and keep the battery compartment intact so you can still use AAs. But they’re also relatively expensive, especially if youContinue reading “Simple Game Boy Advance micro USB / USB-C Li-ion battery power supply aka the “CheapJuice””
- Installing the Linux Nvidia driver in secure boot mode / Manually enrolling a platform key in BIOSMy Asrock Fatal1ty X470 AC BIOS is broken or does not work correctly in conjunction with my Nvidia GTX 1660 Ti, as I can’t see the screen to enroll a platform key. This is necessary if you want to install e.g. the proprietary Nvidia driver with secure boot on. IContinue reading “Installing the Linux Nvidia driver in secure boot mode / Manually enrolling a platform key in BIOS”
- Coreboot for the Lenovo T420 / T420i with Ivy Bridge supportUsually I tend to decline offers for old laptops, because I have too many projects anyway, but when a friend offered me a broken T420, I thought “Hmm, good opportunity to try out Coreboot…”. Because, why not?! The laptop The device arrived in a sad state: It was dirty, hadContinue reading “Coreboot for the Lenovo T420 / T420i with Ivy Bridge support”
- Properly (passive) cooling the Toshiba Z20t-C / the Intel m7-6Y75The Toshiba Z20t-C is a really nice, silent convertible with a long battery runtime. It’s CPU is held back though by cooling issues. The Intel m7-6Y75 performs especially bad, running even slower than its cheaper m5-6Y57 / m5-6Y54 counterparts due to cooling. Though the CPU could clock at 2.9 GHzContinue reading “Properly (passive) cooling the Toshiba Z20t-C / the Intel m7-6Y75”
- Using a 24C256 / 24LC256 EEPROM on Raspberry Pi with device overlaysFor my HappyPlayer project I needed non-volatile storage for some settings, but I wanted to make the RPIs SD card read-only to prevent data-loss or file system corruption in case of power loss of the whole device. So I used an EEPROM (Atmel 24C256) to store the settings in regularContinue reading “Using a 24C256 / 24LC256 EEPROM on Raspberry Pi with device overlays”
- Compiling SDL2 / image / mixer / ttf for the Raspberry Pi without X11If you want accelerated SDL2 graphics when on the console, e.g. on Raspbian Lite you don’t want to use X11. You could get away with just installing SDL2 from the repository, but my SDL2 version had problems regarding touch screens, so I needed to recompile. Also if you install anyContinue reading “Compiling SDL2 / image / mixer / ttf for the Raspberry Pi without X11”
- Use a rotary encoder and button on Raspberry Pi with device overlaysFor my HappyPlayer project I needed to control the audio volume using a rotary encoder and GPIOs. I used device tree overlays for this. The encoder used is a standard type with an additional momentary switch when you press it. It needs 4 pins: Common GND -> Pi GND MomentaryContinue reading “Use a rotary encoder and button on Raspberry Pi with device overlays”
- (My personal) git cheat sheetCreate a repository from existing code and push it to remote Change into your code sub-directory and do: git init git add . git commit -m “First commit” git remote add origin https://REMOTE_HOST/REPO_NAME.git git push -u origin master Change a repositories origin remote url This is useful if you haveContinue reading “(My personal) git cheat sheet”
- Overclocking the Raspberry Pi Zero / Zero 2As my OctoPi installation was a bit slow on my RPi Zero I wanted to try overclocking it. I found a lot of different reports about overclockability and temperature, so I did some measurements myself. Make sure your CPU governor is set correctly Otherwise you CPU will not clock toContinue reading “Overclocking the Raspberry Pi Zero / Zero 2”
- Booting up OctoPi fast(er)OctoPrint is awesome, but especially if you use a Rasperry Pi 0 you want to make it boot up as quickly as possible. Here’s what you can do. I compiled this from different sources on the internet, e.g. this. Warning: Make sure you have OctoPrint up and running and makeContinue reading “Booting up OctoPi fast(er)”
- Overclocking SD cards on the Raspberry PiWarning: Overclocking SD cards can corrupt your data and possibly damage your SD card! If you want better SD card speed and have an UHS-1/3-capable SD card, you can make the Pi run it with more than the standard of 50 Mhz. I tried this with a Rasperry Pi 0Continue reading “Overclocking SD cards on the Raspberry Pi”
- Running GUI applications over SSH on a Raspberry PiSometimes you have a RPi attached to a screen, but no keyboard or mouse attached and want to run GUI applications on it via SSH. This will also let you cross-compile RPi applications on a development machine and test them on the real machine. Prepare the RPi for ssh accessContinue reading “Running GUI applications over SSH on a Raspberry Pi”
- Signing your kernel modules on Ubuntu 16.04I have an Asus UX3410UA laptop. To silence the fan I use ACPI calls to adjust the fan tipping point. See this. This needs the kernel module “acpi-call-dkms” for being able to run the “acpi_call” executable. If secure boot is enabled on a computer this module will not load ifContinue reading “Signing your kernel modules on Ubuntu 16.04”
- Compiling Android x86 5.1.1 from sourceI had this Medion Lifetab P8314(.2) tablet and kernel sources from the vendor and wanted to compile Android x86 5.1.1 64Bit for it. Compiling Android x86 is described in detail here, but there are some caveats, so I’ll noodle it all down here from the beginning. Note that I useContinue reading “Compiling Android x86 5.1.1 from source”
- Setting up a Qt 5 CMake project for Visual Studio and LinuxCMake is cool, Qt is cool. Both together not so, if you don’t know what you’re doing. This describes how to build a Qt project CMakeLists.txt so everything works and how to run / debug your application in Linux and Visual Studio. Make sure to additionally check out the Qt5Continue reading “Setting up a Qt 5 CMake project for Visual Studio and Linux”
- Building and installing the MP4 / M4A / AAC plugin for Mixxx 2.0 / 2.1 on UbuntuThis is a pita. You’ve installed and set up Mixxx, but your .m4a files are not shown in the library. You need to compile Mixxx from source, but it is fast to do so. Here’s how. I tested this on Ubuntu 16.04.02 LTS 64bit and it will build Mixxx 2.0Continue reading “Building and installing the MP4 / M4A / AAC plugin for Mixxx 2.0 / 2.1 on Ubuntu”
- Stream hardware-encoded H.264 video from a Raspberry Pi to a web page using WebRTCI use the wonderful 3D printing distribution OctoPi (which in turn uses OctoPrint) on a Raspberry Pi Zero to start and monitor my 3D prints. It has built-in webcam functionality, which means you can monitor your printer and see in the web interface if the print is going well orContinue reading “Stream hardware-encoded H.264 video from a Raspberry Pi to a web page using WebRTC”
- Setting up the XYZ Da Vinci 1.0A 3D printer with RepetierHost and Slic3r on UbuntuI finally bought a 3D printer. It’s a used one and entry level, but printing parts is good fun. Here’s how to set it up on Ubuntu 14.04: Install Repetier firmware The new firmware will give you much more control over the printing process. Mine was already installed (v0.92), soContinue reading “Setting up the XYZ Da Vinci 1.0A 3D printer with RepetierHost and Slic3r on Ubuntu”
- Hiding the mouse cursor in KodiI use Kodi with a touchscreen and wanted to hide the mouse cursor, but NOT disable mouse input. This can be done by using a 1×1 transparent PNG file as the mouse cursor. Find out what skin you’re using and where your skin directory is. For me this is “estouchy”Continue reading “Hiding the mouse cursor in Kodi”
- Properly setting up a 5″ HDMI touchscreen for Kodi on RaspbianWow. This was a royal pita. I wanted to build this wake-up-light-alarm-clock-media-thingy for my girlfriend. Well, I got my hands on a RPi Zero and needed an LCD display. I found this nice-looking “WaveShare 4″ IPS display” on Ebay and spent days trying to get it to work properly. YouContinue reading “Properly setting up a 5″ HDMI touchscreen for Kodi on Raspbian”
- Adding backlight control to a 5″ HDMI screen (and Kodi)So the screen from here is working in Kodi now (LCD datasheet / pinout), but it draws a lot of power when the backlight is on (~200mA extra). We want to turn at least the backlight off, leaving the touchscreen active so we can interact and wake it up again.Continue reading “Adding backlight control to a 5″ HDMI screen (and Kodi)”
- Building a mobile magnet lamp / flashlight from repurposed partsI needed a mobile “flashlight” in my car you could simple attach somewhere to the chassis where you’d need it. The are plenty of offers on the interwebs, so could have simply bought one, but I (as usual) had some parts lying around…I had: A spare 12Wh Li-Ion battery leftContinue reading “Building a mobile magnet lamp / flashlight from repurposed parts”
- Building a Kodi in-car entertainment system using a Motorola Atrix Lapdock and an Odroid C0Watching movies in the car is great fun. It is even better when you have a camper and lie in your comfy sleeping bag – I needed an in-car entertainment system.I have a stereo in the car already that can even play videos, but the screen is small, codec supportContinue reading “Building a Kodi in-car entertainment system using a Motorola Atrix Lapdock and an Odroid C0”
- Using the Easybox 803A (Arcadyan ARV752DPW22) with OpenWRT 14.07 / 15.05The Vodafone Easybox 803A has nice router hardware. I found one on the trash recently and decided to put OpenWRT on it. Here’s how. This is based on the instructions found in the OpenWRT wiki, the OpenWRT forum and random bits on the net. UPDATE 2: I have updated theContinue reading “Using the Easybox 803A (Arcadyan ARV752DPW22) with OpenWRT 14.07 / 15.05”
- Useful Linux scripts for standalone systems, emulators, HTPCs etc.Booting the system to console with grub2 Edit the file /etc/default/grub: Change the line GRUB_CMDLINE_LINUX_DEFAULT to include “text”: Save the file and update grub: Note that on systemd systems this might not be enough. Switch to text mode using this: You can switch back to graphical mode using “graphical.target”.Now reboot.Continue reading “Useful Linux scripts for standalone systems, emulators, HTPCs etc.”
- Decompose the OpenGL projection matrixSometimes you need to decompose the OpenGL projection matrix into its original components to adjust some values. Here’s how to do that. I found a thread on stackoverflow on the subject. The formulas there are in row-major format though, but OpenGL is column-major, so they need to be swapped around:Continue reading “Decompose the OpenGL projection matrix”
- Useful Linux scripts etc.A better find I keep using the find command in Unix as such: “find / -name SOMETHING” (Yes, I know there’s locate, too). You always get an error message when you hit a directory you don’t have permissions for, but I usually don’t care about those directories anyway, so itContinue reading “Useful Linux scripts etc.”
- Useful CMake functionsCMake is a great tool, but I always keep searching on how to do this and that. Time to make a list again… Checking the G++ compiler version: Appending entries to a list: Creating filters in Visual Studio projects: Custom install commands To print a message during the install processContinue reading “Useful CMake functions”
- Useful C++ tricks and helper functionsMy brain sucks. It can remember the lyrics to songs or the power draw of a electronic component, but I keep forgetting those simple, useful helper functions you sometimes need. This sends me off Google again, searching through excellent sites like StackOverflow etc. Time to make a list… Remove charactersContinue reading “Useful C++ tricks and helper functions”
- tl;dr – Reviving an Acer Aspire 3820 TG with a broken BIOS chipMan, was I screwed. I had this awesome laptop with a diy keyboard backlight and then it died on me just after the (already voided) warranty had expired and new mainboards were ~200€…It all started when I noticed that my ATI Radeon 5650M GPU had vanished in Windows, so IContinue reading “tl;dr – Reviving an Acer Aspire 3820 TG with a broken BIOS chip”
- Installing and switching gcc/g++ versions in DebianInstalling newer gcc/g++ versions is easy: If your system does not provide the new versions, you might still be able to get them via a different repository. Add the toolchain repository to your system and update your sources: Now you should be able to install gcc/g++. The real problem comesContinue reading “Installing and switching gcc/g++ versions in Debian”
- Raspberry Pi setup / configuration stuffI keep forgetting the stuff and always start over when I have to reformat or the SD card breaks, so here’s a collection of useful tidbits when setting up and configuring a Pi. I’ll expand this page whenever new stuff pops up… Adding a root password When you try toContinue reading “Raspberry Pi setup / configuration stuff”
- Arduino Leonardo as a MAME interfaceUPDATE: I made the thing a project on GitHub. You can find information and can download the source code for the Arduino and PC programs from the project page. Ok. So I found this old arcade cabinet for 1,50€ 😀 on Ebay and managed to carry it up the stairs.Continue reading “Arduino Leonardo as a MAME interface”
- Reading the OpenGL backbuffer to system memorySometimes you are in the need to read back the OpenGL backbuffer, or other framebuffers. In my case the question was how to read back a downsampled framebuffer resp. its texture to system memory. There are different methods for this and I wrote a small benchmark to test them onContinue reading “Reading the OpenGL backbuffer to system memory”
- Using an USB joystick or gamepad in XBMC on UbuntuNow I have those cheap USB gamepads, XBMC running, the ROM collection browser addon and MAME all set up. Awesome! But why can’t I navigate XBMC with my joystick to select games and adjust the volume etc?! Here’s how to solve that problem… 1. Prequisites First of all you needContinue reading “Using an USB joystick or gamepad in XBMC on Ubuntu”
- Calculate Catmull-Rom splines using forward differencing – UPDATEI finally had the time to finish this post by whipping up a small JavaScript canvas example to show forward differencing in action. Not much to see there, actually, other than that the regularly drawn spline and the one drawn with forward differencing look the same. Here’s the part ofContinue reading “Calculate Catmull-Rom splines using forward differencing – UPDATE”
- Setting up an Arduino + LPD8806 ambilight using boblight with XBMC on UbuntuAn Ambilight is a great thing – if it works. I want to write about some of the hoops I had to jump through to make it work. This is very Linux-specific, but you might take away something for other configurations too… Here is the original adalight tutorial, which IContinue reading “Setting up an Arduino + LPD8806 ambilight using boblight with XBMC on Ubuntu”
- Adding a “proper” keyboard backlight to an Acer Aspire 3820TG notebookThis thing started long ago when I got the laptop. I love it, but it really lacks a backlit keyboard. There was one excellent thread with people presenting solutions (add tiny switches, soldering to the bluetooth connector, to the USB breakout board etc.), but I found none of them reallyContinue reading “Adding a “proper” keyboard backlight to an Acer Aspire 3820TG notebook”
- Calculate Catmull-Rom splines using forward differencingUpdate: Here’s a little JavaScript canvas example to give you some sourcecode… Splines are a nice for interpolation of all kinds of stuff. A very nice, thorough (Bezier) spline documentation with lots of examples can be found here.Catmull-Rom splines are handy, because they always pass through their control points. NoContinue reading “Calculate Catmull-Rom splines using forward differencing”
- A little canvas experimentHere’s some base code for simple canvas animations: When you put this into a HTML file and load it in your browser it should look like this.
- Using CriticalSections to synchronize shared resource accessWhen developing multi-threaded applications you can never be sure when and in which order threads run, so you have to synchronize access to shared resources. Otherwise, for example, one thread could modify a piece of data while another thread reads or modifies it. This can give you inconsistent data or,Continue reading “Using CriticalSections to synchronize shared resource access”
- Writing a DLL containing C++ classesPutting functions into a DLL is a good thing. It helps you to reuse stuff, save space on updates, save build time etc. To write a DLL the proper way you have to keep some things in mind though. Those hints are basically the “best-practice” from this page. A DLLContinue reading “Writing a DLL containing C++ classes”
- Using FrameBufferObjects in shadersUsing FrameBufferObjects in shaders would go something like this: Set up your FBO (see here). Render scene while writing values to gl_FragColor and gl_FragDepth (in our case). You could also have more draw buffers, then you could also write to gl_FragData[0-9]. Keep in mind, that values will be clamped toContinue reading “Using FrameBufferObjects in shaders”
- FrameBufferObjects in OpenGLFrameBufferObjects are basically off-screen frame buffers, similar to the regular frame buffer you are normally rendering to. Using FBOs in OpenGL you can do some nice stuff like post-processing or rendering to a texture. There’s a difference between: FrameBufferObjects: FBOs can be bound to / used as a texture, butContinue reading “FrameBufferObjects in OpenGL”
- Ease functionsEase functions are important for interpolation of just about anything. Popular functions are “smoothstep” or “ease in” and “ease out”. This images shows what they look like for x[0,1] and y[0,1]: There are other popular functions for ease in and ease out, e.g. y=sin(x*PI/2) resp. y=1-cos(x*PI/2).What is important about thoseContinue reading “Ease functions”
Categories
- android (1)
- diy (12)
- electronics (14)
- linux (24)
- mountain biking (1)
- programming (17)
- Uncategorized (2)