Skip to content

Instantly share code, notes, and snippets.

View SonoSooS's full-sized avatar

Sono SonoSooS

  • Hungary
  • 05:14 (UTC +02:00)
View GitHub Profile
@SonoSooS
SonoSooS / DMGCPU.MD
Last active April 18, 2024 03:45
Game Boy CPU internals

This document is intended to document certain inner workings of the CPU.

There have been efforts by emu-russia and gekkio to have the CPU decapped, and so we have the decode ROM accessible to us. This means, that we know exactly what each opcode does (besides some nuanced behavior related to HALT, STOP, and some state management related to interrupts and power saving which are hard to untangle).

Table of contents

@SonoSooS
SonoSooS / main.c
Created February 24, 2017 08:35
LCD Tweaker
#include <3ds.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
//#include "testimage_bin.h"
void PrettyScroll(char* txt, u32 val)
{
@SonoSooS
SonoSooS / midiplay2_1.py
Last active May 24, 2021 23:08
One-linear Python MIDI player concept
'''
midiplay2 rev1 - MIDI player written in Python 3.6 for Windows
Copyright (C) 2021 Sono (https://github.com/SonoSooS)
All Rights Reserved
'''
import sys
import struct
import io
import ctypes
@SonoSooS
SonoSooS / bandcamp.lua
Last active February 18, 2021 19:05
Bandcamp VLC plugin
--[[--
bandcamp.lua - Bandcamp album/track player plugin
Copyright (C) 2016-2018 Sono (https://github.com/MarcuzD)
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, but
@SonoSooS
SonoSooS / aaasoundcloud_single.lua
Last active August 1, 2018 06:11
SoundCloud music playlist plugin for VLC
--[[--
aaasoundcloud_single.lua - SonundCloud track parser
Copyright (C) 2016-2018 Sono (https://github.com/MarcuzD)
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, but
/*
Make Discord great again!
Copyright(C) 2017-2018 Sono
All Rights Reserved
*/
#include <stdio.h>
#include <string.h>
#include <windows.h>
#include <tlhelp32.h>
#hdr
#include <3ds.h>
#end
#src
#include "stdmacro.h"
#end
typedef void (*SignalHandler)(u32 notif);
@SonoSooS
SonoSooS / aaasoundcloud.lua
Created May 17, 2018 16:41
SoundCloud set playlist plugin for VLC
--[[--
SonundCloud set (playlist) parser
Copyright (C) 2016-2018 Sono (https://github.com/MarcuzD)
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, but
@SonoSooS
SonoSooS / aaasoundcloud_auser.lua
Last active May 11, 2018 00:08
SoundCloud user track player plugin for VLC
--[[--
SoundCloud user track player plugin
Copyright (C) 2016-2018 Sono (https://github.com/MarcuzD)
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, but
@SonoSooS
SonoSooS / chdir.c
Last active January 15, 2018 22:06
the most overcomplicated chdir implementation
void chdir(const char* path)
{
if(*path == '/')
{
strncpy(root, path, 262);
}
else
{
int len = 262 - strnlen(root, 262);