Skip to content
This repository has been archived by the owner on Jun 29, 2024. It is now read-only.

Commit

Permalink
Subscribe to remote DeviceDiag server in UCLPC
Browse files Browse the repository at this point in the history
  • Loading branch information
DerAndereAndi committed Apr 9, 2024
1 parent 49bfd00 commit 0f7f85e
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion uclpc/events.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ func (e *UCLPC) HandleEvent(payload spineapi.EventPayload) {
}
}

// the remote device was connected
// the remote entity was connected
func (e *UCLPC) connected(entity spineapi.EntityRemoteInterface) {
// initialise features, e.g. subscriptions, descriptions
if loadControl, err := util.LoadControl(e.service, entity); err == nil {
Expand All @@ -48,6 +48,12 @@ func (e *UCLPC) connected(entity spineapi.EntityRemoteInterface) {
logging.Log().Debug(err)
}
}

if localDeviceDiag, err := util.DeviceDiagnosis(e.service, entity); err == nil {
if _, err := localDeviceDiag.Subscribe(); err != nil {
logging.Log().Debug(err)
}
}
}

// the load control limit description data was updated
Expand Down

0 comments on commit 0f7f85e

Please sign in to comment.