REST API for Buddy (Core One version) available
Hi there,
i'm running Core One with USB camera locally without internet connection (is on wifi). Same applies to the printer. Is there any way to manage the camera without Prusa Connect app? Local RTSP stream works fine.
For example pull snapshots from the camera via wifi, setting the resolution, and so on. Is there any public REST API available for the camera?
thanks
RE: REST API for Buddy (Core One version) available
Not really. The firmwarec calls to the PrusaConnect API and gets some commands back. The addresses are baked into the printer firmware.
Not sure about certificates but it might be possible to do MITM injection, but probably would require some tweaking.
See my GitHub and printables.com for some 3d stuff that you may like.
RE: REST API for Buddy (Core One version) available
i know how it currently is. I have a packet capture saved, there is only TLS traffic to Prusa Cloud and nothing else. But since the camera has plain RTSP, there might be something more 😀 hence my question
if I don't find other way, capturing a snapshot from RTSP stream is the alternative way to go. Maybe there is someone else who knows more
RE:
you can save a frame or fragment of the stream with ffmpeg
ffmpeg -y -i rtsp://192.168.1.75/live -y -vframes 1 -q:v 1 -f image2 -update 1 out.jpg
where 192.168.1.75 is an ip of the Buddy3d camera streaming via rtsp
or video, assuming it's 25fps, then '-vframes 750' is 30s
ffmpeg -y -i rtsp://192.168.1.75/live -y -vframes 750 -q:v 1 -update 1 -f mp4 out.mp4
See my GitHub and printables.com for some 3d stuff that you may like.
RE: REST API for Buddy (Core One version) available
yes thanks, that's what i meant with "capturing a snapshot from RTSP stream is the alternative way to go" 🙂
what i'm asking for is a specific endpoint like regular cameras have. E.g. /snapshot.cgi
but i think here is something usable: https://github.com/nvtkaszpir/3d-print/tree/main/prusa-buddy3d-camera
RE: REST API for Buddy (Core One version) available
I haven't poked in the binary, not sure if this kind of endpoint is exposed at all, when you look at the open ports then only rtsp is listening. i need to check the newer binaries with webrtc support, though.
See my GitHub and printables.com for some 3d stuff that you may like.