From 01dabec777ccdb3a6ac596bd8b2a5588756821a1 Mon Sep 17 00:00:00 2001 From: hexbabe Date: Wed, 18 Dec 2024 15:46:22 -0500 Subject: [PATCH] Make logs better; Update thing that tripped me up in README --- README.md | 3 +++ cam/cam.go | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 58f60a2..c64dbcc 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,9 @@ On the new component panel, copy and paste the following attribute template into } } ``` + +Additionally, make sure to add your configured data manager service to the `depends_on` array of your `video-store` component. + > For more information, see [Configure a Machine](https://docs.viam.com/manage/configuration/). ### Attributes diff --git a/cam/cam.go b/cam/cam.go index 4cf5303..f9ee54c 100644 --- a/cam/cam.go +++ b/cam/cam.go @@ -173,13 +173,14 @@ func newvideostore( for range make([]struct{}, numFetchFrameAttempts) { frame, err := camera.DecodeImageFromCamera(ctx, rutils.MimeTypeJPEG, nil, vs.cam) if err != nil { - vs.logger.Warn("failed to get and decode frame from camera, retrying...", err) + vs.logger.Warn("failed to get and decode frame from camera, retrying. Error: ", err) time.Sleep(retryInterval * time.Second) continue } bounds := frame.Bounds() newConf.Properties.Width = bounds.Dx() newConf.Properties.Height = bounds.Dy() + vs.logger.Infof("received frame width and height: %d, %d", newConf.Properties.Width, newConf.Properties.Height) break } }