This file contains hidden or 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
; Author: Adam Allaf | |
; Date: 18.03.2016 | |
; Description: 4-Byte signed integer calculator | |
; Version: 2.0 | |
;------------------------------------------------------------------------------ | |
#include "msp430.h" ; #define controlled include file | |
NAME main ; module name | |
PUBLIC main ; make the main label vissible |
This file contains hidden or 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
#!/usr/bin/python2 | |
# Copyright (C) 2016 Sixten Bergman | |
# License WTFPL | |
# | |
# This program is free software. It comes without any warranty, to the extent | |
# permitted by applicable law. | |
# You can redistribute it and/or modify it under the terms of the Do What The | |
# Fuck You Want To Public License, Version 2, as published by Sam Hocevar. See |
This file contains hidden or 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
function [maxtab, mintab]=peakdet(v, delta, x) | |
%PEAKDET Detect peaks in a vector | |
% [MAXTAB, MINTAB] = PEAKDET(V, DELTA) finds the local | |
% maxima and minima ("peaks") in the vector V. | |
% MAXTAB and MINTAB consists of two columns. Column 1 | |
% contains indices in V, and column 2 the found values. | |
% | |
% With [MAXTAB, MINTAB] = PEAKDET(V, DELTA, X) the indices | |
% in MAXTAB and MINTAB are replaced with the corresponding | |
% X-values. |
This file contains hidden or 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
#!/usr/bin/env python | |
import wave, struct | |
import numpy as np | |
import time | |
class DTMFDecoder: | |
DATA_TYPES = [None, "b", "<h", None, "<i"] | |
LOW_FREQUENCIES = [697.0, 770.0, 852.0, 941.0] | |
HIGH_FREQUENCIES = [1209.0, 1336.0, 1477.0, 1633.0] |
This file contains hidden or 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
#include <msp430g2553.h> | |
int i = 0; // this should be unsigned | |
/* TA0CCR0 = power of 2 values only */ | |
void __attribute__((interrupt(TIMER0_A0_VECTOR))) Timer0_A0_ISR(){ | |
TA0CTL &= ~1; | |
i++; | |
int c = (i & (TA0CCR0 + 1)) - (i & TA0CCR0); |
This file contains hidden or 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 | |
sh /home/adam/control/lcd_pin_enable.sh | |
echo '0' > /sys/class/gpio/gpio508/value |
This file contains hidden or 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
; Welcome to Much Assembly required! | |
; You will find useful information on the game here: https://github.com/simon987/Much-Assembly-Required/wiki | |
HWID_LEGS equ 0x0001 | |
HWID_KEYBOARD equ 0x0004 | |
HWID_DRILL equ 0x0005 | |
HWID_HOLO equ 0x0009 | |
HWID_BATTERY equ 0x000A | |
BATTERY_POLL equ 1 | |
HOLO_DISP_HEX equ 1 |
This file contains hidden or 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 datetime import datetime | |
from queue import Queue | |
from socketserver import BaseRequestHandler, UDPServer | |
from threading import Thread | |
class LogMessage: | |
__slots__ = ['client_ip', 'date', 'log'] | |
def __init__(self): |
This file contains hidden or 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
Sub CopyEmailsToClipboard() | |
Dim clipboard As MSForms.DataObject | |
Dim sEmail As Object | |
Dim msg As String | |
Dim i As Integer | |
i = 0 | |
Set clipboard = New MSForms.DataObject | |
For Each sEmail In ActiveExplorer.Selection |
This file contains hidden or 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
Sub ResponToSelected() | |
Dim OutApp As Outlook.Application | |
Dim objOutlookMsg As Outlook.MailItem | |
Dim objOutlookRecip As Recipient | |
Dim objRecipients As Recipients | |
Dim outlookNameSpace As Outlook.nameSpace | |
Dim sEmail As Object | |
Dim mRecipients As String | |
Dim i As Integer |
OlderNewer