Friday, April 19, 2024

DIY In-Car Infotainment with Raspberry Pi and Kodi

Build your own in-car entertainment system — individual touch displays for each passenger, streaming multimedia over a local network with no internet required. Using off-the-shelf hardware and open-source software, each screen costs around $180–$200.

Last updated: February 7, 2026

What's New (Feb 2026)

  • Pre-built SD card image — Download, flash, and boot. No manual installation needed. Download here (~1.2GB)
  • Rock-solid sync — Integrated kodisync for frame-accurate synchronization. Now achieves sub-10ms sync spread (vs. multiple attempts needed before)
  • Auto-negotiation — No more manual master/slave configuration. Each Pi generates a unique hostname from its MAC address and devices auto-discover each other
  • One image for all — Flash the same image to all SD cards. No per-device configuration required
Detailed wiring diagram for DIY in-car infotainment system with PoE switch, pocket router, and Raspberry Pi screens

Complete wiring diagram: PoE switch powers each Raspberry Pi + touch screen over a single Ethernet cable.

How it works

The system uses a distributed architecture — no central multi-head controller needed. Each passenger screen is an independent Raspberry Pi 4 running Kodi, powered and networked through a single Ethernet cable via Power over Ethernet (PoE). A pocket router acts as the DLNA/DHCP server, serving media files from a USB drive to all screens on the local network.

What you need

Component Role
PoE switch Powers and networks all Raspberry Pi screens over single Ethernet cables
GL-MT300N-V2 pocket router DLNA media server + DHCP server (see pocket router DLNA guide)
Raspberry Pi 4 + PoE HAT Media player endpoint (one per passenger screen)
Full HD touch display Passenger-facing screen (one per seat)
USB media drive Stores multimedia files, plugged into the pocket router

Why this architecture

  • Single-cable per screen — PoE eliminates separate power cables, simplifying in-car wiring
  • Distributed decoding — each Raspberry Pi handles its own multimedia decoding and rendering, so there is no central bottleneck
  • Easily scalable — add more screens by swapping in a PoE switch with more ports
  • Fully offline — works in areas with no mobile coverage; all content is served locally
  • Individual or shared playback — each passenger can browse and play their own content, or all screens can be synchronized

Cost per screen

Each passenger display costs approximately $180–$200, including the Raspberry Pi 4, PoE HAT, and a full HD touch screen. The PoE switch and pocket router are shared across all screens.

Software stack

  • Kodi — open-source media player running on each Raspberry Pi, with DLNA client support built in
  • OpenWrt + minidlna — runs on the pocket router, serving media files over DLNA
  • Raspberry Pi OS — base operating system for the Pi endpoints
  • media-mux — synchronization software that coordinates playback across all screens

For the DLNA server setup on the pocket router, see the companion post: Transforming Your GL-MT300N-V2 Pocket Router into a DLNA Multimedia Server.

Installation

Option 1: Pre-built Image (Recommended)

The easiest way to get started — download and flash the same image to all SD cards:

  1. Download the pre-built image (~1.2GB)
  2. Flash to each SD card using balenaEtcher or Rufus
  3. Insert SD cards into your Raspberry Pi 4's and boot

That's it! Each Pi automatically generates a unique hostname and discovers other devices on the network.

Option 2: Manual Installation

For custom setups, you can install on an existing Raspberry Pi OS. See the manual installation guide for step-by-step instructions.

How sync works

Connect a 3-key USB keyboard to any Raspberry Pi — this becomes the sync trigger device. Press KEY_1 to synchronize all screens:

  1. The sync script reads the currently playing media and position from the trigger device
  2. Discovers all media-mux devices on the network via Avahi/mDNS
  3. Opens the same media file on all devices
  4. Uses kodisync to pause all players at the exact same frame
  5. Seeks all players to the same position and resumes playback simultaneously

Sync accuracy: The system achieves sub-200ms synchronization, typically with less than 10ms spread between devices. This is a significant improvement over the earlier version shown in the video, which required multiple sync attempts.

SOURCE CODE

github.com/hackboxguy/media-mux — sync software + pre-built SD card image

github.com/hackboxguy/multiscreen-media — hardware build guide and bill of materials

