Commit 0dd4bee8 authored by Brandon Invergo's avatar Brandon Invergo

Clean up use of Guile's module system

parent 17944120
......@@ -14,19 +14,18 @@
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
(define-module (librekontrol alsa)
:export (make-alsa-ctl
alsa-ctl?
alsa-ctl-numid
alsa-ctl-type
alsa-ctl-descr
set-alsa-ctl-descr!
define-alsa-ctl
open-alsa-ctl
set-ctl
toggle-ctl
turn-off-ctls))
(use-modules (srfi srfi-9))
#:use-module (srfi srfi-9)
#:export (make-alsa-ctl
alsa-ctl?
alsa-ctl-numid
alsa-ctl-type
alsa-ctl-descr
set-alsa-ctl-descr!
define-alsa-ctl
open-alsa-ctl
set-ctl
toggle-ctl
turn-off-ctls))
(define-record-type <alsa-ctl>
(make-alsa-ctl numid type descr)
......
......@@ -14,36 +14,35 @@
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
(define-module (librekontrol device)
:export (make-control
control?
control-device
control-input-event
control-alsa-ctl
connect-control
define-control
make-input-max-parameter
configure-device
midi-note-button
make-midi-note-button-toggle
remap-button
make-remap-button-toggle
system-button
make-system-button-toggle
rel-knob-to-button
make-abs-knob-to-button
system-abs-knob
system-rel-knob
make-abs-to-rel-system-knob
midi-control-abs-knob
make-rel-to-abs-midi-control-knob
midi-note-pad))
(use-modules (srfi srfi-9)
(ice-9 optargs)
(librekontrol core)
(librekontrol alsa)
(librekontrol input)
((librekontrol midi) #:prefix midi:))
#:use-module (srfi srfi-9)
#:use-module (ice-9 optargs)
#:use-module (librekontrol core)
#:use-module (librekontrol alsa)
#:use-module (librekontrol input)
#:use-module ((librekontrol midi) #:prefix midi:)
#:export (make-control
control?
control-device
control-input-event
control-alsa-ctl
connect-control
define-control
make-input-max-parameter
configure-device
midi-note-button
make-midi-note-button-toggle
remap-button
make-remap-button-toggle
system-button
make-system-button-toggle
rel-knob-to-button
make-abs-knob-to-button
system-abs-knob
system-rel-knob
make-abs-to-rel-system-knob
midi-control-abs-knob
make-rel-to-abs-midi-control-knob
midi-note-pad))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Defining "control" structures and mapping them to callback ;;
......
......@@ -14,10 +14,10 @@
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
(define-module (librekontrol devices ni-a4dj)
:export (alsa-name
input-name
led-current-input))
(use-modules (librekontrol alsa))
#:use-module (librekontrol alsa)
#:export (alsa-name
input-name
led-current-input))
(define alsa-name "Audio4DJ")
(define input-name #f)
......
......@@ -14,14 +14,14 @@
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
(define-module (librekontrol devices ni-a8dj)
:export (alsa-name
input-name
led-current-input
led-gnd-lift-vinyl
led-gnd-lift-cd
led-gnd-lift-phono
led-software-lock))
(use-modules (librekontrol alsa))
#:use-module (librekontrol alsa)
#:export (alsa-name
input-name
led-current-input
led-gnd-lift-vinyl
led-gnd-lift-cd
led-gnd-lift-phono
led-software-lock))
(define alsa-name "Audio8DJ")
(define input-name #f)
......
......@@ -14,24 +14,24 @@
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
(define-module (librekontrol devices ni-ak1)
:export (alsa-name
input-name
button-left
button-middle
button-right
knob-ring
led-left
led-middle
led-right
led-ring
left
middle
right
knob
knob-max))
(use-modules (librekontrol input)
(librekontrol alsa)
(librekontrol device))
#:use-module (librekontrol input)
#:use-module (librekontrol alsa)
#:use-module (librekontrol device)
#:export (alsa-name
input-name
button-left
button-middle
button-right
knob-ring
led-left
led-middle
led-right
led-ring
left
middle
right
knob
knob-max))
(define alsa-name "AudioKontrol1")
(define input-name "Audio Kontrol 1")
......
......@@ -14,263 +14,263 @@
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
(define-module (librekontrol devices ni-kontrols4)
:export (alsa-name
input-name
led-master-quant
led-master-headphone
led-master-master
led-master-snap
led-master-warning
led-master-master-button
led-master-snap-button
led-master-rec
led-master-size
led-master-quant-button
led-master-browser-button
led-master-play-button
led-master-undo-button
knob-loop-dry/wet
fader-crossfader
knob-mic-volume
knob-cue-mix
led-chan-a->
led-chan-a-<
led-chan-a-meter-1
led-chan-a-meter-2
led-chan-a-meter-3
led-chan-a-meter-4
led-chan-a-meter-5
led-chan-a-meter-6
led-chan-a-meter-clip
led-chan-a-active
led-chan-a-cue
led-chan-a-fx1
led-chan-a-fx2
fader-chan-a
knob-chan-a-eq-filter
fader-chan-a-eq-low
fader-chan-a-eq-mid
fader-chan-a-eq-hi
led-chan-b->
led-chan-b-<
led-chan-b-meter-1
led-chan-b-meter-2
led-chan-b-meter-3
led-chan-b-meter-4
led-chan-b-meter-5
led-chan-b-meter-6
led-chan-b-meter-clip
led-chan-b-active
led-chan-b-cue
led-chan-b-fx1
led-chan-b-fx2
fader-chan-b
knob-chan-b-eq-filter
fader-chan-b-eq-low
fader-chan-b-eq-mid
fader-chan-b-eq-hi
led-chan-c->
led-chan-c-<
led-chan-c-meter-1
led-chan-c-meter-2
led-chan-c-meter-3
led-chan-c-meter-4
led-chan-c-meter-5
led-chan-c-meter-6
led-chan-c-meter-clip
led-chan-c-active
led-chan-c-cue
led-chan-c-fx1
led-chan-c-fx2
fader-chan-c
knob-chan-c-eq-filter
fader-chan-c-eq-low
fader-chan-c-eq-mid
fader-chan-c-eq-hi
led-chan-d->
led-chan-d-<
led-chan-d-meter-1
led-chan-d-meter-2
led-chan-d-meter-3
led-chan-d-meter-4
led-chan-d-meter-5
led-chan-d-meter-6
led-chan-d-meter-clip
led-chan-d-active
led-chan-d-cue
led-chan-d-fx1
led-chan-d-fx2
fader-chan-d
knob-chan-d-eq-filter
fader-chan-d-eq-low
fader-chan-d-eq-mid
fader-chan-d-eq-hi
led-deck-a-1-blue
led-deck-a-1-green
led-deck-a-2-blue
led-deck-a-2-green
led-deck-a-3-blue
led-deck-a-3-green
led-deck-a-4-blue
led-deck-a-4-green
led-deck-a-load
led-deck-a-deck-c-button
led-deck-a-in
led-deck-a-out
led-deck-a-shift
led-deck-a-sync
led-deck-a-cue
led-deck-a-play
led-deck-a-tempo-up
led-deck-a-tempo-down
led-deck-a-master
led-deck-a-keylock
led-deck-a-deck-a
led-deck-a-deck-c
led-deck-a-samples
led-deck-a-on-air
led-deck-a-sample-1
led-deck-a-sample-2
led-deck-a-sample-3
led-deck-a-sample-4
led-deck-a-digit-1-a
led-deck-a-digit-1-b
led-deck-a-digit-1-c
led-deck-a-digit-1-d
led-deck-a-digit-1-e
led-deck-a-digit-1-f
led-deck-a-digit-1-g
led-deck-a-digit-1-dot
led-deck-a-digit-2-a
led-deck-a-digit-2-b
led-deck-a-digit-2-c
led-deck-a-digit-2-d
led-deck-a-digit-2-e
led-deck-a-digit-2-f
led-deck-a-digit-2-g
led-deck-a-digit-2-dot
wheel-deck-a
fader-deck-a-tempo
wheel-distance-deck-a
led-deck-b-1-blue
led-deck-b-1-green
led-deck-b-2-blue
led-deck-b-2-green
led-deck-b-3-blue
led-deck-b-3-green
led-deck-b-4-blue
led-deck-b-4-green
led-deck-b-load
led-deck-b-deck-d-button
led-deck-b-in
led-deck-b-out
led-deck-b-shift
led-deck-b-sync
led-deck-b-cue
led-deck-b-play
led-deck-b-tempo-up
led-deck-b-tempo-down
led-deck-b-master
led-deck-b-keylock
led-deck-b-deck-b
led-deck-b-deck-d
led-deck-b-samples
led-deck-b-on-air
led-deck-b-sample-1
led-deck-b-sample-2
led-deck-b-sample-3
led-deck-b-sample-4
led-deck-b-digit-1-a
led-deck-b-digit-1-b
led-deck-b-digit-1-c
led-deck-b-digit-1-d
led-deck-b-digit-1-e
led-deck-b-digit-1-f
led-deck-b-digit-1-g
led-deck-b-digit-1-dot
led-deck-b-digit-2-a
led-deck-b-digit-2-b
led-deck-b-digit-2-c
led-deck-b-digit-2-d
led-deck-b-digit-2-e
led-deck-b-digit-2-f
led-deck-b-digit-2-g
led-deck-b-digit-2-dot
wheel-deck-b
fader-deck-b-tempo
wheel-distance-deck-b
led-fx1-dry/wet
led-fx1-1
led-fx1-2
led-fx1-3
led-fx1-mode
led-fx2-dry/wet
led-fx2-1
led-fx2-2
led-fx2-3
led-fx2-mode
knob-fx1-dry/wet
knob-fx1-1
knob-fx1-2
knob-fx1-3
knob-fx2-dry/wet
knob-fx2-1
knob-fx2-2
knob-fx2-3
button-unknown-1
button-unknown-2
button-unknown-3
button-unknown-4
button-unknown-5
button-unknown-6
button-unknown-7
button-unknown-8
button-unknown-9
button-unknown-10
button-unknown-11
button-unknown-12
button-unknown-13
button-unknown-14
button-unknown-15
button-unknown-16
button-unknown-17
button-unknown-18
button-unknown-19
button-unknown-20
button-unknown-21
button-unknown-22
button-unknown-23
button-unknown-24
button-unknown-25
button-unknown-26
button-unknown-27
button-unknown-28
button-unknown-29
button-unknown-30
button-unknown-31
button-unknown-32
button-unknown-33
button-unknown-34
button-unknown-35
button-unknown-36
button-unknown-37
button-unknown-38
button-unknown-39
button-unknown-40
knob-unknown-1
knob-unknown-2
knob-unknown-3
knob-unknown-4
knob-unknown-5
knob-unknown-6
knob-unknown-7
knob-unknown-8
knob-unknown-9
pot-max
knob-max))
(use-modules (librekontrol input)
(librekontrol alsa)
(librekontrol device))
#:use-module (librekontrol input)
#:use-module (librekontrol alsa)
#:use-module (librekontrol device)
#:export (alsa-name
input-name
led-master-quant
led-master-headphone
led-master-master
led-master-snap
led-master-warning
led-master-master-button
led-master-snap-button
led-master-rec
led-master-size
led-master-quant-button
led-master-browser-button
led-master-play-button
led-master-undo-button
knob-loop-dry/wet
fader-crossfader
knob-mic-volume
knob-cue-mix
led-chan-a->
led-chan-a-<
led-chan-a-meter-1
led-chan-a-meter-2
led-chan-a-meter-3
led-chan-a-meter-4
led-chan-a-meter-5
led-chan-a-meter-6
led-chan-a-meter-clip
led-chan-a-active
led-chan-a-cue
led-chan-a-fx1
led-chan-a-fx2
fader-chan-a
knob-chan-a-eq-filter
fader-chan-a-eq-low
fader-chan-a-eq-mid
fader-chan-a-eq-hi
led-chan-b->
led-chan-b-<
led-chan-b-meter-1
led-chan-b-meter-2
led-chan-b-meter-3
led-chan-b-meter-4
led-chan-b-meter-5
led-chan-b-meter-6
led-chan-b-meter-clip
led-chan-b-active
led-chan-b-cue
led-chan-b-fx1
led-chan-b-fx2
fader-chan-b
knob-chan-b-eq-filter
fader-chan-b-eq-low
fader-chan-b-eq-mid
fader-chan-b-eq-hi
led-chan-c->
led-chan-c-<
led-chan-c-meter-1
led-chan-c-meter-2
led-chan-c-meter-3
led-chan-c-meter-4
led-chan-c-meter-5
led-chan-c-meter-6
led-chan-c-meter-clip
led-chan-c-active
led-chan-c-cue
led-chan-c-fx1
led-chan-c-fx2
fader-chan-c
knob-chan-c-eq-filter
fader-chan-c-eq-low
fader-chan-c-eq-mid
fader-chan-c-eq-hi
led-chan-d->
led-chan-d-<
led-chan-d-meter-1
led-chan-d-meter-2
led-chan-d-meter-3
led-chan-d-meter-4
led-chan-d-meter-5
led-chan-d-meter-6
led-chan-d-meter-clip
led-chan-d-active
led-chan-d-cue
led-chan-d-fx1
led-chan-d-fx2
fader-chan-d
knob-chan-d-eq-filter
fader-chan-d-eq-low
fader-chan-d-eq-mid
fader-chan-d-eq-hi
led-deck-a-1-blue
led-deck-a-1-green
led-deck-a-2-blue
led-deck-a-2-green
led-deck-a-3-blue
led-deck-a-3-green
led-deck-a-4-blue
led-deck-a-4-green
led-deck-a-load
led-deck-a-deck-c-button
led-deck-a-in
led-deck-a-out
led-deck-a-shift
led-deck-a-sync
led-deck-a-cue
led-deck-a-play
led-deck-a-tempo-up
led-deck-a-tempo-down
led-deck-a-master
led-deck-a-keylock
led-deck-a-deck-a
led-deck-a-deck-c
led-deck-a-samples
led-deck-a-on-air
led-deck-a-sample-1
led-deck-a-sample-2
led-deck-a-sample-3
led-deck-a-sample-4
led-deck-a-digit-1-a
led-deck-a-digit-1-b
led-deck-a-digit-1-c
led-deck-a-digit-1-d
led-deck-a-digit-1-e
led-deck-a-digit-1-f
led-deck-a-digit-1-g
led-deck-a-digit-1-dot
led-deck-a-digit-2-a
led-deck-a-digit-2-b
led-deck-a-digit-2-c
led-deck-a-digit-2-d
led-deck-a-digit-2-e
led-deck-a-digit-2-f
led-deck-a-digit-2-g
led-deck-a-digit-2-dot
wheel-deck-a
fader-deck-a-tempo
wheel-distance-deck-a
led-deck-b-1-blue
led-deck-b-1-green
led-deck-b-2-blue
led-deck-b-2-green
led-deck-b-3-blue
led-deck-b-3-green
led-deck-b-4-blue
led-deck-b-4-green
led-deck-b-load
led-deck-b-deck-d-button
led-deck-b-in
led-deck-b-out
led-deck-b-shift
led-deck-b-sync
led-deck-b-cue
led-deck-b-play
led-deck-b-tempo-up
led-deck-b-tempo-down
led-deck-b-master
led-deck-b-keylock
led-deck-b-deck-b
led-deck-b-deck-d
led-deck-b-samples
led-deck-b-on-air
led-deck-b-sample-1
led-deck-b-sample-2
led-deck-b-sample-3
led-deck-b-sample-4
led-deck-b-digit-1-a
led-deck-b-digit-1-b
led-deck-b-digit-1-c
led-deck-b-digit-1-d
led-deck-b-digit-1-e
led-deck-b-digit-1-f
led-deck-b-digit-1-g
led-deck-b-digit-1-dot
led-deck-b-digit-2-a
led-deck-b-digit-2-b
led-deck-b-digit-2-c
led-deck-b-digit-2-d
led-deck-b-digit-2-e
led-deck-b-digit-2-f
led-deck-b-digit-2-g
led-deck-b-digit-2-dot
wheel-deck-b
fader-deck-b-tempo
wheel-distance-deck-b
led-fx1-dry/wet
led-fx1-1
led-fx1-2
led-fx1-3
led-fx1-mode
led-fx2-dry/wet
led-fx2-1
led-fx2-2
led-fx2-3
led-fx2-mode
knob-fx1-dry/wet
knob-fx1-1
knob-fx1-2
knob-fx1-3
knob-fx2-dry/wet
knob-fx2-1
knob-fx2-2
knob-fx2-3
button-unknown-1
button-unknown-2
button-unknown-3
button-unknown-4
button-unknown-5
button-unknown-6
button-unknown-7
button-unknown-8
button-unknown-9
button-unknown-10
button-unknown-11
button-unknown-12
button-unknown-13
button-unknown-14
button-unknown-15
button-unknown-16
button-unknown-17
button-unknown-18
button-unknown-19
button-unknown-20
button-unknown-21
button-unknown-22
button-unknown-23
button-unknown-24
button-unknown-25
button-unknown-26
button-unknown-27
button-unknown-28
button-unknown-29
button-unknown-30
button-unknown-31
button-unknown-32
button-unknown-33
button-unknown-34
button-unknown-35
button-unknown-36
button-unknown-37
button-unknown-38
button-unknown-39
button-unknown-40
knob-unknown-1
knob-unknown-2
knob-unknown-3
knob-unknown-4
knob-unknown-5
knob-unknown-6
knob-unknown-7
knob-unknown-8
knob-unknown-9
pot-max
knob-max))
(define alsa-name "TraktorKontrolS")
(define input-name "Traktor Kontrol S4")
......
......@@ -14,96 +14,96 @@
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
(define-module (librekontrol devices ni-kontrolx1)
:export (alsa-name
input-name
led-fx-a-on
led-fx-a-1
led-fx-a-2
led-fx-a-3
led-fx-b-on
led-fx-b-1