Skip to content

Instantly share code, notes, and snippets.

@CommitThis
CommitThis / Advent of Code 2021
Last active December 3, 2021 17:02
Advent of Code
Title workaround.

Customising mion

It is possible to create a mion image with your own software and features. This article will take you through some basics to get you started.

Introduction

mion is an operating system and build system based on the Yocto Project tooling.

There are a few key terms you will need to be aware of:

@CommitThis
CommitThis / bf6064-filter.patch
Last active June 17, 2021 15:23
Build ONLP manually
From a982850e4602a585ad2634032fa8f598b6999e50 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Eil=C3=ADs=20N=C3=AD=20Fhlannag=C3=A1in?=
<pidge@toganlabs.com>
Date: Tue, 17 Nov 2020 10:30:18 +0000
Subject: [PATCH] Makefile: Add FILTER from src to machine name
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Killing the alltargets bug
Signed-off-by: Eil<C3><AD>s N<C3><AD> Fhlannag<C3><A1>in <pidge@toganlabs.com>
@CommitThis
CommitThis / device_map.c
Last active June 4, 2021 13:45
Device Mapping
#include <cstdio> // for printf debugging
struct port_channel
{
unsigned int muxaddr;
unsigned int muxchannel;
unsigned int port_number;
};
typedef struct port_channel port_channel_t;
@CommitThis
CommitThis / buildstratum_bmv2.sh
Last active February 23, 2021 11:34
Stratum BMv2 Build Script
#! /usr/bin/env bash
if [[ "$UID" != "0" ]]; then
sudo $0
exit
fi
export BMV2_COMMIT=498202d98d83a6c580aa86a3497b9b496bcd43b2
export JDK_URL=https://mirror.bazel.build/openjdk/azul-zulu11.29.3-ca-jdk11.0.2/zulu11.29.3-ca-jdk11.0.2-linux_x64.tar.gz
@CommitThis
CommitThis / error.cu
Created November 27, 2020 17:00
NVCC Error
enum class policy {
a, b
};
template <policy P>
auto foo() {
if constexpr (P == policy::a) {
return 240;
} else {
return 204;
@CommitThis
CommitThis / CUDA std::vector
Last active April 28, 2024 20:22
CUDA std::vector - Unified Memory Allocator
Example code for making a std::vector backed by
memory on the GPU using a custom allocator.
@CommitThis
CommitThis / User Defined Literals
Last active December 3, 2021 17:07
User Defined Literals
Deomstrating use of user defined literals with
a "memory buffer" as an example.