Documentation ¶
Index ¶
Constants ¶
View Source
const ( NEWLORHAMMER = "newLorhammer" // prevent orchestrator new lorhammer is here LORHAMMER -> ORCHESTRATOR LORHAMMERADDED = "lorhammerAdded" // orchestrator has received lorhammer infos ORCHESTRATOR -> LORHAMME INIT = "init" // send init (lorawan info) ORCHESTRATOR -> LORHAMMER REGISTER = "register" // send lorawan sensors to provision LORHAMMER -> ORCHESTRATOR START = "start" // send start after sensors provisioning ORCHESTRATOR -> LORHAMMER STOP = "stop" // send stop to finish test ORCHESTRATOR -> LORHAMMER SHUTDOWN = "shutdown" // kill lorhammers ORCHESTRATOR -> LORHAMMER )
All commands for communication between orchestrator and lorhammer
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CMD ¶
type CMD struct { CmdName CommandName `json:"cmd"` Payload json.RawMessage `json:"payload"` }
CMD is the stuct for communication between orchestrator and lorhammer
type CommandName ¶
type CommandName string
CommandName is a type to be sure command are send (and not all string possible)
type Gateway ¶
type Gateway struct { Nodes []*Node NsAddress string MacAddress lorawan.EUI64 RxpkDate int64 PayloadsReplayMaxLaps int AllLapsCompleted bool ReceiveTimeoutTime time.Duration }
Gateway represent a lorawan gateway
type Init ¶
type Init struct { NsAddress string `json:"nsAddress"` NbGateway int `json:"nbGatewayPerLorhammer"` NbNode [2]int `json:"nbNodePerGateway"` NbScenarioReplayLaps int `json:"nbScenarioReplayLaps"` ScenarioSleepTime [2]string `json:"scenarioSleepTime"` GatewaySleepTime [2]string `json:"gatewaySleepTime"` AppsKey string `json:"appskey"` Nwskey string `json:"nwskey"` WithJoin bool `json:"withJoin"` Payloads []Payload `json:"payloads"` RxpkDate int64 `json:"rxpkDate"` ReceiveTimeoutTime string `json:"receiveTimeoutTime"` Description string `json:"description"` RandomPayloads bool `json:"randomPayloads"` }
Init is the struc send by orchestrator to lorhammer
type NewLorhammer ¶
type NewLorhammer struct {
CallbackTopic string
}
NewLorhammer is the struct used by lorhammer to prevent orchestrator
type Node ¶
type Node struct { DevAddr lorawan.DevAddr DevEUI lorawan.EUI64 AppEUI lorawan.EUI64 AppKey lorawan.AES128Key AppSKey lorawan.AES128Key NwSKey lorawan.AES128Key JoinedNetwork bool Payloads []Payload NextPayload int PayloadsReplayLap int RandomPayloads bool Description string }
Node represent a lorawan sensor
type Payload ¶
Payload struct define a payload with timestamp date attached { "value": "a string", "date": <timestamp>}
Click to show internal directories.
Click to hide internal directories.