Share
 
 

About importing harness data (.xml and .csv)

Harness assemblies often contain many discrete wires and multi-conductor cables that must be placed in the harness assembly and attached to the appropriate pins. Instead of bringing in each wire or cable individually, you can import a wire list data set that automatically establishes connectivity in the harness assembly. The import files can be in .csv or .xml format. When using an .xml import file, you can also generate virtual parts and bring in additional data such as properties.

Once the wires and cables are imported, the system indicates the status of the import, displays the Imported Harness Data dialog box, and writes a log file containing the details of the import.

Note: Import files do not provide enough information to create and place electrical parts and splices in the harness assembly. For success with the import, these objects must already exist in the harness assembly.

How can I check electrical part data before I import a file?

To verify that all connectors and splices used in the import file are already placed in the assembly and contain an appropriate RefDes, use Review Harness Data on the Cable and Harness tab. Review harness data parses the import file for all electrical parts defined in the data, lists them in the dialog box, and identifies any missing RefDes information. You can then make corrections and add missing data to ensure success when importing.

What is the workflow to import wires and cables?

To import the wires and cables, you set a unique reference designator (RefDes) property for the appropriate splices and connector occurrences (if not already set), and then select one or more import files to use. The import files include an .xml file, or a configuration (.cfg) file and a comma separated (.csv) data file. The import process can be done many times with the same or different import files.

How do the configuration (.cfg) and data files (.xml or .csv) differ?

The data file has a .csv extension and specifies the point to point connectivity of each wire, including cable wires, in the active assembly. The configuration file has a .cfg extension and describes the format of the input data file. The description includes the input parameters, their associated data types, and corresponding units. An .xml data file combines the information provided in both the .cfg and .csv file. An xml data file can also include information on properties and virtual parts that the .csv file cannot.

Note: Do not use the .cfg and .csv files in the Wire Library sample folder to import wire lists. Use the files in the Wire List Import folder.

What are the delimiters used for different locales in the .csv and .cfg files?

Both the .cfg and .csv files use delimiters to separate values. The delimiter is usually a comma. For locales other than the United States it is often a semi-colon. Both delimiters can be used regardless of the delimiter specified in the Windows regional or language settings.

The Wire Library and Wire List Import folders in the Tutorial Files directory for Cable and Harness contain sample delimited files. For example in the Wire Library folder the comma delimited file for a cable library is named CableLibrary.cfg, while the semi-colon delimited file is name CableLibrary_semicolon.cfg.

What checks are done on imported wires?

The import checks the data file by checking for valid connection points and valid library wire or cable names. Also, each value is validated to ensure that it matches the property and type specified in the configuration file. Depending on the validation failure, part of the wire's data is ignored or the entire wire is skipped. All validation failures are reported in the Imported Harness Data dialog box and a log file.

How is data handled during the import?

For wires each row in the .csv file represents the data used to generate a new occurrence wire in the active harness assembly. For cables each row in the CSV file is its own reference to the cable occurrence. A row in the data file is treated as a wire if a wire ID is specified, but the cable ID and conductor ID are not specified. If cable ID and conductor ID are specified, it is treated as a cable wire.

The order of the properties is defined by the list in the third row of the CFG file. The property names and values are not case sensitive, but case is maintained for values in the data file.

The import process for both .xml and .csv/.cfg import files does not update existing wire and cable wire occurrence properties or change the connectivity. If there are no custom properties on the harness objects to import, delete the objects to update and import them.

How can I detect and correct issues with imported data?

Before the wires and cables are imported, the system displays the Imported Harness Data dialog box. This dialog box lists all imported data along with any error conditions. Right-click items in this list for additional options. The options vary depending on what is selected and enable you to add information required to complete the definition in the assembly or detect and correct error conditions.

What data is transferred between AutoCAD Electrical and Cable and Harness?

The properties that are imported and exported between AutoCAD Electrical and Cable and Harness include the RefDes (component tags), wire ID (wire number), cable ID (cable conductor wire layer) and custom properties. For more details on how to prepare AutoCAD Electrical data for import into Cable and Harness, and to see how Cable and Harness properties are handled in AutoCAD Electrical, see the AutoCAD Electrical Help.

Was this information helpful?