Skip to content

Instantly share code, notes, and snippets.

#include <stdint.h>
#include <stddef.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <stdbool.h>
// Solver for FBX FileId and footer hashes.
// The hash construction is based on @hamish-milne's FbxWriter
// https://github.com/hamish-milne/FbxWriter
#include <stdint.h>
#include <stddef.h>
#include <stdio.h>
#include <string.h>
#define array_count(arr) (sizeof(arr) / sizeof(*(arr)))
struct original_entry {
const char *date;
const char *hashes[2];
from amaranth import *
from amaranth_boards.ulx3s import ULX3S_85F_Platform
class Counter(Elaboratable):
def elaborate(self, platform):
m = Module()
counter = Signal(8)
leds = [platform.request("led", n) for n in range(8)]
from amaranth import *
from amaranth.lib import wiring
from amaranth.lib.wiring import In, Out
from amaranth.sim import Simulator, SimulatorContext
from dataclasses import dataclass
@dataclass
class SdramSpec:
row_bits: int
col_bits: int
from nmigen import *
from enum import Enum, unique
from nmigen.cli import main
from nmigen.back.pysim import Simulator, Delay, Settle
@unique
class Op(Enum):
NOP = 0
MOVE = 1
UPDATE = 2
#if 1
#include <atomic>
#include <vector>
#include <mutex>
#include <unordered_set>
__declspec(noinline) void ebi_assert(bool cond)
{
if (!cond)
{
#define _CRT_SECURE_NO_WARNINGS
#include "ufbx.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
void print_indent(FILE *f, int indent)
{
for (int i = 0; i < indent; i++) {
This file has been truncated, but you can view the full file.
#ifndef UFBX_UFBX_C_INCLUDED
#define UFBX_UFBX_C_INCLUDED
#if defined(UFBX_HEADER_PATH)
#include UFBX_HEADER_PATH
#else
#include "ufbx.h"
#endif
This file has been truncated, but you can view the full file.
#ifndef UFBX_UFBX_C_INCLUDED
#define UFBX_UFBX_C_INCLUDED
#if defined(UFBX_HEADER_PATH)
#include UFBX_HEADER_PATH
#else
#include "ufbx.h"
#endif
This file has been truncated, but you can view the full file.
#ifndef UFBX_UFBX_C_INCLUDED
#define UFBX_UFBX_C_INCLUDED
#if defined(UFBX_HEADER_PATH)
#include UFBX_HEADER_PATH
#else
#include "ufbx.h"
#endif