customcamera

package module
v0.0.0-...-9e736f7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

README

[!NOTE] This is a module template. Read the instructions for a step by step guide on how to create your module.

modular resource

This module implements... With this model, you can...

Requirements

Add instructions here for any requirements.

Build and run

To use this module, follow the instructions to add a module from the Viam Registry and select the <INSERT API NAMESPACE>:<INSERT API NAME>:<INSERT MODEL> model from the [<INSERT MODEL> module](https://app.viam.com/module//).

Configure your camera

[!NOTE] Before configuring your camera you must create a machine.

Navigate to the Config tab of your machine's page in the Viam app. Click on the Components subtab and click Create component. Select the <INSERT API NAME> type, then select the <INSERT MODEL> model. Click Add module, then enter a name for your camera and click Create.

On the new component panel, copy and paste the following attribute template into your camera’s Attributes box:

{
  <INSERT SAMPLE ATTRIBUTES>
}

[!NOTE] For more information, see Configure a Machine.

Attributes

The following attributes are available for <INSERT API NAMESPACE>:<INSERT API NAME>:<INSERT MODEL> camera's:

Name Type Inclusion Description
todo1 string Required TODO
todo2 string Optional TODO
Example configuration
{
  <INSERT SAMPLE CONFIGURATION(S)>
}
Next steps

Add any additional information you want readers to know and direct them towards what to do next with this module. For example:

  • To test your...
  • To write code against your...

Troubleshooting

Add troubleshooting notes here.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Model = resource.NewModel("viam-labs", "go-module-templates-camera", "customcamera")
)

Here is where we define your new model's colon-delimited-triplet (viam-labs:go-module-templates-camera:customcamera) viam-labs = namespace, go-module-templates-camera = repo-name, customcamera = model name. TODO: Change model namespace, family (often the repo-name), and model. For more information see https://docs.viam.com/registry/create/#name-your-new-resource-model

Functions

This section is empty.

Types

type Config

type Config struct {
	ArgumentOne int    `json:"one"`
	ArgumentTwo string `json:"two"`
}

TODO: Change the Config struct to contain any values that you would like to be able to configure from the attributes field in the component configuration. For more information see https://docs.viam.com/build/configure/#components

func (*Config) Validate

func (cfg *Config) Validate(path string) ([]string, error)

Validate validates the config and returns implicit dependencies. TODO: Change the Validate function to validate any config variables.

Directories

Path Synopsis
cmd
module
Package main is a module which serves the customcamera custom model.
Package main is a module which serves the customcamera custom model.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL