Commit Graph

137 Commits

Author SHA1 Message Date
pjohnson
d78119e29f Modified docs and communication interfaces to reflect change from A to Nm for motor control input.
Renamed vel_integrator_current_ to vel_integrator_torque_
Removed input_current_ from controller, added input_torque_
2020-06-16 17:10:36 -04:00
pjohnson
e2527ec468 added torque_constant to motor config struct and interface file
changed all instances of current_setpoint to torque_setpoint
modified limitVel() to use torque instead of current units
removed effective_current_lim, added effective_torque_lim()
added torque_lim to motor config struct and interface file
2020-06-16 15:55:18 -04:00
Samuel Sadok
653c4c327e Merge remote-tracking branch 'origin/devel' into feature/interface_autogen_merged 2020-05-22 21:27:58 +02:00
Samuel Sadok
b3912d58c2 revert numerical static_cast to C style casts
As per https://github.com/madcowswe/ODrive/pull/410#discussion_r427725994
2020-05-20 13:26:14 +02:00
Samuel Sadok
3d07325022 remove aligned formatting of assignments 2020-05-20 12:27:28 +02:00
Samuel Sadok
3d710a5385 don't treat watchdog_timeout == 0 as special case
this special treatment is now redundant with enable_watchdog
2020-05-20 11:57:04 +02:00
Samuel Sadok
e4d70a22b7 Initial implementation of interface autogenerator.
TODO:
 - write to endpoints from float (for PWM/analog input)
 - ascii protocol
2020-05-14 23:05:02 +02:00
Samuel Sadok
da7f719283 improve naming consistency between code and fibre
Consistent naming makes code autogeneration easier.
This commit does not claim that the exported names of the variables were
more sensible than the in-code names. However changing the exported
names can break external tools and needs to happen in a controlled and
documented way.
2020-05-14 11:16:32 +02:00
Samuel Sadok
50ecdef860 move DC overcurrent/undercurrent checks to update_brake_current()
The checks now take into account the brake current.
Expose ibus on fibre.
2020-05-05 18:16:06 +02:00
Oskar Weigl
d002a74d24 rename psu current fault levels 2020-05-01 16:37:20 -07:00
Unknown
3d2d0f0e1a Clean up and modernize axis task_chain 2020-04-27 15:27:43 -04:00
Samuel Sadok
237a50bfc9 add step/dir input tests 2020-04-21 15:57:26 +02:00
Unknown
fb46103498 Add doctest, fix drv8301 warning 2020-03-27 21:22:04 -04:00
Unknown
f9b4c78667 Merge remote-tracking branch 'madcowswe/devel' into RazorsEdge 2020-01-30 21:30:34 -05:00
Oskar Weigl
8cbc09e168 feed watchdog on enter closed loop 2020-01-30 16:16:39 -08:00
Unknown
1bdea53ec8 Improve testability 2020-01-08 22:11:50 -05:00
Unknown
62654ed966 Fix avoid transients at startup 2020-01-01 21:38:17 -05:00
Unknown
c9d35415db Configure motors before encoders to avoid SPI collision 2020-01-01 21:37:04 -05:00
Unknown
f127df72f1 Add stack_size vars, reduce stack usage 2019-10-26 14:28:06 -04:00
Samuel Sadok
82e8cd64fb cosmetic changes 2019-09-27 18:01:38 +02:00
Samuel Sadok
8ce66c6ec7 change power supply limit from watts to amps 2019-09-27 18:01:33 +02:00
Samuel Sadok
c6f473936f Merge remote-tracking branch 'origin/devel' into RazorsFrozen 2019-09-27 13:04:58 +02:00
Samuel Sadok
f8ea7d5684 [homing] make separate control mode
[endstops] enable in all control modes
[load encoder] use load encoder more consequently
2019-09-23 12:23:27 +02:00
samuelsadok
c49e679bd9 fix bad use of memcpy
memcpy is not guaranteed to work with overlapped memory areas, however memmove is.
Apart from the semantic difference this fixes a compiler warning and possibly previously unexplained occurrences of `ERROR_INVALID_STATE`.
2019-09-19 10:10:51 +02:00
Unknown
9e782cce7b Revert "Formatting pass"
This reverts commit 2b58d15d8d.
2019-09-15 01:15:51 -04:00
Unknown
5a3fc8690f Remove homing offset compensation 2019-09-09 23:18:00 -04:00
Unknown
3f4433f50d Enable rudimentary dual-encoder support 2019-09-01 17:02:15 -04:00
Unknown
4ad2fc60a8 Reset vel_integrator_current when going into closed loop mode 2019-08-29 20:24:09 -04:00
Unknown
b880d7986e Fix homing offset compensation per @riewert 2019-08-26 22:32:45 -04:00
Unknown
2e3768c329 Start moving casts and math functions to std:: 2019-08-25 17:13:10 -04:00
Unknown
ec2cd83f1f Add compensation term for axis debounce during homing 2019-08-24 23:48:16 -04:00
Unknown
36f4dc0ada Add watchdog enable option 2019-08-24 21:50:59 -04:00
Unknown
2b58d15d8d Formatting pass 2019-08-20 23:13:54 -04:00
Paul Guenette
82beb16ae5 Fix odd behaviour during homing
Because the accelerations and velocities are so low during this phase, we were overshooting quite a bit.  Also, the pos_setpoint was wrong during the calculation of the trap_traj, so it was all sorts of screwed up.
2019-08-11 15:24:35 -04:00
Paul Guenette
ca93c0e2d2 Add isHomed indicator 2019-08-11 12:30:24 -04:00
Paul Guenette
fbd7ab2738 Improve the behaviour of the HOMING sequence 2019-07-18 17:29:21 +02:00
Paul Guenette
1494cb333f Merge remote-tracking branch 'madcowswe/lockin-refactor' into RazorsEdge 2019-06-22 17:04:29 +02:00
Ben Wang
a3755b848d use default constructor for general lockin struct 2019-06-03 12:06:50 -04:00
Paul Guenette
e8a6698fa5 Merge branch 'devel' into RazorsEdge 2019-06-03 00:30:25 +02:00
Ben Wang
f69685df13 refactor lockin mode into separate variables for sensorless spinup, encoder calibration and general (user initiated) mode 2019-05-29 16:26:07 -04:00
Paul Guenette
12664d141d Remove the ability to home the axis with requested_state = AXIS_HOMING 2019-05-27 17:17:20 +02:00
Paul Guenette
d95d0bc283 Fix call to input_pos_updated() 2019-05-26 22:39:37 +02:00
Paul Guenette
0d6be2869b step callback needs to increment input_pos, not pos_setpoint 2019-05-26 19:52:46 +02:00
Paul Guenette
cf9857651e Make Homing use input_xxx values 2019-05-25 14:54:41 +02:00
Paul Guenette
cc36edeabf Merge branch 'anticogging_saver' into RazorsEdge 2019-05-25 14:16:46 +02:00
Paul Guenette
820fd72ae8 Merge branch 'bugfix/watchdog_fix' into RazorsEdge 2019-05-25 14:15:24 +02:00
Paul Guenette
987a14b8c7 Merge branch 'feature/63-dc-bus-limit' into RazorsEdge 2019-05-25 14:14:20 +02:00
Paul Guenette
104e4413c9 Fix input_filter integration issues 2019-05-25 14:07:44 +02:00
Paul Guenette
687cf5b877 Merge branch 'Endstops' into develop 2019-05-25 13:53:38 +02:00
Paul Guenette
2abae9034b Change how the watchdog_reset_ value is handled 2019-05-24 23:54:38 +02:00