circup API?
Hello!
I created a tool a few years ago that uses some non-public methods from circup (basically just device folder detection). When updating it recently I had to make changes as circup's internal code had changed.
The tool is circdeploy that copies project files from a code folder to a device. (I don't like editing the device files directly)
- Would it be possible to expose an official
circupAPI that my tool could use instead of relying on non-public methods that may change? - Or alternatively is the functionality in
circdeploysomething that you would be interested in having adding tocircup? - I'm pretty sure nobody but me uses
circdeploy, as I've never advertised it. So I guess this is its debut!
Cheers!
As far as detecting the USB drive goes, circup just looks for a drive named CIRCUITPY, there's no great magic to it. I don't know that there's a need for a public API for that. Note that circup now has wwshell, a tool to manage files via the web workflow if you want to do that too.
But maybe it would be interesting to turn the backends into a separate public API, to make tools that can be agnostic to the type of backend used.
If you want, you can look into discotool, I made it specifically to be able to find microcontroller boards, including their serial port and drive no matter what its name is, on all platforms. It is both a command line tool and a python module. https://github.com/Neradoc/discotool?tab=readme-ov-file#module