Is there an upload limit/minute/etc (or recommendation) for the camera API?
Is anyone aware of a limit or a suggested frequency for images uploaded to the camera API? I'm currently doing every 30 seconds....a friend is doing every 10 seconds.... What is too much? What is expected?
RE: Is there an upload limit/minute/etc (or recommendation) for the camera API?
sending an image once per 10s per camera is I guess the most frequent that you can get.
another factor is file size of the upload image, which is limited to 16 MB https://connect.prusa3d.com/docs/cameras/openapi/#tag/camera/paths/~1c~1snapshot/put
See my GitHub and printables.com for some 3d stuff that you may like.
RE:
Until we can get web RTC with STUN implemented, we won't do anything faster. I think we're still not rate limiting the camera endpoint but we sure are going to.
RE: Is there an upload limit/minute/etc (or recommendation) for the camera API?
What I'm missing is ability to know what printer is doing in my camera API script.
I would like to slow down pushing jpegs to one every 1-5 minutes when no printing is happening and do it more often (like 1s or 10s) when printing is happning.
Right now I have no choice to always do 1s or 10s interval even when printer is idle.
RE: Is there an upload limit/minute/etc (or recommendation) for the camera API?
Our bad, we should rate limit that endpoint or our servers will burn. 1s should not be allowed. That's 16MB/s per person. that can become insane very quickly.
Yea, there were plans for that, but nothing was decided and we did not touch cameras on PrusaLink from that point onwards. I even had a pseudo time-lapse mode attempt (photo per layer), tried to cover vase mode too. Had to delete all that code as it was not very readable. Anyways, this should happen at some point, there's a financial incentive in it as more photos costs more money. So yea, i think someday it'll happen.
RE: Is there an upload limit/minute/etc (or recommendation) for the camera API?
1s makes no sense anyway as "connect" web interface is not being able to keep up with displaying at that speed 😀 (but api endpoint is fast enough to handle it)
RE: Is there an upload limit/minute/etc (or recommendation) for the camera API?
Web interface would probably keep up if you would have changed the fetch interval. We try to set it in a way that we don't end up DDOSing ourselves