Skip to content

Commit

Permalink
Merge branch 'master' into devel
Browse files Browse the repository at this point in the history
  • Loading branch information
madcowswe committed Oct 9, 2020
2 parents df3b3e9 + 573aa96 commit f37a50f
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Arduino/ODriveArduino/ODriveArduino.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ bool ODriveArduino::run_state(int axis, int requested_state, bool wait) {
do {
delay(100);
serial_ << "r axis" << axis << ".current_state\n";
} while (readInt() != requested_state && --timeout_ctr > 0);
} while (readInt() != AXIS_STATE_IDLE && --timeout_ctr > 0);
}

return timeout_ctr > 0;
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,15 @@ Please add a note of your changes below this heading if you make a Pull Request.
## [0.5.1] - 2020-09-27
### Added
* Added motor `torque_constant`: units of torque are now [Nm] instead of just motor current.
* Added `motor.config.torque_lim`: limit for motor torque in [Nm].
* [Motor thermistors support](docs/thermistors.md)
* Enable/disable of thermistor thermal limits according `setting axis.<thermistor>.enabled`.
* Introduced `odrive-interface.yaml` as a root source for the ODrive's API. `odrivetool` connects much faster as a side effect.
* Added torque_constant and torque_lim to motor config

### Changed
* **`input_pos`, `input_vel`, `pos_estimate_linear`, `pos_estimate_circular`, are now in units of [turns] or [turns/s] instead of [counts] or [counts/s]**
* **`pos_gain`, `vel_gain`, `vel_integrator_gain`, are now in units of [(turns/s) / turns], [Nm/(turns/s)], [Nm/(turns/s * s)] instead of [(counts/s) / counts], [A/(counts/s)], [A/((counts/s) * s)].** `pos_gain` is not affected. Old values of `vel_gain` and `vel_integrator_gain` should be multiplied by `torque_constant * encoder cpr` to convert from the old units to the new units. `torque_constant` is approximately equal to 8.27 / (motor KV).
* `axis.motor.thermal_current_lim` has been removed. Instead a new property is available `axis.motor.effective_current_lim` which contains the effective current limit including any thermal limits.
* `axis.motor.get_inverter_temp()`, `axis.motor.inverter_temp_limit_lower` and `axis.motor.inverter_temp_limit_upper` have been moved to seperate fet thermistor object under `axis.fet_thermistor`. `get_inverter_temp()` function has been renamed to `temp` and is now a read-only property.
* `axis.config.counts_per_step` is now `axis.config.turns_per_step`
Expand Down
5 changes: 4 additions & 1 deletion Firmware/odrive-interface.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -735,12 +735,15 @@ interfaces:
pos_gain:
type: float32
unit: (turn/s) / turn
doc: units = (turn/s) / turn, default = 20
vel_gain:
type: float32
unit: 'Nm/(turn/s)'
doc: units = 'Nm/(turn/s), default = 0.16
vel_integrator_gain:
type: float32
unit: Nm/(turn/s * s)
doc: units = Nm/(turn/s * s), default = 0.32
vel_limit:
type: float32
unit: turn/s
Expand Down Expand Up @@ -1151,4 +1154,4 @@ valuetypes:
HighCurrent:
#LowCurrent: # not implemented
Gimbal: {value: 2}
Acim:
Acim:
3 changes: 3 additions & 0 deletions docs/assets/css/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -337,6 +337,9 @@ header li {
.navitem a {
display: block;
width: 100%;
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
}

.levelbar {
Expand Down
4 changes: 2 additions & 2 deletions docs/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ See [here](api/odrive.axis.axisstate) for a description of each state.
### Control Mode
The default control mode is position control.
If you want a different mode, you can change `<axis>.controller.config.control_mode`.
Possible values are listed [here](api/odrive.axis.controller.controlmode).
Possible values are listed [here](api/odrive.controller.controlmode).

### Input Mode

Expand All @@ -51,7 +51,7 @@ As of version v0.5.0, ODrive now intercepts the incoming commands and can apply

Modes can be selected by changing `<axis>.controller.config.input_mode`.
The default input mode is `INPUT_MODE_PASSTHROUGH`.
Possible values are listed [here](api/odrive.axis.controller.inputmode).
Possible values are listed [here](api/odrive.controller.inputmode).

## System monitoring commands

Expand Down
2 changes: 2 additions & 0 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -378,3 +378,5 @@ If you have any issues or any questions please get in touch. The [ODrive Communi
## Upgrading from 0.4.12
A new version (0.5.1) of ODrive firmware has released, complete with a new odrivetool. Follow the installation instructions, making sure to add the `--upgrade` flag to pip commands, and check out the [Changelog](../CHANGELOG.md) for changes!
The odrivetool will stage and restore your configuration. This probably isn't wise for the 0.4.12 -> 0.5.1 upgrade, so we suggest using `odrv0.erase_configuration()` immediately after connecting the first time.

0 comments on commit f37a50f

Please sign in to comment.