nfc

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthorizedTags

type AuthorizedTags struct {
	AuthorizedTags []UserTag `json:"authorized_tags"`
}

type Nfc

type Nfc struct {
	// contains filtered or unexported fields
}

func NewNfcTagsService

func NewNfcTagsService(request warp.Request) *Nfc

func (*Nfc) Config

func (n *Nfc) Config() (AuthorizedTags, error)

func (*Nfc) SeenTags

func (n *Nfc) SeenTags() ([]Tag, error)

func (*Nfc) StartCharging

func (n *Nfc) StartCharging(tag UserTag) error

func (*Nfc) StopCharging

func (n *Nfc) StopCharging() error

type Tag

type Tag struct {
	Type     int    `json:"tag_type"`
	Id       string `json:"tag_id"`
	LastSeen int    `json:"last_seen"`
}

type UserTag

type UserTag struct {
	UserId int    `json:"user_id"`
	Type   int    `json:"tag_type"`
	Id     string `json:"tag_id"`
}

Jump to

Keyboard shortcuts

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