-
Notifications
You must be signed in to change notification settings - Fork 73
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
[Enhancement] firmware: Support reporting the current version of Katapult. #87
Comments
The ability to receive Katapult version info as well as UUID in a query response would be very helpful. With multiple versions and since AFAIK there is currently no easy automatic Katapult version updater (and perhaps people would not be easily convinced to use one for updates anyway) it is valuable to know definitively if you need to update and how many revisions you may be skipping when deploying the most current one and/or which version you would be wanting to revert to if you found an incompatibility/problem with newer one. |
This functionality would also be greatly appreciate for everything already mentioned. I'll look into this myself but no guarantees. @Arksine anywhere I should be looking in specific to pulling the current Katapult version on the device? |
Hey, I've been looking into this a while ago and the update to the thread reminded me to write down the takeaways. The only workable solution IMO seems to be passing data to the Klipper payload similar to how bootloaders pass parameters (so-called "atags") to the Linux kernel. It seems to work by reserving a small piece of memory above the stack and passing its address through a register before jumping to the kernel. The address contains a list of structs. Then Klipper would have to pick up the address, validate the data and read it. See:
EDIT: Nevermind. I just realized this issue is about getting the Katapult version from Katapult, not from Klipper. |
FWIW, I have an implementation of this that I intend to push soon. As requested, it uses There are several approaches that can be taken to accomplish this, I used Kconfig. By doing so the version is defined in |
Excellent news! That's roughly what I came up with temporarily but my version involved using json and having version information hosted somewhere (git etc) Yours is much more elegant 👍🏻 |
I have added this commit to PR #126. If some of you want to test it before I merge feel free to do so. The The output should look like the following:
|
Ill run through this a bunch today and tomorrow and provide feedback 👍🏻 |
Is working for me so far :D |
Add a command (or extend CONNECT) to report the version of canboot (possibly from
git describe
or a.version
file if not in a git repo at build time). This would allow for software to query and update canboot (via deployer or other methods) conditionally.The text was updated successfully, but these errors were encountered: