Skip to content

Instantly share code, notes, and snippets.

@xndcn
xndcn / .gitignore
Last active November 5, 2024 12:24
stm32_qemu_test
main.elf
:0200000460009A
:100000004643464200000156000000000103030081
:1000100000000000000000000000000000000000E0
:1000200000000000000000000000000000000000D0
:1000300000000000000000000000000000000000C0
:1000400000000000010408000000000000000000A3
:100050000000800000000000000000000000000020
:100060000000000000000000000000000000000090
:100070000000000000000000000000000000000080
:10008000EB04180A063204260000000000000000FD
/***************************************************************************
Copyright (c) Microsoft Corporation 2013.
This code is licensed using the Microsoft Public License (Ms-PL). You can find the text of the license here:
http://www.microsoft.com/resources/sharedsource/licensingbasics/publiclicense.mspx
Published at http://OpenXmlDeveloper.org
Resource Center and Documentation: http://openxmldeveloper.org/wiki/w/wiki/open-xml-sdk-for-javascript.aspx
@xndcn
xndcn / 0_reuse_code.js
Last active August 29, 2015 14:11
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@xndcn
xndcn / d-term.py
Last active October 10, 2017 04:03
# coding=utf-8
import urwid
import requests
import re
from hashlib import md5
import time
from bs4 import BeautifulSoup, NavigableString
import lxml.html
/*
* Checksummed file writer
*
* This module collects data buffers until they should be written out to a
* file, prefixed by a checksum.
*
* Typical usage is:
*
* ChecksumWriter writer;
* cwriter_init(&writer);
@xndcn
xndcn / drawFont.py
Last active December 15, 2015 13:48
# coding=utf-8
import Image, ImageDraw, ImageFont
import struct
font_width = 16
font = ImageFont.truetype("/usr/share/fonts/truetype/wqy/wqy-zenhei.ttc", font_width)
def get_font_data(char):