Commit Graph
248 Commits
Author SHA1 Message Date
Oskar Weigl 94245a608b explicit cast on num_steps 2018-05-12 22:24:17 -07:00
Oskar Weigl 1ace6422db explicit cast on num_steps 2018-05-12 22:20:41 -07:00
Samuel Sadok e2c14c0082 fix excessive firmware size due to oscilloscope array 2018-04-24 13:49:39 -07:00
Samuel Sadok 861a26735c Merge branch 'sam_disable_dfu' into sam_oskar_testing 2018-04-24 13:41:53 -07:00
Samuel Sadok 5735d5cd96 [firmware] disable DFU feature for board version <= 3.4 because it can break the board 2018-04-24 12:52:41 -07:00
Oskar Weigl f3a484d6db fix deadtime violation check polarity 2018-04-23 20:21:18 -07:00
Samuel Sadok 8b696d29e0 change pos_cpr to pos_cpr_ 2018-04-23 20:10:02 -07:00
Samuel Sadok dc303606b1 fix USB TX lockup issue
When the host reset the connection without reading the response packet first, the TX-empty semaphore would never get released, thereby blocking any further TX communication. This commit just overrides the TX buffer if the semaphore wait times out.
2018-04-23 19:03:55 -07:00
Samuel Sadok 535dbcf481 add system_stats to monitor resource usage 2018-04-23 19:03:55 -07:00
Oskar Weigl 8455c0a5a6 remove old unused version of shunt conductance 2018-04-23 16:05:16 -07:00
Oskar Weigl 1734f86ea5 catch brake resistor deadtime violations 2018-04-23 16:04:17 -07:00
Samuel Sadok 1f504d1d99 Merge branch 'sam_testing' into sam_oskar_testing 2018-04-21 23:11:36 -07:00
Samuel Sadok 96d2bc81f2 Merge branch 'sam_refactoring' into sam_testing 2018-04-21 22:22:42 -07:00
Samuel Sadok e581cc9c90 move enable_dfu_mode() to main.cpp 2018-04-21 22:09:54 -07:00
Oskar Weigl 0ac2871dec drv fault only reads fault regs, add blackside loopback tests 2018-04-21 14:27:37 -07:00
Samuel Sadok 1d7bf6b467 Merge branch 'devel' of github.com:madcowswe/ODrive into sam_refactoring 2018-04-21 00:07:31 -07:00
Samuel Sadok 741a51442f split communication into multiple files 2018-04-20 23:44:55 -07:00
Samuel Sadok abdb037d75 move communication related files 2018-04-20 21:33:39 -07:00
Samuel Sadok dee8efef22 initialize USB interrupt pump before initializing USB device 2018-04-20 21:15:59 -07:00
Oskar Weigl 015532d49b Merge pull request #153 from madcowswe/sam_versions
Add Board & Firmware versions
2018-04-20 00:49:54 -07:00
Samuel Sadok f3b03fb67c change meaning of "hardware_variant" from {0, 1} to voltage 2018-04-19 18:03:51 -07:00
Oskar Weigl 8407721744 fix external interrupts, step dir now working 2018-04-17 03:21:03 -07:00
Samuel Sadok 27574234d5 improve resilience and safety of entering DFU mode
- Disable interrupts before setting the reboot cookie
- Delay after NVIC_SystemReset before jumping to bootloader
  (see comment for an explanation)
