forked from woudshoo/cl-nxt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
package.lisp
106 lines (90 loc) · 2.18 KB
/
package.lisp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
;;; Copyright (c) 2010-2011 by Willem Rein Oudshoorn
;;;
;;; Licensed under the BSD License, see accompanied LICENSE file
;;;
(in-package #:cl-user)
(defpackage #:nxt
(:use #:cl)
(:export #:nxt ;classes
#:usb-nxt
#:bluetooth-nxt
#:*nxt* ;default brick handling
#:open-connection
#:close-connection
#:find-an-nxt ;low-level opening and closing
#:open-bluetooth-nxt
#:find-usb-nxt
#:close-nxt
#:*default-bluetooth-device*
;; nxt commands
#:nxt-open-read
#:nxt-open-write
#:nxt-read
#:nxt-write
#:nxt-close
#:nxt-delete
#:nxt-find-first
#:nxt-find-next
#:nxt-get-firmware-version
#:nxt-get-device-info
#:nxt-request-first-module
#:nxt-request-next-module
#:nxt-close-module-handle
#:nxt-start-program
#:nxt-stop-program
#:nxt-play-sound-file
#:nxt-play-tone
#:nxt-set-output-state
#:nxt-set-input-mode
#:nxt-get-output-state
#:nxt-get-input-values
#:nxt-reset-input-scaled-value
#:nxt-message-write
#:nxt-reset-motor-position
#:nxt-get-battery-level
#:nxt-stop-sound-playback
#:nxt-keep-alive
#:nxt-ls-get-status
#:nxt-ls-write
#:nxt-ls-read
#:nxt-get-current-program-name
#:nxt-message-read
;; lower-level functions for users not wishing to go through
;; the individual exported symbols above:
#:find-frame-pair
#:perform-command
;; introspection
#:list-all-commands
#:show-commands
#:show-command
;; programs
#:running-a-program-p
#:stop-current-program
#:start-program
;; MotorControl
#:restart-motor-control
#:motor-control
#:stop-motor
#:query-motor
#:motor-ready-p
#:sleep-until-motor-ready
;; sensor utilities
#:switch-on
#:get-switch
#:lightdetector-on
#:light-off
#:get-brightness-or-color
#:ultrasonic-on
#:get-ultrasonic
#:acceleration-sensor-on
#:get-acceleration
#:angle-sensor-on
#:get-angle-sensor-data
#:get-current-angle
#:get-accumulated-angle
#:get-rpm
#:compass-on
#:get-compass
#:enumerate-digital-sensors
#:probe-digital-sensor))
(pushnew :nxt *features*)