Skip to content

Commit

Permalink
Use model-specific point IDs
Browse files Browse the repository at this point in the history
  • Loading branch information
andig committed Aug 9, 2020
1 parent 5e2245e commit a7f6428
Showing 1 changed file with 30 additions and 30 deletions.
60 changes: 30 additions & 30 deletions meters/sunspec/models.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,19 @@ var modelMap = map[sunspec.ModelId]map[int]map[string]meters.Measurement{
// single phase inverter - float
model111.ModelID: {
0: {
model101.A: meters.Current,
model101.AphA: meters.CurrentL1,
model101.PhVphA: meters.VoltageL1,
model101.Hz: meters.Frequency,
model101.W: meters.Power,
model101.VA: meters.ApparentPower,
model101.VAr: meters.ReactivePower,
model101.PF: meters.Cosphi,
model101.WH: meters.Export,
model101.DCA: meters.DCCurrent,
model101.DCV: meters.DCVoltage,
model101.DCW: meters.DCPower,
model101.TmpCab: meters.HeatSinkTemp,
model111.A: meters.Current,
model111.AphA: meters.CurrentL1,
model111.PhVphA: meters.VoltageL1,
model111.Hz: meters.Frequency,
model111.W: meters.Power,
model111.VA: meters.ApparentPower,
model111.VAr: meters.ReactivePower,
model111.PF: meters.Cosphi,
model111.WH: meters.Export,
model111.DCA: meters.DCCurrent,
model111.DCV: meters.DCVoltage,
model111.DCW: meters.DCPower,
model111.TmpCab: meters.HeatSinkTemp,
},
},
// three phase inverter
Expand Down Expand Up @@ -77,23 +77,23 @@ var modelMap = map[sunspec.ModelId]map[int]map[string]meters.Measurement{
// three phase inverter - float
model113.ModelID: {
0: {
model103.A: meters.Current,
model103.AphA: meters.CurrentL1,
model103.AphB: meters.CurrentL2,
model103.AphC: meters.CurrentL3,
model103.PhVphA: meters.VoltageL1,
model103.PhVphB: meters.VoltageL2,
model103.PhVphC: meters.VoltageL3,
model103.Hz: meters.Frequency,
model103.W: meters.Power,
model103.VA: meters.ApparentPower,
model103.VAr: meters.ReactivePower,
model103.PF: meters.Cosphi,
model103.WH: meters.Export,
model103.DCA: meters.DCCurrent,
model103.DCV: meters.DCVoltage,
model103.DCW: meters.DCPower,
model103.TmpCab: meters.HeatSinkTemp,
model113.A: meters.Current,
model113.AphA: meters.CurrentL1,
model113.AphB: meters.CurrentL2,
model113.AphC: meters.CurrentL3,
model113.PhVphA: meters.VoltageL1,
model113.PhVphB: meters.VoltageL2,
model113.PhVphC: meters.VoltageL3,
model113.Hz: meters.Frequency,
model113.W: meters.Power,
model113.VA: meters.ApparentPower,
model113.VAr: meters.ReactivePower,
model113.PF: meters.Cosphi,
model113.WH: meters.Export,
model113.DCA: meters.DCCurrent,
model113.DCV: meters.DCVoltage,
model113.DCW: meters.DCPower,
model113.TmpCab: meters.HeatSinkTemp,
},
},
model160.ModelID: {
Expand Down

0 comments on commit a7f6428

Please sign in to comment.