Laurens Valk
b4adb50adf
pybricks.robotics: Add Car class.
2024-01-25 20:38:02 +01:00
Laurens Valk
43f0e72a09
blocks: Initial round of images.
2023-11-28 15:06:45 +01:00
Laurens Valk
f509178dab
pybricks.pupdevices.Motor: Document close.
2023-11-20 14:03:12 +01:00
Laurens Valk
fd61866f2b
pybricks.iodevices: Make LWP3 write awaitable.
2023-11-16 12:01:28 +01:00
Laurens Valk
91bc9a5d60
pybricks.hubs.MoveHub: Enable imu orientation.
2023-11-13 11:06:57 +01:00
Laurens Valk
f470f1c510
pupdevices: Fix remote light being external.
...
So it is awaitable.
2023-11-13 08:49:19 +01:00
Laurens Valk
d7f9723f6f
pybricks.common.Accelerometer: Move tilt to simple.
...
The Move Hub has it too now.
2023-11-13 08:49:15 +01:00
Laurens Valk
e7377dff31
pybricks.pupdevices.Motor: Clarify profile setting.
2023-10-26 14:31:16 +02:00
Laurens Valk
d935841399
pybricks.robotics.DriveBase: Add brake.
2023-10-26 14:18:56 +02:00
David Lechner
3335042218
ubuiltins: add set class
...
Add type stubs and docs for builtin `set` type.
Issue: https://github.com/pybricks/support/issues/402
2023-10-26 09:21:41 +02:00
Laurens Valk
209fba5c7e
pybricks.tools: Document multitasking.
2023-10-24 17:05:10 +02:00
Laurens Valk
faf11581c0
pybricks.tools: Document hub_menu.
...
Fixes https://github.com/pybricks/pybricks-api/issues/144
2023-10-24 16:23:59 +02:00
Laurens Valk
8819446513
pybricks.common.BLE: Update broadcast API.
...
Match firmware updates.
2023-10-24 10:40:52 +02:00
Laurens Valk
6bbdccb25f
pybricks.hubs.ThisHub.storage: Fix duplicate self.
...
Fixes https://github.com/pybricks/pybricks-api/issues/146
2023-10-23 16:36:13 +02:00
Laurens Valk
1a49d396d2
pybricks.robotics: Document use_gyro.
2023-10-23 15:39:52 +02:00
David Lechner
821a3e4455
pybricks.*: add MaybeAwaitable types
...
Many blocking functions now return Awaitable[T] when the async run
loop is running. The static analysis tools don't have a way of
knowing this, so the best we can do is return both types so that
x = method() and x = await method() both work mostly as expected.
2023-06-12 17:04:09 -05:00
David Lechner
41b9ce71dd
pybricks.tools: add read_input_byte()
...
This adds stubs and docs for the new `pybricks.tools.read_input_byte()`
function.
2023-06-12 11:06:20 -05:00
David Lechner
4dc289ad61
pybricks.common.BLE.broadcast: fix missing `
...
This caused bad formatting.
2023-05-16 16:02:13 -05:00
David Lechner
3274cef849
pybricks.common: Add new BLE class.
...
This adds a new BLE class that is used for connectionless broadcasting/
observing on hubs with built-in Bluetooth Low Energy.
Also see https://github.com/pybricks/pybricks-micropython/pull/158 .
2023-05-16 14:46:53 -05:00
David Lechner
8e5891d9e8
all: spelling
...
Misc spelling fixes.
2023-05-10 14:16:15 -05:00
Laurens Valk
be9f99d41b
pybricks.tools: Add category headings.
2023-04-21 13:59:16 +02:00
Laurens Valk
870aae83c0
pybricks.tools: Document cross product.
2023-04-21 13:39:08 +02:00
Laurens Valk
9cde749e8a
pybricks.geometry: Drop module.
...
See https://github.com/pybricks/pybricks-micropython/pull/160
2023-04-21 13:33:19 +02:00
Laurens Valk
8bca5eb6e4
pybricks.robotics: Add GyroDriveBase.
2023-04-21 10:42:30 +02:00
Laurens Valk
95a12a7386
pybricks.robotics: Drop note suggesting to flip motors.
...
This will still work, but it is asking for trouble when including the gyro.
So it is probably better not to mention this at all.
2023-04-21 10:42:30 +02:00
Laurens Valk
98f2bb27fe
pybricks.robotics.DriveBase: Drop positive direction.
...
This reverts commit e4650cb1c9 .
This is not needed for gyro support, so it is better to remove it
before it is ever released.
2023-04-21 10:42:30 +02:00
Laurens Valk
fdbd078388
pybricks._common.IMU: Heading is clockwise positive.
...
This is not a breaking change because heading() was never implemented until now.
2023-04-21 10:42:30 +02:00
Laurens Valk
ccd2b46819
pybricks.robotics.DriveBase: Revert gyro use via init.
...
This reverts commit dadaab6f61 .
We will introduce a separate class instead.
2023-04-21 10:42:30 +02:00
Laurens Valk
c0cb05dd74
pybricks.robotics.DriveBase: Document use of gyro.
2023-04-21 10:42:30 +02:00
Laurens Valk
b183e1420a
pybricks.pupdevices.Motor: Document speed time window.
2023-04-21 10:42:30 +02:00
Laurens Valk
b311c54261
pybricks._common.IMU: Change settings setter.
2023-04-21 10:42:30 +02:00
Laurens Valk
bb37b94f5e
pybricks._common.IMU: Add imu status.
2023-04-21 10:42:30 +02:00
Laurens Valk
5b25606afa
pybricks._common.IMU: Add rotation and orientation.
...
Also update implementation status for heading and reset_heading.
2023-04-21 10:42:30 +02:00
Laurens Valk
8172d11ef6
urandom: Fix formula in getrandbits.
2023-03-28 08:50:00 +02:00
Laurens Valk
c415296b71
pybricks._common.Motor: Document profile.
...
Fixes https://github.com/pybricks/support/issues/966
2023-03-20 15:12:36 +01:00
Laurens Valk
e4650cb1c9
pybricks.robotics.DriveBase: Document positive direction.
...
Fixes https://github.com/pybricks/support/issues/992
2023-03-20 14:22:25 +01:00
Laurens Valk
91154a394c
pybricks.robotics.DriveBase: Clarify settings method.
...
Fixes https://github.com/pybricks/support/issues/882
2023-03-20 14:00:42 +01:00
David Lechner
3c36010c04
pybricks.ev3devices: Fix Gyro direction parameter name.
...
The actual implemented name is `direction`, not `positive_direction`.
Fixes: https://github.com/pybricks/support/issues/509
2023-03-20 13:56:16 +01:00
Laurens Valk
b40c3989aa
pybricks.common.Motor: Add Model() class instance.
...
This is mainly used to debug the motor model, and to quickly select the
feedback parameters. This is useful when adding or configuring new motor
types.
Reading the estimated speed can also be useful in advanced applications
where the user builds their own PID controller.
We may choose to hide this method from the documentation before the
release.
2023-02-09 10:25:15 +01:00
Laurens Valk
428bca79ab
pybricks.common.Control: Document deadzone.
2023-02-02 14:45:34 +01:00
David Lechner
236bda5f31
ubuiltins.round: Fix example.
...
The example did not have proper line breaks between statements.
Also add an additional example using f-strings.
2022-12-28 14:09:18 -06:00
Laurens Valk
72f5cb6827
micropython: Use separate keys for CTRL + C.
...
Since each :kbd: key is rendered as a button, it is more intuitive to
render them separately. (There is no CTRL-C button.)
Fixes https://github.com/pybricks/pybricks-api/issues/125
2022-12-08 09:32:08 +01:00
Laurens Valk
4da4ce8f7c
pybricks.robotics.DriveBase: Add clarifying comments.
...
Fixes https://github.com/pybricks/support/issues/698
2022-12-06 16:38:31 +01:00
Laurens Valk
eff6eaa253
jedi: Add ustruct, json modules.
2022-12-02 15:17:55 +01:00
Laurens Valk
99d5210313
pybricks.robotics.DriveBase: Add stalled, done.
2022-12-02 12:43:24 +01:00
Laurens Valk
631cf31a07
pybricks.common.Motor: Document when settings take effect.
...
This updates how and when settings take effect. In this release, you can
change them even while the motor is moving. Some settings do not
take effect right away, as now indicated in the relevant methods.
See also https://github.com/pybricks/pybricks-api/issues/105
2022-12-02 12:10:31 +01:00
Laurens Valk
115ae0d856
pybricks.common.Motor: Add done, stalled, load.
...
These used to be implemented as part of the Control object,
but now they are available directly on the motor.
This way they:
- Also give useful values when control is passive, via dc().
- Can be supported on Move Hub
- Give useful values for drive bases (see next commits).
Fixes https://github.com/pybricks/pybricks-api/issues/115
2022-12-02 12:02:22 +01:00
Laurens Valk
4d360d2b01
pybricks.parameters: Reduce floating warning to note.
...
This is a good case of a box. But nothing blows up if you try it, so a note suffices.
2022-12-01 16:59:08 +01:00
Laurens Valk
52cb0fe81e
ubuiltins: Fix missing types on print args.
2022-12-01 16:49:45 +01:00
Laurens Valk
961cebe48b
ustruct: Document modules.
2022-12-01 16:48:20 +01:00