Commit 819c563d authored by Ishan Kumar Kaler's avatar Ishan Kumar Kaler
Browse files

push library demo

parent 7657982b
{"buildTargets":[],"launchTargets":[],"customConfigurationProvider":{"workspaceBrowse":{"browsePath":["/home/ishan/Downloads/gsoc/lib-data-over-audio","/usr/include/pd"],"compilerArgs":["-fPIC","-Wall","-Wextra","-Wshadow","-Winline","-Wstrict-aliasing","-O3","-ffast-math","-funroll-loops","-fomit-frame-pointer","-march=core2","-mfpmath=sse","-msse","-msse2","-msse3","-o","decoder.o","-c","decoder.c"],"compilerPath":"/usr/bin/cc","windowsSdkVersion":""},"fileIndex":[["/home/ishan/Downloads/gsoc/lib-data-over-audio/encoder.c",{"uri":{"$mid":1,"fsPath":"/home/ishan/Downloads/gsoc/lib-data-over-audio/encoder.c","path":"/home/ishan/Downloads/gsoc/lib-data-over-audio/encoder.c","scheme":"file"},"configuration":{"defines":["PD","UNIX"],"includePath":["/usr/include/pd"],"forcedInclude":[],"compilerPath":"/usr/bin/cc","compilerArgs":["-fPIC","-Wall","-Wextra","-Wshadow","-Winline","-Wstrict-aliasing","-O3","-ffast-math","-funroll-loops","-fomit-frame-pointer","-march=core2","-mfpmath=sse","-msse","-msse2","-msse3","-o","encoder.o","-c","encoder.c"],"windowsSdkVersion":""},"compileCommand":{"command":"cc -DPD -I \"/usr/include/pd\" -DUNIX -fPIC -Wall -Wextra -Wshadow -Winline -Wstrict-aliasing -O3 -ffast-math -funroll-loops -fomit-frame-pointer -march=core2 -mfpmath=sse -msse -msse2 -msse3 -o encoder.o -c encoder.c","directory":"/home/ishan/Downloads/gsoc/lib-data-over-audio","file":"/home/ishan/Downloads/gsoc/lib-data-over-audio/encoder.c"}}],["/home/ishan/Downloads/gsoc/lib-data-over-audio/decoder.c",{"uri":{"$mid":1,"fsPath":"/home/ishan/Downloads/gsoc/lib-data-over-audio/decoder.c","path":"/home/ishan/Downloads/gsoc/lib-data-over-audio/decoder.c","scheme":"file"},"configuration":{"defines":["PD","UNIX"],"includePath":["/usr/include/pd"],"forcedInclude":[],"compilerPath":"/usr/bin/cc","compilerArgs":["-fPIC","-Wall","-Wextra","-Wshadow","-Winline","-Wstrict-aliasing","-O3","-ffast-math","-funroll-loops","-fomit-frame-pointer","-march=core2","-mfpmath=sse","-msse","-msse2","-msse3","-o","decoder.o","-c","decoder.c"],"windowsSdkVersion":""},"compileCommand":{"command":"cc -DPD -I \"/usr/include/pd\" -DUNIX -fPIC -Wall -Wextra -Wshadow -Winline -Wstrict-aliasing -O3 -ffast-math -funroll-loops -fomit-frame-pointer -march=core2 -mfpmath=sse -msse -msse2 -msse3 -o decoder.o -c decoder.c","directory":"/home/ishan/Downloads/gsoc/lib-data-over-audio","file":"/home/ishan/Downloads/gsoc/lib-data-over-audio/decoder.c"}}]]}}
\ No newline at end of file
make --dry-run --always-make --keep-going --print-directory
make: Entering directory '/home/ishan/Downloads/gsoc/lib-data-over-audio'
++++ info: using Makefile.pdlibbuilder version 0.6.0
++++ info: using Pd API /usr/include/pd/m_pd.h
++++ info: making target all in lib data-over-audio
++++ info: evaluating implicit prerequisites in lib data-over-audio.....
++++ info: making encoder.o in lib data-over-audio
cc -DPD -I "/usr/include/pd" -DUNIX -fPIC -Wall -Wextra -Wshadow -Winline -Wstrict-aliasing -O3 -ffast-math -funroll-loops -fomit-frame-pointer -march=core2 -mfpmath=sse -msse -msse2 -msse3 -o encoder.o -c encoder.c
++++ info: linking objects in encoder.pd_linux for lib data-over-audio
cc -rdynamic -shared -fPIC -Wl,-rpath,"\$ORIGIN",--enable-new-dtags -o encoder.pd_linux encoder.o -lc -lm
++++ info: making decoder.o in lib data-over-audio
cc -DPD -I "/usr/include/pd" -DUNIX -fPIC -Wall -Wextra -Wshadow -Winline -Wstrict-aliasing -O3 -ffast-math -funroll-loops -fomit-frame-pointer -march=core2 -mfpmath=sse -msse -msse2 -msse3 -o decoder.o -c decoder.c
++++ info: linking objects in decoder.pd_linux for lib data-over-audio
cc -rdynamic -shared -fPIC -Wl,-rpath,"\$ORIGIN",--enable-new-dtags -o decoder.pd_linux decoder.o -lc -lm
++++info: target all in lib data-over-audio completed
make: Leaving directory '/home/ishan/Downloads/gsoc/lib-data-over-audio'
{
"makefile.extensionOutputFolder": "./.vscode"
}
\ No newline at end of file
make all --print-data-base --no-builtin-variables --no-builtin-rules --question
make: -dumpmachine: No such file or directory
++++ info: using Makefile.pdlibbuilder version 0.6.0
# GNU Make 4.3
# Built for x86_64-pc-linux-gnu
# Copyright (C) 1988-2020 Free Software Foundation, Inc.
# License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
# This is free software: you are free to change and redistribute it.
# There is NO WARRANTY, to the extent permitted by law.
# Make data base, printed on Wed Jun 8 00:30:13 2022
# Variables
# environment
GDK_BACKEND = x11
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 704)
warn.flags = -Wall -Wextra -Wshadow -Winline -Wstrict-aliasing
# environment
LC_ALL = C
# environment
NO_AT_BRIDGE = 1
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 422)
shared.objects :=
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 423)
lib.setup.objects :=
# environment
I3SOCK = /run/user/1000/i3/ipc-socket.1108
# environment
VSCODE_IPC_HOOK_EXTHOST = /run/user/1000/vscode-ipc-6a549b50-edfa-4a84-83ba-70b04c3f0852.sock
# environment
LC_NAME = en_IN
# environment
LC_NUMERIC = en_IN
# environment
VSCODE_CWD = /home/ishan/Downloads/gsoc/lib-data-over-audio
# environment
WINDOWID = 62914562
# environment
LESS_TERMCAP_me = 
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 411)
classes.sources := decoder.c encoder.c
# environment
LC_ADDRESS = en_IN
# default
MAKE_COMMAND := make
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 727)
c.ldflags := $(subst ,, )
# makefile (from 'Makefile', line 12)
datafiles =
# automatic
@D = $(patsubst %/,%,$(dir $@))
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 728)
c.ldlibs := $(subst ,, )
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 731)
cxx.flags := -DPD -I "" -Wall -Wextra -Wshadow -Winline -Wstrict-aliasing -O3 -ffast-math -funroll-loops -fomit-frame-pointer
# environment
VSCODE_HANDLES_UNCAUGHT_ERRORS = true
# default
.VARIABLES := GDK_BACKEND LC_ALL NO_AT_BRIDGE I3SOCK VSCODE_IPC_HOOK_EXTHOST LC_NAME LC_NUMERIC VSCODE_CWD WINDOWID LESS_TERMCAP_me LC_ADDRESS MAKE_COMMAND datafiles @D VSCODE_HANDLES_UNCAUGHT_ERRORS .VARIABLES PWD %D MAIL XDG_DATA_DIRS OLDPWD ^D VSCODE_LOG_STACK %F ALACRITTY_SOCKET VSCODE_CODE_CACHE_PATH XDG_SESSION_PATH LANG XAUTHORITY .LOADED LESS_TERMCAP_md .INCLUDE_DIRS MAKEFLAGS LESS_TERMCAP_so CURDIR VSCODE_PIPE_LOGGING APPLICATION_INSIGHTS_NO_DIAGNOSTIC_CHANNEL *D LESS_TERMCAP_ue MFLAGS .SHELLFLAGS +D lib.name P9K_SSH XDG_SESSION_DESKTOP MAKEFILE_LIST @F VSCODE_VERBOSE_LOGGING VSCODE_PID XDG_SESSION_TYPE CUDA_PATH ?D *F QT_QPA_PLATFORMTHEME CHROME_DESKTOP DBUS_SESSION_BUS_ADDRESS <D P9K_TTY VSCODE_NLS_CONFIG MAKE_HOST SHELL LESS_TERMCAP_us version MAKECMDGOALS SHLVL MAKELEVEL MAKE PATH LESS_TERMCAP_se MAKEFILES LC_MONETARY MOTD_SHOWN ^F LC_TIME LESS_TERMCAP_mb PDLIBBUILDER_DIR VSCODE_LOG_NATIVE LC_TELEPHONE ?F XDG_SEAT encoder.class.sources XDG_CURRENT_DESKTOP class.sources ALACRITTY_LOG MKLROOT LS_COLORS +F XDG_SEAT_PATH LESS DESKTOP_SESSION ORIGINAL_XDG_CURRENT_DESKTOP metafile GNUMAKEFLAGS BROWSER LOGNAME add-class-source TERMINAL XDG_VTNR .DEFAULT_GOAL EDITOR DISPLAY GTK_MODULES USER MAKE_VERSION LC_MEASUREMENT externalsdir _ LC_PAPER XDG_RUNTIME_DIR COLORTERM decoder.class.sources XDG_SESSION_CLASS VSCODE_AMD_ENTRYPOINT GTK2_RC_FILES HOME ELECTRON_RUN_AS_NODE VSCODE_IPC_HOOK TERM XDG_SESSION_ID .RECIPEPREFIX <F SUFFIXES _P9K_TTY VSCODE_CLI ELECTRON_NO_ATTACH_CONSOLE LS_OPTIONS XDG_GREETER_DATA_DIR .FEATURES Makefile.pdlibbuilder GDMSESSION PKGFILE_PROMPT_INSTALL_MISSING LC_IDENTIFICATION
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 743)
compile-cxx :=
# environment
PWD = /home/ishan/Downloads/gsoc/lib-data-over-audio
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 420)
classes.objects := decoder.o encoder.o
# automatic
%D = $(patsubst %/,%,$(dir $%))
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 691)
pdincludepathwithspaces :=
# environment
MAIL = /var/spool/mail/ishan
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 679)
PDINCLUDEDIR = $(pdincludepath)
# environment
XDG_DATA_DIRS = /home/ishan/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share:/usr/share:/var/lib/snapd/desktop
# environment
OLDPWD = /home/ishan/Downloads/gsoc
# automatic
^D = $(patsubst %/,%,$(dir $^))
# environment
VSCODE_LOG_STACK = false
# automatic
%F = $(notdir $%)
# environment
ALACRITTY_SOCKET = /run/user/1000/Alacritty-:0-3720.sock
# environment
VSCODE_CODE_CACHE_PATH = /home/ishan/.config/Code/CachedData/c3511e6c69bb39013c4a4b7b9566ec1ca73fc4d5
# environment
XDG_SESSION_PATH = /org/freedesktop/DisplayManager/Session0
# environment
LANG = C
# environment
XAUTHORITY = /home/ishan/.Xauthority
# default
.LOADED :=
# environment
LESS_TERMCAP_md = 
# default
.INCLUDE_DIRS = /usr/include /usr/local/include /usr/include
# makefile
MAKEFLAGS = pqrR
# environment
LESS_TERMCAP_so = 
# makefile
CURDIR := /home/ishan/Downloads/gsoc/lib-data-over-audio
# environment
VSCODE_PIPE_LOGGING = true
# environment
APPLICATION_INSIGHTS_NO_DIAGNOSTIC_CHANNEL = 1
# automatic
*D = $(patsubst %/,%,$(dir $*))
# environment
LESS_TERMCAP_ue = 
# environment
MFLAGS = -pqrR
# default
.SHELLFLAGS := -c
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 680)
PDLIBDIR = $(firstword $(objectsdir) $(pkglibdir))
# automatic
+D = $(patsubst %/,%,$(dir $+))
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 378)
lib.name := data-over-audio
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 726)
c.flags := -DPD -I "" -Wall -Wextra -Wshadow -Winline -Wstrict-aliasing -O3 -ffast-math -funroll-loops -fomit-frame-pointer
# environment
P9K_SSH = 0
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 421)
common.objects :=
# environment
XDG_SESSION_DESKTOP = i3
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 440)
shared.lib =
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 1)
MAKEFILE_LIST := Makefile pd-lib-builder//Makefile.pdlibbuilder
# automatic
@F = $(notdir $@)
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 408)
classes := encoder decoder
# environment
VSCODE_VERBOSE_LOGGING = true
# environment
VSCODE_PID = 13397
# environment
XDG_SESSION_TYPE = x11
# environment
CUDA_PATH = /opt/cuda
# automatic
?D = $(patsubst %/,%,$(dir $?))
# automatic
*F = $(notdir $*)
# environment
QT_QPA_PLATFORMTHEME = qt5ct
# environment
CHROME_DESKTOP = code-url-handler.desktop
# environment
DBUS_SESSION_BUS_ADDRESS = unix:path=/run/user/1000/bus
# automatic
<D = $(patsubst %/,%,$(dir $<))
# environment
P9K_TTY = old
# environment
VSCODE_NLS_CONFIG = {"locale":"en-gb","availableLanguages":{},"_languagePackSupport":true}
# default
MAKE_HOST := x86_64-pc-linux-gnu
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 733)
cxx.ldlibs := $(subst ,, )
# makefile
SHELL = /bin/sh
# environment
LESS_TERMCAP_us = 
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 2)
version = 0.6.0
# default
MAKECMDGOALS := all
# environment
SHLVL = 2
# environment
MAKELEVEL := 0
# default
MAKE = $(MAKE_COMMAND)
# environment
PATH = /home/ishan/.cargo/bin:/home/ishan/.local/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/opt/cuda/bin:/opt/cuda/nsight_compute:/opt/cuda/nsight_systems/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/var/lib/snapd/snap/bin
# environment
LESS_TERMCAP_se = 
# default
MAKEFILES :=
# environment
LC_MONETARY = en_IN
# environment
MOTD_SHOWN = pam
# automatic
^F = $(notdir $^)
# environment
LC_TIME = en_IN
# environment
LESS_TERMCAP_mb = 
# makefile (from 'Makefile', line 15)
PDLIBBUILDER_DIR = pd-lib-builder/
# environment
VSCODE_LOG_NATIVE = false
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 703)
optimization.flags = -O3 -ffast-math -funroll-loops -fomit-frame-pointer
# environment
LC_TELEPHONE = en_IN
# automatic
?F = $(notdir $?)
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 510)
target.arch :=
# environment
XDG_SEAT = seat0
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 404)
encoder.class.sources = encoder.c
# environment
XDG_CURRENT_DESKTOP = i3
# makefile (from 'Makefile', line 9)
class.sources = encoder.c decoder.c
# environment
ALACRITTY_LOG = /tmp/Alacritty-3720.log
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 424)
all.objects = $(classes.objects) $(common.objects) $(shared.objects) $(lib.setup.objects)
# environment
MKLROOT = /opt/intel/mkl
# environment
LS_COLORS = rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=00:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.avif=01;35:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:*~=00;90:*#=00;90:*.bak=00;90:*.old=00;90:*.orig=00;90:*.part=00;90:*.rej=00;90:*.swp=00;90:*.tmp=00;90:*.dpkg-dist=00;90:*.dpkg-old=00;90:*.ucf-dist=00;90:*.ucf-new=00;90:*.ucf-old=00;90:*.rpmnew=00;90:*.rpmorig=00;90:*.rpmsave=00;90:
# automatic
+F = $(notdir $+)
pd-lib-builder//Makefile.pdlibbuilder:760: *** Command " -dumpmachine" did not return a target triplet, needed for a build. Is compiler "" installed in your PATH? (/home/ishan/.cargo/bin:/home/ishan/.local/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/opt/cuda/bin:/opt/cuda/nsight_compute:/opt/cuda/nsight_systems/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/var/lib/snapd/snap/bin). Does compiler "" support option "-dumpmachine"?. Stop.
# environment
XDG_SEAT_PATH = /org/freedesktop/DisplayManager/Seat0
# environment
LESS = -R
# environment
DESKTOP_SESSION = i3
# environment
ORIGINAL_XDG_CURRENT_DESKTOP = i3
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 381)
metafile :=
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 723)
shared.ldflags := $(subst ,, )
# environment
GNUMAKEFLAGS :=
# environment
BROWSER = /usr/bin/palemoon
# environment
LOGNAME = ishan
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 407)
sourcevariables := encoder.class.sources decoder.class.sources
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 714)
cpp.flags := -DPD -I ""
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 400)
add-class-source = $(notdir $(basename $v)).class.sources += $v
# environment
TERMINAL = /usr/bin/alacritty
# environment
XDG_VTNR = 7
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 412)
all.sources := decoder.c encoder.c
# makefile
.DEFAULT_GOAL :=
# environment
EDITOR = /usr/bin/vim
# environment
DISPLAY = :0
# environment
GTK_MODULES = canberra-gtk-module
# environment
USER = ishan
# default
MAKE_VERSION := 4.3
# 'override' directive
.SHELLSTATUS := 0
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 720)
LDFLAGS :=
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 547)
arch.c.flags =
# environment
LC_MEASUREMENT = en_IN
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 366)
externalsdir = ..
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 732)
cxx.ldflags := $(subst ,, )
# environment
_ = /usr/bin/make
# environment
LC_PAPER = en_IN
# environment
XDG_RUNTIME_DIR = /run/user/1000
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 711)
CFLAGS = $(warn.flags) $(optimization.flags) $(arch.c.flags)
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 742)
compile-c :=
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 717)
depcheck.flags := -DPD -I ""
# environment
COLORTERM = truecolor
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 404)
decoder.class.sources = decoder.c
# environment
XDG_SESSION_CLASS = user
# environment
VSCODE_AMD_ENTRYPOINT = vs/workbench/api/node/extensionHostProcess
# environment
GTK2_RC_FILES = /home/ishan/.gtkrc-2.0
# environment
HOME = /home/ishan
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 434)
classes.executables = $(addsuffix .$(extension), $(classes))
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 473)
target.triplet :=
# environment
ELECTRON_RUN_AS_NODE = 1
# environment
VSCODE_IPC_HOOK = /run/user/1000/vscode-41782f3b-1.67.2-main.sock
# environment
TERM = alacritty
# environment
XDG_SESSION_ID = 2
# default
.RECIPEPREFIX :=
# automatic
<F = $(notdir $<)
# default
SUFFIXES :=
# environment
_P9K_TTY = /dev/pts/0
# environment
VSCODE_CLI = 1
# environment
ELECTRON_NO_ATTACH_CONSOLE = 1
# environment
LS_OPTIONS = --color=auto
# environment
XDG_GREETER_DATA_DIR = /var/lib/lightdm-data/ishan
# default
.FEATURES := target-specific order-only second-expansion else-if shortest-stem undefine oneshell nocomment grouped-target extra-prereqs archives jobserver output-sync check-symlink guile load
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 369)
Makefile.pdlibbuilder = true
# makefile (from 'pd-lib-builder//Makefile.pdlibbuilder', line 687)
installpath := /data-over-audio
# environment
GDMSESSION = i3
# environment
PKGFILE_PROMPT_INSTALL_MISSING = 1
# environment
LC_IDENTIFICATION = en_IN
# variable set hash-table stats:
# Load=166/1024=16%, Rehash=0, Collisions=35/283=12%
# Pattern-specific Variable Values
# No pattern-specific variable values.
# Directories
# . (device 66312, inode 4199088): 22 files, no impossibilities.
# 22 files, no impossibilities in 1 directories.
# Implicit Rules
# No implicit rules.
# Files
# Not a target:
Makefile:
# Implicit rule search has not been done.
# Modification time never checked.
# File has not been updated.
# Not a target:
pd-lib-builder//Makefile.pdlibbuilder:
# Implicit rule search has not been done.
# Modification time never checked.
# File has not been updated.
# Not a target:
.DEFAULT:
# Implicit rule search has not been done.
# Modification time never checked.
# File has not been updated.
# Not a target:
all:
# Command line target.
# Implicit rule search has not been done.
# Modification time never checked.
# File has not been updated.
# files hash-table stats:
# Load=5/1024=0%, Rehash=0, Collisions=0/7=0%
# VPATH Search Paths
# No 'vpath' search paths.
# No general ('VPATH' variable) search path.
# strcache buffers: 1 (0) / strings = 28 / storage = 323 B / avg = 11 B
# current buf: size = 8162 B / used = 323 B / count = 28 / avg = 11 B
# strcache performance: lookups = 33 / hit rate = 15%
# hash-table stats:
# Load=28/8192=0%, Rehash=0, Collisions=0/33=0%
# Finished Make data base on Wed Jun 8 00:30:13 2022
# Makefile to build library data over audio.
# Needs Makefile.pdlibbuilder as helper makefile for platform-dependent build
# settings and rules.
# library name
lib.name = data-over-audio
# input source file
class.sources = encoder.c decoder.c
# all extra files to be included in binary distribution of the library
datafiles =
# include Makefile.pdlibbuilder from submodule directory 'pd-lib-builder'
PDLIBBUILDER_DIR=pd-lib-builder/
include $(PDLIBBUILDER_DIR)/Makefile.pdlibbuilder
\ No newline at end of file
......@@ -3,10 +3,13 @@
## Getting started
Open encoder-test.pd and decoder-test.pd simultaneously to test sending receiving.
To make it easy for you to get started with GitLab, here's a list of recommended next steps.
If not on Linux, to compile on your system run, <code>make clean</code> and then run <code>make all</code>
Already a pro? Just edit this README.md and make it your own. Want to make it easy? [Use the template at the bottom](#editing-this-readme)!
If things fail make sure <code>$PDDIR</code> is set to pd directory having src and bin files in it.
Ignore rest of the auto generated readme for now.
## Add your files
......
/**
* This is code for decoder part of data over audio library.
* 29 start - the value is precedded by message.
* 30 end - the value is succeded by message.
* 31 run length decoder - idea, to be implemented
* 32 - 64 == space and special characters
* 65-90 == A - Z
* 97 - 122 == a - z
* 91-96 and 123-126 == special characters
*
* The main freq is checked in a window of size(15) from stream if its in majority accross the window
* if freq is out of bound we skip, if we dont get identifier start freq, we just ignore all values to input
* end is gived by end identifier freq. if now freq is detected continously while active listening, we assume an
* error has occured.
* When we get main freq we perform reverse operations of encoding to get string back.
*/
/**
* include the interface to Pd
*/
#include "m_pd.h"
#include <string.h>
// decoder
static t_class *decoder_class;
// window size to check
const int CHECK_COUNT = 15;
/**
* This dataspace of our decoder object
* This includes the data members that would be used by our objects.
*/
typedef struct _decoder {
t_object x_obj;
char messageStr[1000];
int freqUpdateArray[21000];
int upperIndex;
int baseFreq;
// is active listening to the data stream, else looking for start freq
int isListening;
// set previous decoded freq value in this to avoid repitition
// limitation message with consicutive same letters will fail for now #TO_FIX,
// like purr-data will be decoded as pur-data
int prev;
int curr_count;
// windows count failed in detecting
int failedCount;
} t_decoder;
/**
* @brief - print the message to pd console on output
*
* @param x - Object of decoder class
*/
void decoder_bang(t_decoder *x){
post(x->messageStr);
}
/**
* @brief - does nothing for now
*
* @param x - Object of decoder class
* @param s
* @param argc
* @param argv
*/
void decoder_list(t_decoder *x, t_symbol *s, int argc, t_atom *argv){
// if (argc == 0){
// post("Empty List");
// return;
// }
// decoder_float(x, atom_getfloat(argv));
}
/**
* @brief - return frequency round to nearest decimal value, eg 103 to 100 and 109 to 110
*
* @param f - frequency
* @return int
*/
int approximateFrequency(t_floatarg f){
int freq = f;
if (freq%10 > 5){
freq -= freq%10;
freq += 10;
}
else{
freq -= freq%10;
}
return freq;
}
/**
* @brief - takes a stream of float numbers, processes it and decodes the message and stores
* it into x->messageStr;
* Frequency updates are performed on x->freqUpdateArray
*
* @param x - Object of decoder class
* @param f - frequency in float
*/
void decoder_float(t_decoder *x, t_floatarg f){
if (f < x->baseFreq + 285 || f > x->baseFreq + 1265){
post("OUT OF BOUNDS. Skipping!!");
return;
}
int startFreq = x->baseFreq + 290;
int endFreq = x->baseFreq + 300;
char array[10];
int freq = approximateFrequency(f);
sprintf(array, "%d", freq);
// post(array);
if (x->failedCount >= 5){
post("Error Decoding!!");
return;
}
if (x->isListening){
x->freqUpdateArray[freq] += 1;
if (x->curr_count == CHECK_COUNT && x->freqUpdateArray[endFreq] > 9){
x->isListening = 0;
x->failedCount = 0;
memset(x->freqUpdateArray, 0, sizeof x->freqUpdateArray);
// output the decoded message
post(x->messageStr);
// x->upperIndex = 0;
// memset(x->messageStr, 0, sizeof x->messageStr);
return;
}
if (x->curr_count == CHECK_COUNT){
int index = x->baseFreq + 320;
for (int frq = x->baseFreq + 320; frq <= x->baseFreq + 1260; frq += 10){
if (x->freqUpdateArray[frq] > x->freqUpdateArray[index]){
index = frq;
}
}
if (x->freqUpdateArray[index] > 7){
if (index != x->prev){
x->prev = index;
int val = (index - x->baseFreq)/10;
char cc = val;
printf("%d %d %c\n", index, val, cc);
x->messageStr[x->upperIndex] = cc;
x->upperIndex = x->upperIndex + 1;
}
}
else{
x->failedCount = x->failedCount + 1;
}
for (int frq = x->baseFreq + 320; frq <= x->baseFreq + 1260; frq += 10){
x->freqUpdateArray[frq] = 0;
}
}
}
else{
if (freq == startFreq){
x->freqUpdateArray[startFreq] += 1;
}
if (x->curr_count > CHECK_COUNT && x->freqUpdateArray[startFreq] > 9){
x->isListening = 1;
x->prev = 0;
}
}
if (x->curr_count > CHECK_COUNT){
x->curr_count = 0;
}
else{
if (!x->isListening && freq == endFreq) return;
x->curr_count = x->curr_count + 1;
}
}
/**