-
Notifications
You must be signed in to change notification settings - Fork 0
Add ODrive motor_temperature to TracksHardware
#4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
| {config.name}.shadow({config.name}_front) | ||
| ''') | ||
| core_message_fields = [f'{config.name}.linear_speed:3', f'{config.name}.angular_speed:3'] | ||
| if config.odrive_version == self.ERROR_FLAG_VERSION: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reading out the temperatures requires a different version than just checking for motor errors. This will lead to errors.
@Johannes-Thiel What do you think about ditching ERROR_FLAG_VERSION and instead add booleans to the configuration that enable the features? Like check_errors and check_temperatures (but we should change the naming 😆)
We could also use better versioning for our ODrive fork to differentiate the versions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes that is a good idea, but we have to keep in mind, that the check_temperatures already implements the check_errors .
I would like to finish the calibration via can firmware. With that change we could increase the minor version of the fork.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For temperature, we might not need the flag for the ODrive firmware version. We depend on the latest Lizard version. If Lizard doesn’t receive the temperature from the ODrive, it will return 0, and we interpret that as N/A. This won’t break the UI or our code. However, we should include a note with a link to the Lizard documentation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would the simplest way, yes.
However I'm not a fan of values that could be reasonable, but need background knowledge to understand them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes i get your point but the limiting factors here have so many levels, that ist is almost impossible to get the right flag. For this it is easier and safer to rely on Lizard and the ODrive firmware.
We want to be able to see the ODrive temperature. For this, we use the
motor_temperatureproperty from Lizard. Lizard will return0if there is no measurement. Since the chance that the actualmotor_temperatureis0is very small, we will displayN/Ain this case. This will help the user understand that the temperature sensor is not working for their device.