Comments (8)
FWIW, I have an implementation of this that I intend to push soon. As requested, it uses git describe
and falls back on a .version
file in the katapult folder if its not a git repo.
There are several approaches that can be taken to accomplish this, I used Kconfig. By doing so the version is defined in autoconf.h
, making the change minimal. This means that its a good idea to clean before building a new version, since we need to make sure that autoconf.h
is regenerated before the build. Failing to do so could result in a build containing stale version info.
from katapult.
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.
from katapult.
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?
from katapult.
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:
- https://github.com/torvalds/linux/blob/661e504db04c6b7278737ee3a9116738536b4ed4/arch/arm/kernel/head-common.S#L142
- https://github.com/torvalds/linux/blob/661e504db04c6b7278737ee3a9116738536b4ed4/arch/arm/kernel/setup.c#L1102
EDIT: Nevermind. I just realized this issue is about getting the Katapult version from Katapult, not from Klipper.
from katapult.
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 👍🏻
from katapult.
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 flashtool
script should still work for devices flashed with previous versions of Katapult, the software version should return as "?". I have done some initial testing, but would still like to test all of the interfaces before I merge.
The output should look like the following:
Flashing Serial Device /dev/ttyACM0, baud 250000
Attempting to connect to bootloader
Katapult Connected
Software Version: v0.0.1-68-gb768c12
Protocol Version: 1.1.0
Block Size: 64 bytes
Application Start: 0x8002000
MCU type: stm32f103xe
Flashing '/home/eric/klipper/out/klipper.bin'...
from katapult.
Ill run through this a bunch today and tomorrow and provide feedback 👍🏻
from katapult.
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
flashtool
script should still work for devices flashed with previous versions of Katapult, the software version should return as "?". I have done some initial testing, but would still like to test all of the interfaces before I merge.The output should look like the following:
Flashing Serial Device /dev/ttyACM0, baud 250000 Attempting to connect to bootloader Katapult Connected Software Version: v0.0.1-68-gb768c12 Protocol Version: 1.1.0 Block Size: 64 bytes Application Start: 0x8002000 MCU type: stm32f103xe Flashing '/home/eric/klipper/out/klipper.bin'...
Is working for me so far :D
Flashed via USB using flashtool
works as described.
from katapult.
Related Issues (20)
- Issue with make, and Error 127 HOT 1
- flash_can.py not going into boot loader mode
- MKS SKIPR goes not in DFU Mode after canboot HOT 1
- BTT Pi
- Supported STM32 models HOT 2
- [Help needed] - cause of "CONNECT timed out"on btt-mmb HOT 15
- Compiler error BTT EBB36 V1.0
- Reflashing rp2040
- EBB42 1.2 cannot flash klipper or canboot update via CAN HOT 3
- Can't get this to work on Fly ERCF or BTT Manta M8P HOT 4
- Compile Error Mellow SB2040 V1 HOT 1
- STM32407 SKR PRO Can katapult be loaded and function correctly
- Failure to manuconfig for Katapult Pi 5 HOT 1
- Reboot not connecting HOT 2
- Is posible reduce size of the final binary ? HOT 2
- Flashing RP2040 - "No rule to make target 'flash'. Stop. HOT 1
- RPI - UART - SKR 3 - CAN - EBB36 (UART to CAN Bridge) HOT 1
- Custom Board w/ STM32G0B1CEU6 - 512K HOT 2
- Support for STM32G431 HOT 1
- Problem using Katapult with a serial connection HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from katapult.