2011

Table Of Contents
5 Edit the API call in the COMMAND_LIST column for this component.
For example, the last argument of this Insert Multi-pole Component API
call is used to predefine MISC1 coded values with nil when nothing extra
is defined.
Before and after are shown:
Before: (c:ace_cb_multipole #xyz nil "HT0001" 3 #scl 4 nil)
After: (c:ace_cb_multipole #xyz nil "HT0001" 3 #scl 4
_L=|TERM01=T1|TERM01=T2|TERM01=T3|)
NOTE See the API documentation for more information.
6 Save the spreadsheet.
Assign attribute values using AutoLISP
An AutoLISP expression can be used to define a calculated or special value for
an attribute on a component. For example, you can calculate related values
such as Kilowatt (KW) based upon a selected horsepower value.
See
Map motor parameters to the motor symbol attributes on page 2063 to map
the entered horsepower.
1 Open the circuit template drawing that contains the marker block for
the motor symbol.
2 Find the correct marker block for the motor symbol.
3 Edit its MISC1 attribute value using the format {attribute
name}=(AutoLISP expression). For example, convert the HP value to
Kilowatts and push this value out to attribute RATING5 on the motor
symbol. Enter this expression on the MISC1 attribute of the marker block:
RATING5=(rtos (* @1@ 0.746) 2 2)
The "@1@" maps to the second entry (list is zero based) held in the #data
global variable, which is the entered horsepower value. Multiplying by
0.746 converts the horsepower (HP) to Kilowatts (KW).
Circuit Builder - How to | 2047