Skip to content

Instantly share code, notes, and snippets.

View racingmars's full-sized avatar

Matthew R. Wilson racingmars

View GitHub Profile
@racingmars
racingmars / crtdsmtap.c
Created February 25, 2024 03:37
A utility to copy routine exports from a text file to a DSM-11 compatible simh tape
/*
* crtdsmtap - Create a DSM-11 compatible routine tape file for use with simh.
*
* This utility reads a single saved M[UMPS] language routine save file and
* converts it into a simh tap file that can be read with the ^%RR utility in
* DSM-11 on a simh PDP-11 (or DSM for OpenVMS on a simh VAX).
*
* The routine file must already be in a format that is supported by DSM-11.
* %^RS files from current versions of Cache/IRIS don't always work...I have
* found that importing the routines into RSM first, then using ^%RS from RSM
@racingmars
racingmars / lmy99print.go
Last active March 14, 2022 03:05
Utilty to process Luminary099 sources to prepare for Virtual1403
/*
Author of this utility: Matthew R. Wilson <mwilson@mattwilson.org>
Date: March 13, 2022
License: I release this into the public domain.
This utilty reads the files from
<https://github.com/chrislgarry/Apollo-11/tree/master/Luminary099>
and prepares a file to print with Virtual1403.
Note:
@racingmars
racingmars / README.md
Created February 16, 2021 07:23 — forked from smoser/README.md
qemu to linux mapping of smbios / dmi information

Mappings for DMI/SMBIOS to Linux and dmidecode

Information can be put into dmi tables via some qemu-system hosts (x86_64 and aarch64). That information is exposed in Linux under /sys/class/dmi/id and can be read with dmidecode. The names are very annoyingly inconsistent. The point of this doc is to map them.

Mappings

Example qemu cmdline:

qemu-system-x86_64 -smbios type=<type>,field=value[,...]

qemu-system-x86_64 -smbios type=0,vendor=superco,version=1.2.3
@racingmars
racingmars / netsol-update.jcl
Last active October 1, 2020 12:03
Create a customized network solicitor screen for my MVS 3.8J system
//MWILSONU JOB CLASS=A,MSGCLASS=X,MSGLEVEL=(1,1)
//*
//* CREATE A CUSTOMIZED NETWORK SOLICITOR SCREEN FOR MY MVS3.8J
//* SYSTEM, BASED ON THE EXAMPLE PROVIDED BY TOMMY SPRINKLE AT
//* http://tommysprinkle.com/mvs/netsol/index.htm
//*
//* RESTORE ORIGINAL NETSOL SO WE CAN MODIFY A CLEAN COPY.
//* THIS, OF COURSE, ASSUMES YOU HAVE PREVIOUSLY BACKED UP THE ORIGINAL
//* SYS1.MACLIB(NETSOL) TO SYS1.MACLIB(NETSOL00). DO THAT BEFORE EVER
//* RUNNING THIS JOB FOR THE FIRST TIME.
@racingmars
racingmars / Makefile
Created September 5, 2020 02:03
Makefile for JCC compile and link on Linux, submitting to Hercules socket card reader
export WINEARCH = win32
CC=wine ../jcc/jcc.exe
INCLUDE=-I../jcc/include
LINK=wine ../jcc/prelink.exe
LOBJS=../jcc/objs
RDRPREP=../rdrprep/rdrprep
HERCHOST=localhost
HERCPORT=3506
TARGET = hello.jcl
@racingmars
racingmars / kubernetes-dashboard.yaml
Created March 30, 2017 19:20
Kubernetes Dashboard 1.6 w/ service account setup
# Copyright 2015 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# RxRate (set "units" in Grafana to bits per second, the *8 converts bytes to bits):
SELECT mean("rxrate") * 8 FROM "network_traffic" WHERE "host" = 'gw' AND "interface" = 'eth0' AND $timeFilter GROUP BY time($interval)
# TxRate (set "units" in Grafana to bits per second, the *8 converts bytes to bits):
SELECT mean("txrate") * 8 FROM "network_traffic" WHERE "host" = 'gw' AND "interface" = 'eth0' AND $timeFilter GROUP BY time($interval)
# 30-day Rx data (I use this as a "singlestat" dashboard item)
SELECT sum("rx") FROM "autogen"."historical_network_traffic" WHERE "host" = 'gw' AND "interface" = 'eth0' AND time >= now() - 30d
@racingmars
racingmars / .zshrc
Created September 26, 2014 01:55
Matthew's boring .zshrc
# History
HISTFILE=~/.histfile
HISTSIZE=1000
SAVEHIST=1000
setopt appendhistory
# Completion
autoload -Uz compinit
compinit