package main

import "github.com/spf13/viper"

// Board def
type Board struct {
	ChannelCount uint   `json:"channelcount"`
	ID           string `json:"id"`
	Name         string `json:"name"`
	Type         string `json:"type"`
}

// Configuration def
type Configuration struct {
	Hostname string `json:"hostname"`
	//	Outlets  map[(uint)]Outlet `json:"outlets"`
	Boards []Board `json:"boards"`
	//	MQTT     MQTTConfig        `json:"mqtt"`
}

// Boards definition
var Boards []Board

func main() {
	var err error
	viper.SetConfigName("v")
	viper.SetConfigType("yaml")
	viper.AddConfigPath(".")

	mock()

}

func mock() {
	b := Board{
		ID:           "6561df75-bf93-43f5-82ac-9b3dda081961",
		Name:         "Internal GPIO",
		Type:         "GPIORelayBoard",
		ChannelCount: 40,
	}
	Boards = append(Boards, b)
}
