Laurens Valk
55c5790a48
doc/nxtdevices: fix typo
2020-04-24 10:50:34 +02:00
Laurens Valk
6f8e3ba0ff
doc/tools: improve datalog information
...
- Fix typo in example
- Explain how to upload a log file
- Show an example graph
2020-04-10 13:54:36 +02:00
David Lechner
b5159a850a
api: fix typo in Font parameter
...
script was missing a letter
2020-04-08 09:58:13 +02:00
Laurens Valk
32ab928aa8
doc/ev3devices/UltrasonicSensor: add freeze note
...
Simplify the text for silent mode, and add a note to say what to do if it stops working when the UART gets confused.
2020-04-07 13:41:04 +02:00
David Lechner
87c2b6857f
api: Use leading _ to hide internals in intellisense
...
Intellisense in VS Code (both jedi and ms python language server) picks
up all imported names and suggests them with equal priority for
code completion. By adding a leading underscore, intellisense lists
these with a lower priority, so they don't get in the way.
Also rename from builtins to _common while we are touching this to
better reflect the intention of the module (it contains types shared
by multiple modules, not builtin types like int).
2020-03-25 20:24:32 +01:00
Laurens Valk
43c006d836
doc/builtins/Motor: return from run_until_stalled
...
The return argument was not documented.
2020-03-25 09:32:46 +01:00
Laurens Valk
ada50328bb
doc/pupdevices/Motor: fix reset_angle
...
The note about absolute angle support had accidentally ended up in the GyroSensor. It applies only to pupdevices.Motor.
2020-03-24 16:25:06 +01:00
Laurens Valk
0bee7ef984
doc: fix and clarify verbs
2020-03-24 12:12:49 +01:00
David Lechner
166ce2109f
doc: Use verbs ending in s for functions/methods
...
The documentation currently has a mix of with and without the `s`.
Adding an `s` is consistent with most API documentation in general,
especially more modern documentation.
2020-03-24 12:11:53 +01:00
Laurens Valk
a827491b2b
doc/pupdevices: doc ColorDistanceSensor.remote()
2020-03-20 11:13:52 +01:00
Laurens Valk
661de5f0fe
doc/*devices: improve rgb() docstring
2020-03-20 10:42:52 +01:00
David Lechner
65deb297dd
api: remove Port subclass from hubs
...
This was removed in the pybricks-micropython implementation.
2020-03-18 18:10:18 -05:00
David Lechner
e3d0d51c9f
config: drop versioneer
...
This removes versioneer for versioning. The version depends on the
pybricks-micropython version targeted so it doesn't make sense to use
automatic versioning here.
2020-03-18 17:30:42 -05:00
David Lechner
21cef2f8c8
api: remove __init__.py
...
pybricks is a namespace, not a module, so it cannot have __init__.py. Otherwise there can be no other packages installed that use the pybricks namespace.
2020-03-18 17:19:48 -05:00
Laurens Valk
aa343d017f
doc/robotics: add note for when to change settings
2020-03-17 15:47:54 +01:00
Laurens Valk
1158e4e45a
api/builtins/Motor: separate methods for stop
...
stop(Stop.COAST)
stop(Stop.BRAKE)
stop(Stop.HOLD)
becomes
stop()
brake()
hold()
This is easier to type and remember.
2020-03-17 15:19:55 +01:00
Laurens Valk
1c576d5b11
api/builtins/Motor: rename stop_type kwarg
...
All point-to-point maneuvers come to a controlled stop before the stop
mode kicks in. Therefore it is more accurate to rename stop_type to
then, as this argument controls what happens after stopping,
so it reads: then=Stop.HOLD.
2020-03-17 15:19:27 +01:00
Laurens Valk
65888a825d
api/robotics: revert stop type for stop()
...
Partially reverts b25227ec5b
This stays coast by default. This way, stop() remains the best way to release all torque from a motor. Also, it ensures that stopping a running motor or drivebase is smooth by default.
2020-03-15 20:44:21 +01:00
Laurens Valk
d282d38836
doc/builtins/DCMotor: a DCMotor cannot hold
2020-03-15 20:36:38 +01:00
Laurens Valk
9dd1f45ccd
doc: drop default argument in docstring
...
This is visible in the function definition, so no need to repeat it.
2020-03-15 20:35:36 +01:00
David Lechner
abe24cf289
api/builtin: add missing DCMotor.stop() method
...
This was missing. It also has a different default value
from the Motor class, so Motor overrides this method.
2020-03-12 12:52:27 -05:00
David Lechner
6ed6ec0378
api: remove empty () on class declarations
...
Python allows this syntax and some even consider it good style.
2020-03-12 12:46:09 -05:00
David Lechner
b25227ec5b
api/Motor,DriveBase: change default stop to HOLD
...
This reflects a change in the implmentation
2020-03-07 16:24:42 -06:00
David Lechner
cab16f6af7
api/media/ev3dev: add Image/screen save method
...
This was overlooked previously.
2020-03-06 12:59:42 -06:00
Laurens Valk
066983a5e1
LICENSE: Update year and authors
...
Also add SPDX-License-Identifier: MIT to API source files for clarity.
2020-03-05 10:33:48 +01:00
Laurens Valk
10731d019a
doc/parameters: remove Align
...
This was already hidden from the docs, but not deleted.
2020-03-03 17:43:53 +01:00
Laurens Valk
c02cc456f7
api/iodevices/Ev3devSensor: add device index
...
This makes it easy to find the sensor to access additional features through the ev3dev lego-sensor and lego-port classes.
2020-02-25 10:29:40 +01:00
David Lechner
df6cfa30f6
api/media.ev3dev.Image: Add default args for empty()
...
Implementation has been changed so that omitting args gives an empty
image the same size as the screen.
2020-02-21 11:01:44 -06:00
Laurens Valk
854760feb6
api/builtins/Control: add feed_forward gain
...
This can be useful for motors with high internal static friction.
2020-02-20 16:34:25 +01:00
Laurens Valk
0d068b17f2
api/iodevices/AnalogSensor: remove type check
...
This makes it consistent with the UARTDevice and I2CDevice class.
The `Ev3devSensor` class can be used instead if auto id is desired.
2020-02-20 16:23:26 +01:00
Laurens Valk
b81b28d338
api/builtins/Control: add scale property
2020-02-19 19:40:44 +01:00
Laurens Valk
16e8af0f4d
api/builtins/Control: add integral_rate setter
2020-02-17 14:04:50 +01:00
Laurens Valk
a0fba6c2d1
api/builtins/Control: Move stalled to control
...
This is a control status property, so move it to the control class. This way, it is hidden from the common motor methods, and DriveBases will be able to use it too.
2020-02-17 13:55:45 +01:00
Laurens Valk
9db7e95959
api/robotics: DriveBase: rename settings args
...
Make it explicit that these arguments affect only the settings for the corresponding methods.
Also rephrase a few docstrings to make them easier to read or fix typos.
2020-02-17 13:43:48 +01:00
David Lechner
5231c48eda
pybricks/media/ev3dev: list known font language codes
...
This list was obtained by running fc-list on an EV3.
2020-02-15 18:18:36 -06:00
Laurens Valk
9c6d2267bd
api/nxtdevices/ColorSensor: add rgb and light
...
also, remove detection of brown color, because this is not supported
2020-02-14 19:26:05 +01:00
Laurens Valk
3c2f1b8444
doc/builtins: update to remove brightness
...
This setting has previously been removed but the docstring was not updated.
2020-02-14 19:24:55 +01:00
Laurens Valk
0ea4c22670
api/tools: add DataLog
2020-02-14 11:47:43 +01:00
Laurens Valk
250dfc63b5
api/tools: remove print
...
Going forward, we are using the builtin print function.
2020-02-13 17:56:11 +01:00
David Lechner
279b0a2a7e
dock/messaging: remove TODO about using Bluetooth address
...
This has been fixed, so we can remove the TODO.
2020-02-12 15:56:03 -06:00
Laurens Valk
57a44265b8
api/nxtdevices: add VernierAdapter
2020-02-12 12:49:40 +01:00
Laurens Valk
d1a9d6f15f
doc/messaging: drop availability
...
This appears to give build errors in derivatives of this repository, so we remove it for now.
2020-02-12 11:20:22 +01:00
David Lechner
aded6ebfe7
doc/messaging: clarify incoming and outgoing
2020-02-12 09:55:28 +01:00
David Lechner
f8ccbb7896
api/messaging: rename ev3messaging module to messaging
2020-02-12 09:55:28 +01:00
Laurens Valk
627701d26a
doc/ev3messaging: organize page
...
Group connection related classes under a header and move it to the top.
Avoid duplicating shared methods. This reduces the page length considerably so it is easier to see the bigger picture. Add examples of data types instead.
2020-02-12 09:55:28 +01:00
Laurens Valk
57c53921ec
api/ev3messaging: don't encode by default
...
The Numeric/Text/Logic will be the convenience classes for common data types, so make the basic class general purpose for sending bytes.
2020-02-12 09:55:28 +01:00
David Lechner
b1382f02b0
move EV3 mailboxes to ev3messaging module
...
- add separate maibox classes
- drop bluetooth module since it is not considered public API
2020-02-12 09:55:28 +01:00
David Lechner
7acbcbd874
initial EV3 bluetooth mailbox docs
2020-02-12 09:55:28 +01:00
David Lechner
f16876cca9
doc/media/ev3dev/image: use substitution to disambiguate screen/image
2020-02-11 11:49:05 -06:00
David Lechner
d9089bcbae
api/media/ev3dev: update for Image API changes
2020-02-11 11:43:54 -06:00