Skip to content

Commit

Permalink
Make logs better; Update thing that tripped me up in README
Browse files Browse the repository at this point in the history
  • Loading branch information
hexbabe committed Dec 18, 2024
1 parent 1e0ea48 commit 01dabec
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
3 changes: 2 additions & 1 deletion cam/cam.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
}
}
Expand Down

0 comments on commit 01dabec

Please sign in to comment.