Skip to content

Instantly share code, notes, and snippets.

@CompaqDisc
CompaqDisc / clock_app.c
Created May 2, 2022 20:50
A simple clock for Flipper Zero
#include <furi.h>
#include <furi_hal.h>
#include <gui/elements.h>
#include <gui/gui.h>
#include <input/input.h>
#define TAG "Clock"
#define CLOCK_DATE_FORMAT "%.4d-%.2d-%.2d"
@CompaqDisc
CompaqDisc / keybase.md
Created December 6, 2019 04:16
_keybase

Keybase proof

I hereby claim:

  • I am compaqdisc on github.
  • I am compaqdisc (https://keybase.io/compaqdisc) on keybase.
  • I have a public key ASCgkJXB6OI7sHjOA3YR5xW9_7B9Itz6kZN7Ov4wlc4-bgo

To claim this, I am signing this object:

@CompaqDisc
CompaqDisc / main.cc
Created August 27, 2019 07:08
Re-implementation of Javidx9's Console FPS Game using olcPixelGameEngine.
#define OLC_PGE_APPLICATION
#include "olcPixelGameEngine.h"
#include <math.h>
#include <cstring>
#include <vector>
#include <algorithm>
#include <utility>
class Demo : public olc::PixelGameEngine
{
--- p3.cc 2019-08-02 01:00:02.824687700 -0600
+++ SimpleDemo3DPGE.cc 2019-08-02 12:21:52.749790300 -0600
@@ -1,95 +1,57 @@
/*
-OneLoneCoder.com - 3D Graphics Part #3 - Cameras & Clipping
-"Tredimensjonal Grafikk" - @Javidx9
-
-License
-~~~~~~~
-One Lone Coder Console Game Engine Copyright (C) 2018 Javidx9
@CompaqDisc
CompaqDisc / trace.log
Created February 9, 2019 17:32
strace of process adtrack2
execve("./adtrack2", ["./adtrack2"], 0x7ffff2678280 /* 41 vars */) = 0
strace: [ Process PID=18189 runs in 32 bit mode. ]
brk(NULL) = 0x14e93000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_LARGEFILE|O_CLOEXEC) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=220341, ...}) = 0
mmap2(NULL, 220341, PROT_READ, MAP_PRIVATE, 3, 0) = 0xf7edf000
close(3) = 0
openat(AT_FDCWD, "/usr/lib32/libSDL-1.2.so.0", O_RDONLY|O_LARGEFILE|O_CLOEXEC) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0@E\0\0004\0\0\0"..., 512) = 512
@CompaqDisc
CompaqDisc / string_demo.cc
Created January 31, 2019 21:47
Print std::string various ways.
// For std::string
#include <string.h>
// For std::copy, std::for_each
#include <algorithm>
// For std::ostream_iterator
#include <iterator>
// For std::cin, std::cout
#include <iostream>
// For std::numeric_limits
#include <limits>
@CompaqDisc
CompaqDisc / diff.diff
Created January 31, 2019 06:41
Just a diff...
--- test-old.cc 2019-01-30 22:49:33.481304795 -0700
+++ test.cc 2019-01-30 23:39:32.564553393 -0700
@@ -69,13 +69,13 @@
int main()
{
- const int maxLength = 100;
+ const int maxLength = 101;
char inputChar = '\0';
@CompaqDisc
CompaqDisc / .bashrc
Created September 8, 2018 00:14
dotfiles
#
# ~/.bashrc
#
# If not running interactively, don't do anything
[[ $- != *i* ]] && return
alias ls='ls --color=auto'
alias ll='ls --color=auto -hl'
PS1='\e[0;34m\u\e[0;35m@\e[0;31m\h \e[0;32m\w\e[0m\$ '
@CompaqDisc
CompaqDisc / compton.conf
Created June 10, 2018 18:32
compton configuration
# Shadow
shadow = true; # Enabled client-side shadows on windows.
no-dock-shadow = true; # Avoid drawing shadows on dock/panel windows.
no-dnd-shadow = true; # Don't draw shadows on DND windows.
clear-shadow = true; # Zero the part of the shadow's mask behind the
# window. Fix some weirdness with ARGB windows.
shadow-radius = 7; # The blur radius for shadows. (default 12)
shadow-offset-x = -7; # The left offset for shadows. (default -15)
shadow-offset-y = -7; # The top offset for shadows. (default -15)
shadow-opacity = 0.7; # The translucency for shadows. (default .75)
0xb5DFC84687769e357774AF243127F2E247e971A8