forked from letsRobot/letsrobot
-
Notifications
You must be signed in to change notification settings - Fork 19
/
controller.sample.conf
389 lines (315 loc) · 9.42 KB
/
controller.sample.conf
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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
# Sample Configuration file for the RemoTV python controller
# Global robot variables
[robot]
# This is your username on the remotv site. This is the user that is allowed
# to issue commands via chat
owner=YourRemoUsername
# Your robots API key. The site will provide you with this when you create a
# new robot.
robot_key=YourRobotAPIKey
# The name of the channel you want the robot to join. This is optional. If the
# named channel cannot be found, the robot will join the first channel.
channel=
# Motor controller type for your robot. Current valid types are serial_board,
# motor_hat, gopigo2, gopigo3, l298n, motozero, pololu, adafruit_pwm, owi_arm,
# diddyborg, megapi_board or none.
type=none
# Only used for motor_hat and mdd10
turn_delay=0.4
straight_delay=0.5
[camera]
# Disable video
no_camera=false
# Disable mic
no_mic=false
# Specify the audio / video encoder you are using here. Currently ffmpeg,
# ffmpeg-arecord and none. Note: Only robots with Raspberry Pi's or other Linux
# based controllers should use ffmpeg-arecord. All others should use ffmpeg or
# none.
type=ffmpeg-arecord
# X and Y resolution to capture video at
#x_res = 640
#y_res = 480
x_res = 768
y_res = 432
#x_res = 1280
#y_res = 720
# Video device
camera_device = /dev/video0
# windows device example
#camera_device = video="USB Webcam"
# Audio device. Generally the hardware number is preferred, but if you have
# issues with that changing, using the device name will probably help.
# otherwise, leave it blank.
mic_num = 1,0
mic_device=
#windows
#mic_device = audio="Microphone (Logitech G533 Gaming Headset)"
[ffmpeg]
# Combined ffmpeg options for audio and video
ffmpeg_location = /usr/bin/ffmpeg
# Windows path example
#ffmpeg_location = c://ffmpeg//bin//ffmpeg.exe
# Path to v4l2-ctl
v4l2-ctl_location=/usr/bin/v4l2-ctl
# Audio codec ffmpeg should use, only mp2 is supported but twolame will work
# when compiled in to ffmpeg.
audio_codec = mp2
# Audio channels, 1 for mono 2 for stereo.
audio_channels = 1
# Bitrate for the audio stream in kilobytes
audio_bitrate = 32
# Sample rate fot the audio stream in hertz
audio_sample_rate = 44100
# Video codec ffmpeg should use. Currently only mpeg1video is supported.
video_codec = mpeg1video
# Bitrate for the video stream in kilobytes
video_bitrate = 350
# Video filter options. To rotate the video 180 degree, uncomment this line
#video_filter = transpose=2,transpose=2
# Optional additional ffmpeg options for audio input and output. leave
# audio_input_device blank if using alsa for audio format
# windows
#audio_input_format = dshow
#audio_input_options = -audio_buffer_size 250
audio_input_format = alsa
audio_input_options =
audio_output_options = -nostats
# Optional additional ffmpeg options for video input and output
video_input_format = v4l2
# windows
# video_input_format = dshow
video_input_options =
video_output_options = -nostats -threads 2
# frame rate option. DO NOT CHANGE THIS unless you know what you are doing.
# it's not really about changing the framerate from the camera as it is
# changing the framerate of the video being sent to the server. The video
# encoder gets grumpy if this is set wrong.
# video_framerate = 25
[ffmpeg-arecord]
arecord_path=/usr/bin/arecord
arecord_format=S16_LE
[tts]
# Specify the TTS engine you are using here. Current valid types are espeak,
# festival and none
type=espeak
# TTS volume
tts_volume=80
# Allow anonymous users chat messages to be broadcast over TTS. Set to false to
# block them.
anon_tts=true
# Block URLS from being broadcast over TTS. Set to true to block them.
filter_url_tts=true
# Enable extended chat commands
ext_chat=true
# ALSA HW number for your playback device
# For Tellys this is 2.
# If you have trouble with the playback device changing hardware numbers,
# use the audio device name. Otherwise, leave it blank.
speaker_num=1,0
speaker_device=
# What the robot should say when it is ready to receive commands.
# No need to encapsulate in quotes.
boot_message=ok
# Announce the IPv4 address. This is useful for debugging
# especially in new environments.
announce_ip=False
# Announces when the cloned repo is out of date and by how many commits.
annouce_out_of_date=False
# Enable delayed TTS, this allows a window for moderators to remove messages
# before they get passed to TTS. Messenger must be enabled for this to function.
delay_tts = false
delay = 10
[espeak]
# espeak specific TTS settings go here
# voice gender, male or female
male = True
# voice number
voice_number=1
# espeak path. Option setting, for when espeak is not installed in the expected
# place.
#espeak_path=
# Windows path
#espeak_path=C://Program Files (x86)//eSpeak//command_line//
[festival]
# Festival specific TTS settings go here
[pico]
voice=en-US
[polly]
# polly requires you to have an amazon aws account and have setup a IAM user
# with access to polly
robot_voice=Matthew
owner_voice=Russell
random_voices=true
access_key=
secrets_key=
region_name=us-east-1
[google_cloud]
ssml_enabled=False
key_file=
voice=en-US-Wavenet-A
#pitch can be between -20.0 and 20.0, 0.0 is default pitch for chosen voice
voice_pitch=0.0
#speaking rate can be between 0.25 and 4.0, 1.0 is default rate
voice_speaking_rate=1.0
# All the settings below only work if random_voices is enabled
random_voices=False
# Enable standard_voices to disable the use of Wavenet voices.
standard_voices=False
# A comma separated list of approved language codes.
strict_languages= en-US,en-GB,en-AU
[cozmo]
forward_speed = 75
turn_speed = 50
volume = 100
charge_high = 4.79
charge_low = 3.6
send_online_status = 1
stay_on_dock = 0
annotated = 0
colour = 0
[adafruit_pwm]
address=0x40
pwm_freq=60
more_debug=False
[owi_arm]
[serial]
serial_device=/dev/ttyACM0
#serial_device=COM3 # Windows example serial device
#Option value, that will search for a serial port with a specific hardware
#name or id. Overwrites serial_device with the correct value if found.
#serial_name=Arduino
baud_rate=9600
[motor_hat]
day_speed = 255
night_speed = 255
turning_speed = 250
forward=[-1,1,-1,1]
left=[1,1,1,1]
# Enable charging behaviours
slow_for_low_battery = false
# Charging stuff
charge_hours = 3.0
discharge_hours = 8.0
chargeCheckInterval=5
chargeIONumber = 17
[gopigo2]
drive_time=0.35
turn_time=0.15
[gopigo3]
drive_time=0.35
turn_time=0.15
# Settings specific to the l298n dual h-bridge motor driver
[l298n]
StepPinForward=12,16
StepPinBackward=11,15
StepPinLeft=15,12
StepPinRight=11,16
# Change sleeptime to adjust driving speed
# Change rotatetimes to adjust the turning. Will be multiplied with sleeptime.
# IMPORTANT NOTE: How this is handled has changed, your values may no longer be
# correct if using settings from an older controller.
sleeptime=0.2
rotatetimes=5
[motozero]
MotorDelay = 0.3
# Motor1 is back left
# Motor1A is reverse
# Motor1B is forward
Motor1A = 24
Motor1B = 27
Motor1Enable = 5
# Motor2 is back right
# Motor2A is reverse
# Motor2B is forward
Motor2A = 6
Motor2B = 22
Motor2Enable = 17
# Motor3 is ?
# Motor3A is reverse
# Motor3B is forward
Motor3A = 23
Motor3B = 16
Motor3Enable = 12
# Motor4 is ?
# Motor4A is reverse
# Motor4B is forward
Motor4A = 13
Motor4B = 18
Motor4Enable = 25
[pololu]
drivingSpeed=90
[mc33926]
drivingSpeed=180
[max7219]
ledrotate=180
[thunderborg]
# maximum is 1.0, minimum is 0.0
left_motor_max=1.0
right_motor_max=1.0
sleep_time=0.4
[megapi_board]
# Default time per message
motor_time = 0.2
# Speed of drive motors (0 to 255)
driving_speed = 150
# Speed of arm drive (0 to 255)
arm_speed = 50
# Speed of grabber (0 to 255)
grabber_speed = 50
# Motor controller ports
left_track_port = 2
right_track_port = 3
grabber_port = 4
arm_port = 1
[mqtt_pub]
# If you are using MQTT you need to supply the host IP address, port, and Topic
# host should be the IP address where the MQTT broker is running (i.e. 192.168.xx.xx)
# the port typically is 1883 for MQTT
# the topic is your choice, but it needs to match with the robot subscribers
host = YourBrokerID
port = 1883
topic = LR/command
#username for MQTT server.
#Not needed unless the server is accessible from outside the local network
#user = remo
#password for user on MQTT server. This can be blank. This also sets MQTT to try to use ssl
#if using SSL, the port should be 8883
#pass = hunter2
# Logging settings
[logging]
# Name of the log file to be written to
log_file=controller.log
# log levels in order of importance are CRITICAL, ERROR, WARNING, INFO, DEBUG
file_level=WARNING
console_level=ERROR
# log size is in bytes
max_size=100000
# Number of old log files to hang onto.
num_backup=2
# This is mostly stuff you probably shouldn't be touching
[misc]
# host server to connect to
server = remo.tv
# API version is the version of the API.
api_version = dev
# video server to connect to so you can use local websocket and remote video server
video_server = remo.tv:1567
# Enable the controller to look for custom handler code
custom_hardware = True
# Enable the controller to look for custom TTS handler code
custom_tts = True
# Enable the controller to look for custom chat handler code
custom_chat = True
# Enable the controller to look for custom video handler code
custom_video = True
# Enable the watchdog timer, if you are not using a raspberry pi, you won't want
# this.
watchdog = True
# Enable async handling of commands, your handler will either need to be able to
# function asyncronously or it will need it's own blocking.
enable_async=False
# Periodically check internet connection status, and report failure / connect
# over tts
check_internet=True
check_freq=120