- Make a variable for the reboot cookie
- Do reboot cookie checks before C++ static initializers
2018-04-16 23:20:20 -07:00
Oskar Weigl 3addc3bf18 Merge branch 'master' into devel 2018-04-15 17:38:58 -07:00
Oskar Weigl 6e60ec4631 Check for dc bus overvoltage 2018-04-15 17:38:37 -07:00
Oskar Weigl 7d99825988 snap pll_vel to 0 to avoid jitter 2018-04-15 15:55:36 -07:00
Oskar Weigl be50b6ee74 split set_count into linear and circular 2018-04-15 01:07:54 -07:00
Oskar Weigl 0b1bf6f278 implement circular vel pll tracking 2018-04-15 00:38:39 -07:00
Samuel Sadok aee1a7343d add property read/write functionality to ASCII protocol
Command examples:
r vbus_voltage
w axis0.config.enable_step_dir 1
2018-04-14 23:03:03 -07:00
Oskar Weigl 339fe59f30 make pos estimate available 2018-04-14 22:47:52 -07:00
Oskar Weigl d864730ecc add integrator resets to firmware 2018-04-13 18:37:39 -07:00
Samuel Sadok bd292b4775 fix comment 2018-04-13 16:17:05 -07:00
Samuel Sadok 1e14c45276 [HACK] implement oscilloscope 2018-04-10 23:54:13 -07:00
Samuel Sadok a7de97defd [HACK] implement return values 2018-04-10 23:45:58 -07:00
Samuel Sadok 44fd8090e1 add overvoltage protection
The motor phases will go into floating state as soon as an overvoltage condition is detected.
2018-04-10 15:49:16 -07:00
Samuel Sadok b4fa53c849 fix encoder offset calibration and error handling 2018-04-10 15:49:00 -07:00
Samuel Sadok 23009d1e93 add overvoltage protection
The motor phases will go into floating state as soon as an overvoltage condition is detected.
2018-04-10 00:25:19 -07:00
Samuel Sadok 09f361de61 fix encoder offset calibration and error handling 2018-04-09 19:32:36 -07:00
Samuel Sadok 1718e5c397 Merge branch 'sam_python_fixes' into sam_testing 2018-04-09 18:32:38 -07:00
Samuel Sadok d9b7996c8a Merge branch 'sam_refactoring' into sam_testing 2018-04-09 18:23:25 -07:00
Oskar Weigl df16d5781f Merge branch 'devel' into sam_python_fixes 2018-04-09 16:16:47 -07:00
Oskar Weigl fed26a8d00 Merge branch 'devel' into sam_versions 2018-04-09 15:03:26 -07:00
Oskar Weigl 48c8ad0990 Merge branch 'master' into devel 2018-04-08 20:15:59 -07:00
Samuel Sadok 338e9759ce fix how enums are exposed on the protocol
Previously the assumption was made that the compiler
uses 32 bits for each enum value. This assumption was
invalid and meant that when reading/writing from
control_mode you would also read/write to enable_step_dir.
2018-04-08 14:06:30 -07:00
Samuel Sadok 8972e4a8b1 reenable ASCII protocol (formerly "legacy" protocol) 2018-04-07 21:20:26 -07:00
Samuel Sadok e264e1c326 rename legacy protocol to ASCII protocol 2018-04-07 13:25:19 -07:00
Samuel Sadok 95994309ae fix bug where an invalid motor config could be loaded
Before this commit, if the NVM is deemed valid and but the subsequent config load fails (e.g. because of a checksum mismatch), the motor config could be left in an undefined state.

Also a variable user_config_loaded is added to indicate whether the device is using user-saved config or factory defaults.
2018-04-07 12:49:29 -07:00
Samuel Sadok 61983a10da store encoder_configs and controller_configs in NVM 2018-04-07 12:30:37 -07:00
Samuel Sadok 814454da00 set usb task pump priority to osPriorityAboveNormal
osPriorityNormal is the same priority as the communication task. If the USB pump task runs on the same priority, it sometimes fails to respond to the host in time, causing spurious halt conditions.
2018-04-06 22:19:03 -07:00
Samuel Sadok 21f74379de set usb task pump priority to osPriorityAboveNormal
osPriorityNormal is the same priority as the communication task. If the USB pump task runs on the same priority, it sometimes fails to respond to the host in time, causing spurious halt conditions.
2018-04-06 21:19:24 -07:00