This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM debian:bullseye | |
RUN apt update && apt install -y wget vim git gcc make gcc binutils build-essential cmake pkg-config | |
RUN mkdir -p /root/tmp | |
RUN cd /root/tmp && wget https://github.com/pjsip/pjproject/archive/refs/tags/2.14.1.tar.gz | |
RUN cd /root/tmp && tar -xf 2.14.1.tar.gz | |
RUN cd /root/tmp/pjproject-2.14.1 && export CFLAGS="$CFLAGS -fPIC" && ./configure && make dep && make && make install | |
RUN apt install -y uuid-dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apt install libglib2.0-dev | |
apt install git | |
apt install autogen | |
apt install build-essential | |
apt install autoconf | |
apt install libyaml-dev | |
apt install libjson-glib-1.0 | |
apt install libjson-glib-dev | |
apt install libparted-dev | |
apt install check |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
import pyperclip | |
import pyopenjtalk | |
import numpy as np | |
import sounddevice as sd | |
# Get initial clipboard content | |
previous_content = "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#set -o errexit # must be disabled | |
set -o nounset | |
#set -o pipefail # must be disabled | |
usage() { | |
cat <<EOF | |
This script permits to execute jobs specified in a text file. Each line should contain a complete command to be executed. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { Transform } = require('stream'); | |
const LOW_FREQUENCIES = [697, 770, 852, 941, 1209, 1336, 1477, 1633]; | |
const HIGH_FREQUENCIES = [1209, 1336, 1477, 1633, 1633, 1633, 1633, 1633]; | |
const TONES = ['1', '2', '3', 'A', '4', '5', '6', 'B', '7', '8', '9', 'C', '*', '0', '#', 'D']; | |
class DtmfDetector extends Transform { | |
constructor() { | |
super({ objectMode: true }); | |
this.samples = []; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Gst; | |
using GLib; | |
public class DtmfDetector : Element { | |
private static const int SAMPLE_RATE = 8000; | |
private static const int CHUNK_SIZE = 256; | |
private static const int LOW_FREQUENCIES = [697, 770, 852, 941]; | |
private static const int HIGH_FREQUENCIES = [1209, 1336, 1477, 1633]; | |
private Gst.Pad sinkpad; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var sip = require('sip'); | |
var util = require('util'); | |
var os = require('os'); | |
const uuid = require('uuid') | |
if(process.argv < 3 || !sip.parseUri(process.argv[2])) { | |
console.error('usage node make_call.js _uri_'); | |
process.exit(1); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script> | |
<script> | |
window.onload = function() { | |
console.log('onload') | |
var parent = document.getElementById("parent") | |
var bottom = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt install build-essential | |
sudo add-apt-repository ppa:rock-core/qt4 | |
sudo apt update | |
sudo apt install qt4-dev-tools | |
mkdir yate | |
cd yate | |
svn checkout http://voip.null.ro/svn/yate/trunk | |
cd trunk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const Speaker = require('speaker') | |
var Mic = require('node-microphone') | |
speaker = new Speaker({ | |
audioFormat: 1, | |
endianness: 'LE', | |
channels: 1, | |
sampleRate: 8000, | |
blockAlign: 2, | |
bitDepth: 16, |
NewerOlder