Skip to content

Instantly share code, notes, and snippets.

# build helloworld executable when user executes "make"
volumecontrol: volumecontrol.o
$(CC) $(LDFLAGS) -lasound volumecontrol.o -o volumecontrol
volumecontrol.o: volumecontrol.c
$(CC) $(CFLAGS) -c volumecontrol.c
# remove object files and executable when user executes "make clean"
clean:
rm *.o volumecontrol
@dchabot
dchabot / # neovim - 2018-09-15_20-28-00.txt
Created September 16, 2018 00:42
neovim on Ubuntu 18.04.1 LTS - Homebrew build logs
Homebrew build logs for neovim on Ubuntu 18.04.1 LTS
Build date: 2018-09-15 20:28:00
import os
import soundfile as sd
import numpy as np
import matplotlib.pyplot as plt
import re
flacs = list()
for root, dir, files in os.walk('/Users/chabot/Dropbox/Music'):
@dchabot
dchabot / ffmpeg_load_audio.py
Created June 4, 2018 17:52 — forked from kylemcdonald/ffmpeg_load_audio.py
Load audio from ffmpeg into Python using numpy.
import numpy as np
import subprocess as sp
import os
DEVNULL = open(os.devnull, 'w')
# load_audio can not detect the input type
def ffmpeg_load_audio(filename, sr=44100, mono=False, normalize=True, in_type=np.int16, out_type=np.float32):
channels = 1 if mono else 2
format_strings = {
np.float64: 'f64le',
record(ao, "test:ao") {
field(ASG, "rps_threshold")
field(DRVH, "10")
field(DRVL, "0")
}
record(bo, "test:bo") {
field(ASG, "rps_lock")
field(ZNAM, "OUT")
field(ONAM, "IN")
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#
# Copyright (c) 2008 - 2013 10gen, Inc. <http://10gen.com>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0