Version 2 now available: A self-hosting version that eliminates the pocket router. One Pi becomes the master automatically, providing DHCP, DNS, NTP, and DLNA. See Self-Hosting PoE Raspberry Pi 4 Infotainment System.

Tuesday, April 16, 2024

Getting Started with AWS IoT on OpenWrt Routers

While the internet is flooded with hello-world examples and simulations demonstrating the connection and message exchange between AWS-IoT Devices and AWS-IoT-Core using various programming languages like Python, C, C++, and Java, some of us beginners, students, or enthusiasts find true satisfaction in delving into the world of connected devices through hands-on interactions with physical components. The real excitement lies in experiencing the tangible effects firsthand, rather than merely observing basic hello-world messages on a computer screen.

Demo Video

How It Works

In this video, I introduce an engaging approach for exploring AWS-IoT connectivity and its real-world implications using affordable and readily available hardware components sourced from online stores. For this demonstration, I use an affordable (~$30) GL.iNet pocket router as an IoT End-Node.

This router runs on a custom-built OpenWRT Linux image and hosts an AWS IoT device agent service based on the aws-iot-device-sdk-cpp-v2. The WebUI of this custom Linux image allows you to easily configure and provision AWS IoT-specific settings such as:

  • Device certificates and private keys
  • AWS IoT Endpoints
  • Publish/subscribe topic trigger events
  • Custom scripts to control hardware accessories (switches, relays, LEDs, sensors)

Sunday, March 10, 2024

Pocket Router as a Portable DLNA Media Server

Turn a ~$30 GL-MT300N-V2 pocket router into a standalone DLNA media server — no internet required. Flash a custom OpenWrt firmware, plug in a USB drive with your media files, and any device on the Wi-Fi hotspot can stream via VLC or any DLNA client.

In-car infotainment setup: pocket router with USB media drive powered by 12V-to-5V adapter

In-car setup: pocket router powered by a 12 V-to-5 V adapter, paired with a USB media drive. All smart devices on the hotspot can stream via DLNA.

What you need

  • GL-MT300N-V2 pocket router (~$30)
  • USB flash drive or USB hard drive (NTFS formatted)
  • 5 V DC power source (USB charger, power bank, or 12 V-to-5 V adapter for car use)
  • VLC Player (or any DLNA client) on your smartphone or tablet

Setup steps

  1. Download the custom firmware — get gl-mt300nv2-dlnasrv.bin (~13 MB), an OpenWrt-based image with DLNA pre-configured.
  2. Flash the firmware — replace the OEM firmware on your GL-MT300N-V2 with the downloaded gl-mt300nv2-dlnasrv.bin file.
  3. Prepare your media disk — format a USB drive as NTFS and copy your media files into Audio/, Video/, and Photo/ folders.
  4. Power on — attach the media disk to the router's USB port and power the router with a 5 V source.
  5. Connect to Wi-Fi — the router broadcasts a hotspot with SSID dlnaserver and password goodlife.
  6. Open VLC — install VLC Player on your device, connect to the hotspot, and navigate to Local Network. The DLNA server (penguin icon) will appear with all your media files.

Default credentials: SSID = dlnaserver, password = goodlife. These are for initial setup only — change them immediately (see Security section below).

Step-by-step screenshots

The following image walks through the full flashing and configuration process in 16 slides:

Step-by-step setup guide for GL-MT300N-V2 DLNA server (16 slides)

Complete setup walkthrough: firmware flash, USB disk preparation, Wi-Fi connection, and VLC media browsing.

After following all 16 slides, connect your smartphone or tablet to the dlnaserver hotspot (password goodlife) and open VLC to browse media over the local network.

VLC Player showing DLNA server with media files

VLC Player on Android showing the DLNA server and available media files.

In-car infotainment use case

For those with an extensive multimedia collection, this compact DLNA server works well as an in-car infotainment system. Passengers can stream local media on their smartphones or tablets via the shared Wi-Fi hotspot — no mobile data or internet connection needed. This is especially useful during long drives through areas with poor network coverage.

The setup is simple: a pocket router powered by a 12 V-to-5 V DC adapter, paired with a USB media drive. When powered on, it creates a Wi-Fi hotspot and serves files over DLNA to all connected devices.

Security

Change the default credentials immediately. Modify the web UI login password, Wi-Fi SSID, and Wi-Fi password through the standard OpenWrt web interface at http://192.168.8.1.