Skip to content

Instantly share code, notes, and snippets.

View gitlarryf's full-sized avatar

Larry Frieson gitlarryf

View GitHub Profile
@gitlarryf
gitlarryf / hash.asm
Created May 26, 2020 21:16
x86 Hash Algorithm
int Hash(char *str)
{
char *p = str;
__asm {
mov ecx, dword ptr [esp+4]
test ecx, 3
je go
bloop:
mov al, byte ptr[ecx]
@gitlarryf
gitlarryf / buildNeonxFiles.cmd
Created May 6, 2020 17:17
Recompiles all .neonx files in a Neon working folder.
@ECHO OFF
SETLOCAL ENABLEDELAYEDEXPANSION
SET /A count=0
call:Libraries
call:Samples
call:Tests
goto:end
:Libraries
echo Recompiling Neon Libraries...
@gitlarryf
gitlarryf / buildNeonxFiles.cmd
Created May 6, 2020 17:17
Recompiles all .neonx files in a Neon working folder.
@ECHO OFF
SETLOCAL ENABLEDELAYEDEXPANSION
SET /A count=0
call:Libraries
call:Samples
call:Tests
goto:end
:Libraries
echo Recompiling Neon Libraries...
@gitlarryf
gitlarryf / daisy.neon
Created April 20, 2020 19:23
Sample program to play a tune through the SID module in Neon.
#|
| File: daisy.neon
|
| This file plays "Daisy Bell" (Bicycle Built For Two) to demonstrate the use of the
| core sid library.
|#
#IMPORT bitwise
IMPORT sid
VAR Voice: Number := 1 # Play the tune out of voice 3.
@gitlarryf
gitlarryf / phone.cmd
Created April 9, 2020 16:57
3CX Phone Helper Script
@ECHO OFF
SETLOCAL
SET Version=1.3
SET TCX="%ProgramData%\3CXPhone for Windows\PhoneApp\CallTriggerCmd.exe"
SET Away=242
SET Custom1=244
SET Custom2=241
SET Available=245
SET Exceptions=-1
SET CustomHours=-2
@gitlarryf
gitlarryf / Levenshtein.neon
Last active May 10, 2023 19:47
Returns the Levenshtein Distance value between two strings.
-- Rosettacode Coding Exercise: Levenshtein distance
-- Description: In information theory and computer science, the Levenshtein distance is a metric
-- for measuring the amount of difference between two sequences (i.e. an edit
-- distance). The Levenshtein distance between two strings is defined as the minimum
-- number of edits needed to transform one string into the other, with the allowable
-- edit operations being insertion, deletion, or substitution of a single character.
-- From: http://rosettacode.org/wiki/Levenshtein_distance
-- Language: http://neon-lang.org
-- Author: Larry Frieson
-- Date: 11/11/2015
@gitlarryf
gitlarryf / backplane_sample.neon
Last active August 4, 2020 17:46
MVI69E-LDM Sample code in the Neon Programming Language.
#############################################################################################################################
# File : backplane_sample.neon
# Author : Larry Frieson
# Desc : This file contains sample code for the MVI69E-LDM module in the Neon programming language.
# Date : 11/11/2019
#
# Copyright (C) 2019 ProSoft Technology, Inc. All rights reserved.
#
# Revision History:
# 11/11/2019 17:43:18 LEF - created.
@gitlarryf
gitlarryf / ldm-test.neon
Created November 11, 2019 16:46
Neon-lang version of the MVI69E-LDM Test Harness
IMPORT io
IMPORT sys
IMPORT mvi69
IMPORT time
VAR bpHandle: mvi69.MVI69Handle
VAR ver: mvi69.MVI69VersionInfo
VAR scanCount: Number := 0
VAR bDone: Boolean := FALSE
VAR ret: Number := 0xFFFF
@gitlarryf
gitlarryf / backplane_sample.c
Created October 31, 2019 15:57
Default MVI69E-LDM Backplane sample source code
/////////////////////////////////////////////////////////////////////////////
// backplane_sample.c
//
// This file contains sample code for the MVI69E-LDM module.
//
// (c) 2013, Prosoft Technology , All Rights Reserved
//
// MODIFIED :
// 4/18/2013 -- PJB
//
@gitlarryf
gitlarryf / mvi69.neon
Last active October 30, 2019 19:28
MVI69E-LDM Neon Extension module interface
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% File : mvi69.neon
% Author : Larry Frieson
% Desc : Contains definitions, structures, and function templates for all functions defined in the MVI69E API. This file
% is distributed as part of the Neon Extension API for the MVI69E-LDM module.
% Date : 10/14/2019
%
% Copyright (C) 2019 ProSoft Technology, Inc. All rights reserved.
%
% Revision History: