-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Increment version to 0.9.3, based on OpenDSS revision 2136 and includ…
…e PM patchset.
- Loading branch information
Showing
18 changed files
with
5,134 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
src/patchset/0001-PM-to-Classic-Add-NumTerminals-to-Capacitor.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
From 9b3174d692c9a2f87ad4ff19e2c58d1f7f6857ea Mon Sep 17 00:00:00 2001 | ||
From: Paulo Meira <10246101+PMeira@users.noreply.github.com> | ||
Date: Fri, 16 Feb 2018 16:06:38 -0200 | ||
Subject: [PATCH] PM to Classic: Add NumTerminals to Capacitor | ||
|
||
--- | ||
Source/PDElements/Capacitor.pas | 9 ++++++++- | ||
1 file changed, 8 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/Source/PDElements/Capacitor.pas b/Source/PDElements/Capacitor.pas | ||
index 5ba88ae..af01111 100644 | ||
--- a/Source/PDElements/Capacitor.pas | ||
+++ b/Source/PDElements/Capacitor.pas | ||
@@ -85,6 +85,7 @@ TYPE | ||
Bus2Defined :Boolean; | ||
|
||
SpecType :Integer; | ||
+ NumTerm : Integer; // Flag used to indicate The number of terminals | ||
|
||
function get_States(Idx: Integer): Integer; | ||
procedure set_States(Idx: Integer; const Value: Integer); | ||
@@ -123,6 +124,8 @@ TYPE | ||
Property NomKV:Double Read kvrating; | ||
Property LastStepInService:Integer Read FLastStepInService Write set_LastStepInService; | ||
|
||
+ Property NumTerminals:Integer Read NumTerm; // Property to know if the capacitor has 2 terminals | ||
+ | ||
end; | ||
|
||
VAR | ||
@@ -341,7 +344,10 @@ BEGIN | ||
CASE ParamPointer OF | ||
0: DoSimpleMsg('Unknown parameter "'+ParamName+'" for Object "Capacitor.'+Name+'"', 450); | ||
1: CapSetbus1(param); | ||
- 2: Setbus(2, param); | ||
+ 2: Begin | ||
+ Setbus(2, param); | ||
+ NumTerm := 2; // Specifies that the capacitor is not connected to ground | ||
+ End; | ||
3:{ Numphases := Parser.IntValue}; // see below | ||
4: InterpretDblArray (Param, FNumSteps, FkvarRating); | ||
5: kvRating := Parser.Dblvalue; | ||
@@ -526,6 +532,7 @@ BEGIN | ||
Bus2Defined := FALSE; | ||
|
||
RecalcElementData; | ||
+ NumTerm := 1; | ||
|
||
InitPropertyValues(0); | ||
END; | ||
-- | ||
2.10.0.windows.1 | ||
|
48 changes: 48 additions & 0 deletions
48
src/patchset/0002-PM-to-Classic-Port-some-memory-checks.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
From 15d2a477a4dcf5024759a1a3101bc2282baf52fb Mon Sep 17 00:00:00 2001 | ||
From: Paulo Meira <10246101+PMeira@users.noreply.github.com> | ||
Date: Fri, 16 Feb 2018 16:09:12 -0200 | ||
Subject: [PATCH] PM to Classic: Port some memory checks | ||
|
||
--- | ||
Source/Meters/EnergyMeter.pas | 4 ++++ | ||
1 file changed, 4 insertions(+) | ||
|
||
diff --git a/Source/Meters/EnergyMeter.pas b/Source/Meters/EnergyMeter.pas | ||
index 12cc190..fd28c88 100644 | ||
--- a/Source/Meters/EnergyMeter.pas | ||
+++ b/Source/Meters/EnergyMeter.pas | ||
@@ -2842,6 +2842,7 @@ begin | ||
If (EnergyMeterClass.DI_Verbose) Then Begin | ||
|
||
This_Meter_DIFileIsOpen := TRUE; | ||
+ if DI_MHandle <> nil then DI_MHandle.free; | ||
DI_MHandle := Create_Meter_Space('"Hour"'); | ||
For i := 1 to NumEMRegisters Do WriteintoMemStr(DI_MHandle,', "' + RegisterNames[i] + '"'); | ||
WriteintoMemStr(DI_MHandle, Char(10)); | ||
@@ -3200,6 +3201,7 @@ begin | ||
Try | ||
IF This_Meter_DIFileIsOpen Then SDI_MHandle.Free; | ||
This_Meter_DIFileIsOpen := TRUE; | ||
+ if SDI_MHandle <> nil then SDI_MHandle.free; | ||
SDI_MHandle := Create_Meter_Space('"Hour", '); | ||
WriteintoMemStr(SDI_MHandle, 'kWh, kvarh, "Peak kW", "peak kVA", "Losses kWh", "Losses kvarh", "Peak Losses kW"' + Char(10)); | ||
|
||
@@ -3590,6 +3592,7 @@ begin | ||
Try | ||
IF OverloadFileIsOpen Then OV_MHandle.Free; | ||
OverloadFileIsOpen := TRUE; | ||
+ if OV_MHandle <> nil then OV_MHandle.free; | ||
OV_MHandle := Create_Meter_Space('"Hour", "Element", "Normal Amps", "Emerg Amps", "% Normal", "% Emerg", "kVBase"' + Char(10)); | ||
Except | ||
On E:Exception Do DosimpleMsg('Error creating memory space (Overload report) for writing.'+CRLF+E.Message, 541); | ||
@@ -3602,6 +3605,7 @@ begin | ||
Try | ||
IF VoltageFileIsOpen Then VR_MHandle.Free; | ||
VoltageFileIsOpen := TRUE; | ||
+ if VR_MHandle <> nil then VR_MHandle.free; | ||
VR_MHandle := Create_Meter_Space('"Hour", "Undervoltages", "Min Voltage", "Overvoltage", "Max Voltage", "Min Bus", "Max Bus"'); | ||
WriteintoMemStr(VR_MHandle,', "LV Undervoltages", "Min LV Voltage", "LV Overvoltage", "Max LV Voltage", "Min LV Bus", "Max LV Bus"' + Char(10)); | ||
Except | ||
-- | ||
2.10.0.windows.1 | ||
|
Oops, something went wrong.