Skip to content

Instantly share code, notes, and snippets.

View jimbob88's full-sized avatar
🖊️

James Blackburn jimbob88

🖊️
View GitHub Profile
@jimbob88
jimbob88 / bisim_alg.py
Created March 5, 2026 12:18
A simple implementation of the bisimulation algorithm with verification.
"""A simple implementation of the bisimulation algorithm with verification.
The bisimulation algorithm discovers pairs of states that are bisimilar. This
itself is the bisimulation relation <->.
LICENSE
-------
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
@jimbob88
jimbob88 / bi.py
Created March 5, 2026 10:56
A simple, exhaustive implementation of the bisimulation property in Python.
"""A simple, exhaustive implementation of the bisimulation property in Python.
In order to more deeply understand the bisimulation property of an LTS,
this code implements two forms of LTS verification. Note, this code is
not intended to be production ready, but rather as a proof of concept
to express the bisimulation property. Further, it is intentionally
computationally slow, hence, there are a large number of slow for loops.
LICENSE
-------
@jimbob88
jimbob88 / Makefile
Created February 6, 2025 07:43
Draw a Christian cross in the centre of the screen on C64
# Stripped version of cc65/samples/Makefile for simple tgi project
SYS = c64
ifdef CC65_HOME
AS = $(CC65_HOME)/bin/ca65
CC = $(CC65_HOME)/bin/cc65
CL = $(CC65_HOME)/bin/cl65
LD = $(CC65_HOME)/bin/ld65
else
@jimbob88
jimbob88 / Makefile
Created February 6, 2025 07:04
Makefile for building cc65 programs with TGI embedded into `*.d64` file
# Stripped version of cc65/samples/Makefile for simple tgi project
SYS = c64
ifdef CC65_HOME
AS = $(CC65_HOME)/bin/ca65
CC = $(CC65_HOME)/bin/cc65
CL = $(CC65_HOME)/bin/cl65
LD = $(CC65_HOME)/bin/ld65
else
@jimbob88
jimbob88 / Makefile
Created February 6, 2025 06:41
CC65 Makefile
SOURCES = example.c
PROGRAM = example
ifdef CC65_TARGET
CC = cl65
CFLAGS = -t $(CC65_TARGET) -O --create-dep $(<:.c=.d)
LDFLAGS = -t $(CC65_TARGET) -m $(PROGRAM).map
else
CC = gcc
@jimbob88
jimbob88 / README.md
Created February 6, 2025 05:53
cc65: C64 Hello World

Print "Hello World!" on C64

This follows the tutorial found in the c65 documentation overview to print hello world on the screen.

vice-screen-2025020605523915

@jimbob88
jimbob88 / Dockerfile
Created March 1, 2024 18:14
Build Prizm SDK and FXSDK
FROM alpine:3.14
# Set up GiteaPC
## Install GiteaPC dependencies
RUN apk add --no-cache gcc curl git python3 make pkgconf
## Needs to use bash and yes
RUN apk add --no-cache bash
## Install GiteaPC and accept the path added
RUN curl "https://gitea.planet-casio.com/Lephenixnoir/GiteaPC/raw/branch/master/install.sh" -o /tmp/giteapc-install.sh
RUN yes | bash /tmp/giteapc-install.sh
@jimbob88
jimbob88 / huffman.py
Created October 25, 2022 12:21
Huffman Coding in Python
"""
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
@jimbob88
jimbob88 / hosts.py
Created October 15, 2022 16:10
A fast hosts file generator (including compression support)
import itertools
import pathlib
import re
import sys
from collections import defaultdict
from typing import List
import requests
from tqdm import tqdm
@jimbob88
jimbob88 / main.py
Created September 3, 2022 16:56
Continuous Autocomplete in a textbox Qt
"""
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the