Skip to content

Instantly share code, notes, and snippets.

View shaman7036's full-sized avatar
๐Ÿ–•

shaman7036

๐Ÿ–•
View GitHub Profile
@shaman7036
shaman7036 / uart.c
Created May 19, 2021 08:39 — forked from glegrain/uart.c
STM32 printf retarget to UART
/*# 1- Identify the UART interface, GPIO pins and Alternate Function #########*/
/* For example:
* B-L475E-IOT01A:
* PB6 ------> USART1_TX
* PB7 ------> USART1_RX
*
* NUCLEO-L476RG:
* PA2 ------> USART2_TX
* PA3 ------> USART2_RX
*
/*
* SEP firmware split tool
*
* Copyright (c) 2017 xerub
*/
#include <fcntl.h>
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
@shaman7036
shaman7036 / preprocessor_fun.h
Created February 9, 2018 22:32 — forked from aras-p/preprocessor_fun.h
Things to commit just before leaving your job
// Just before switching jobs:
// Add one of these.
// Preferably into the same commit where you do a large merge.
//
// This started as a tweet with a joke of "C++ pro-tip: #define private public",
// and then it quickly escalated into more and more evil suggestions.
// I've tried to capture interesting suggestions here.
//
// Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_,
// @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant,
@shaman7036
shaman7036 / excavator-driver.py
Created January 21, 2018 15:45 — forked from YoRyan/excavator-driver.py
Cross-platform controller for NiceHash Excavator for Nvidia.
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Cross-platform controller for NiceHash Excavator for Nvidia."""
# Example usage:
# $ excavator -p 3456 &
# $ sleep 5
# $ python3 excavator-driver.py