Skip to content

Commit 395e085

Browse files
authored
Merge pull request #28 from pvlib/cables
move cable_to_parent to module_array
2 parents 44f09ac + 7798957 commit 395e085

File tree

2 files changed

+8
-35
lines changed

2 files changed

+8
-35
lines changed

Examples/05 - VerySimpleFixedPVC2_with_electrical_layout_v3.pvc

Lines changed: 6 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -182,32 +182,24 @@
182182
<!-- first string tag => the string connected to this mppt input -->
183183
<pv:string id="string1">
184184
<pv:module_array>
185+
<!-- Cable between the module_array and the inverter -->
186+
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance4" />
185187
<pv:module_layout url="#rackId1">
186-
<!-- Cable between the string and the inverter -->
187-
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance4" />
188188
<pv:position_in_string>1</pv:position_in_string>
189189
<pv:row>1</pv:row>
190190
<pv:column>1</pv:column>
191191
</pv:module_layout>
192192
<pv:module_layout url="#rackId1">
193-
<!-- Cable between the module and its neighbor in the string -->
194-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance5" />
195193
<pv:position_in_string>2</pv:position_in_string>
196194
<pv:row>1</pv:row>
197195
<pv:column>2</pv:column>
198196
</pv:module_layout>
199197
<pv:module_layout url="#rackId1">
200-
<!-- Cable between the module and its neighbor in the string -->
201-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance6" />
202198
<pv:position_in_string>3</pv:position_in_string>
203199
<pv:row>1</pv:row>
204200
<pv:column>3</pv:column>
205201
</pv:module_layout>
206202
<pv:module_layout url="#rackId1">
207-
<!-- Cable between the module and its neighbor in the string -->
208-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance7" />
209-
<!-- Cable between the string and the inverter -->
210-
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance8" />
211203
<pv:position_in_string>4</pv:position_in_string>
212204
<pv:row>1</pv:row>
213205
<pv:column>4</pv:column>
@@ -228,32 +220,24 @@
228220
<!-- second string tag => the string connected to this mppt input -->
229221
<pv:string id="string2">
230222
<pv:module_array>
223+
<!-- Cable between the module_array and the inverter -->
224+
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance10" />
231225
<pv:module_layout url="#rackId2">
232-
<!-- Cable between the string and the inverter -->
233-
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance10" />
234226
<pv:position_in_string>1</pv:position_in_string>
235227
<pv:row>1</pv:row>
236228
<pv:column>1</pv:column>
237229
</pv:module_layout>
238230
<pv:module_layout url="#rackId2">
239-
<!-- Cable between the module and its neighbor in the string -->
240-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance11" />
241231
<pv:position_in_string>2</pv:position_in_string>
242232
<pv:row>1</pv:row>
243233
<pv:column>2</pv:column>
244234
</pv:module_layout>
245235
<pv:module_layout url="#rackId2">
246-
<!-- Cable between the module and its neighbor in the string -->
247-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance12" />
248236
<pv:position_in_string>3</pv:position_in_string>
249237
<pv:row>1</pv:row>
250238
<pv:column>3</pv:column>
251239
</pv:module_layout>
252240
<pv:module_layout url="#rackId2">
253-
<!-- Cable between the module and its neighbor in the string -->
254-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance13" />
255-
<!-- Cable between the string and the inverter -->
256-
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance14" />
257241
<pv:position_in_string>4</pv:position_in_string>
258242
<pv:row>1</pv:row>
259243
<pv:column>4</pv:column>
@@ -274,32 +258,24 @@
274258
<!-- third string tag => the string connected to this mppt input -->
275259
<pv:string id="string3">
276260
<pv:module_array>
261+
<!-- Cable between the module_array and the inverter -->
262+
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance16" />
277263
<pv:module_layout url="#rackId3">
278-
<!-- Cable between the string and the inverter -->
279-
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance16" />
280264
<pv:position_in_string>1</pv:position_in_string>
281265
<pv:row>1</pv:row>
282266
<pv:column>1</pv:column>
283267
</pv:module_layout>
284268
<pv:module_layout url="#rackId3">
285-
<!-- Cable between the module and its neighbor in the string -->
286-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance17" />
287269
<pv:position_in_string>2</pv:position_in_string>
288270
<pv:row>1</pv:row>
289271
<pv:column>2</pv:column>
290272
</pv:module_layout>
291273
<pv:module_layout url="#rackId3">
292-
<!-- Cable between the module and its neighbor in the string -->
293-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance18" />
294274
<pv:position_in_string>3</pv:position_in_string>
295275
<pv:row>1</pv:row>
296276
<pv:column>3</pv:column>
297277
</pv:module_layout>
298278
<pv:module_layout url="#rackId3">
299-
<!-- Cable between the module and its neighbor in the string -->
300-
<pv:cable_to_neighbor url="#DCCableModel1" length="1" id="cableInstance19" />
301-
<!-- Cable between the string and the inverter -->
302-
<pv:cable_to_parent url="#DCCableModel1" length="3" id="cableInstance20" />
303279
<pv:position_in_string>4</pv:position_in_string>
304280
<pv:row>1</pv:row>
305281
<pv:column>4</pv:column>

schema/pvcollada_schema_0.1.xsd

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -613,16 +613,13 @@ xmlns:collada="http://www.collada.org/2008/03/COLLADASchema">
613613
<!-- module_array: contains one or more module_layout elements -->
614614
<xs:complexType name="module_array_type">
615615
<xs:sequence>
616+
<xs:element name="cable_to_parent" type="cable_to_type" />
616617
<xs:element name="module_layout" type="module_layout_type" maxOccurs="unbounded" />
617618
</xs:sequence>
618619
</xs:complexType>
619-
<!-- module_layout: must have at least one cable (either cable_to_parent or cable_to_neighbor) plus one row and one column -->
620+
<!-- module_layout: must describe position (row, column) and position in string -->
620621
<xs:complexType name="module_layout_type">
621622
<xs:sequence>
622-
<xs:choice maxOccurs="2">
623-
<xs:element name="cable_to_parent" type="cable_to_type" />
624-
<xs:element name="cable_to_neighbor" type="cable_to_type" />
625-
</xs:choice>
626623
<xs:element name="position_in_string" type="xs:integer" />
627624
<xs:element name="row" type="xs:integer" />
628625
<xs:element name="column" type="xs:integer" />

0 commit comments

Comments
 (0)