Miscellaneous commands – TML Programming Details

This category includes the following TML instructions:

FAULTR Fault reset. Gets out the drive/motor from the FAULT status in which it enters when an error occurs. After a FAULTR command, most of the error bits from MER are cleared (set to 0), the Ready output (if present) is set to “ready” level, the Error output (if present) is set to “no error” level.

Remarks:

The FAULT reset command does not change the status of MER.15  (enable input on disabled level), MER.7 (negative limit switch input active), MER.6 (positive limit switch input active) and MER.2 (invalid setup table)
The drive/motor will return to FAULT status if there are errors when the FAULTR command is executed
SAVESaves the actual values of the TML parameters from the RAM memory into the EEPROM memory, in the setup table. Through this command, you can save all the setup modifications done, after the power on initialization.  
SCIBR value16Changes the serial communication interface (SCI) baud rate. SCI is used in data exchanges on RS232 or RS485

The serial baud rate is set at power on using the following algorithm:

a.With the value read from the EEPROM setup table
b.If the setup table is invalid, with the last baud rate read from a valid setup table
c.If there is no baud rate set by a valid setup table, with 9600.

Remarks:

Use this command when a drive/motor operates in AUTORUN (after power on starts to execute the TML program from the EEPROM) and it must communicate with a host at a baud rate different from the default value. In this case, the TML program must start with a serial baud rate change.
An alternate solution to the above case is to set via SCIBR command the desired baud rate and then to save it in the EEPROM, with command SAVE. After a reset, the drive/motor starts directly with the new baud rate, if the setup table was valid. Once set, the new default baud rate is preserved, even if the setup table is later on disabled, because the default serial baud rate is stored in a separate area of the EEPROM.

CANBR value16        Changes the CAN bus baud rate as follows:

The CAN baud rate is set at power on using the following algorithm:

d.With the value read from the EEPROM setup table
e.If the setup table is invalid, with the last baud rate read from a valid setup table
f.If there is no baud rate set by a valid setup table, with 500kb.

Remarks:

Use this command when a drive/motor operates in AUTORUN (after power on starts to execute the TML program from the EEPROM) and it must communicate with a host at a baud rate different from the default value. In this case, the TML program must start with a CAN baud rate change.
An alternate solution to the above case is to set via CANBR command the desired baud rate and then to save it the EEPROM, with command SAVE. After a reset, the drive/motor starts directly with the new baud rate, if the setup table was valid. Once set, the new default baud rate is preserved, even if the setup table is later on disabled, because the default CAN baud rate is stored in a separate area of the EEPROM  

LOCKEEPROM value16 Locks or unlocks the EEPROM write protection. When the EEPROM is write-protected, it is not possible to write data into the EEPROM, with the exception of the TML command SAVE. This command temporary unlocks the EEPROM, saves the setup data and then locks back the EEPROM. Value16 may have the following values:

0 – Disables EEPROM write protection

1 – Enables write protection for the last quarter of the EEPROM

2 – Enables write protection for the last half of the EEPROM

3 – Enables write protection for the entire EEPROM

Example: An EEPROM has 8Kwords. In the TML program space occupies the address range: 4000-5FFFh. LOCKEEPROM 1 protects the address range: 5800-5FFFh, LOCKEEPROM 2 protects the address range: 5000-5FFFh and LOCKEEPROM 3 protects the entire address range: 4000-5FFFh.  

ENEEPROM Enables EEPROM usage after it was disabled by the initialization of feedback devices like SSI or EnDat encoders using the same SPI link as the EEPROM

NOP                No operation

BEGIN        First instruction of a TML program.

ENDLast instruction of the main section of a TML program. When END instruction is executed, the TML program execution is stopped.

Remark: It is mandatory to end the main section of a TML program with an END command. All the TML functions and the TML interrupt service routines must follow after the END command.

ENDINITEND of the INITialization part of the TML program. This command uses the available setup data to perform key initializations, but does not activate the controllers or the PWM outputs. These are activated with the AXISON command

Remarks:

After power on, the ENDINIT command may be executed only once. Subsequent ENDINIT commands are ignored.
The first AXISON command must be executed only after the ENDINIT command
Typically, the ENDINIT command is executed at the beginning of a TML program and may be followed by the AXISON command even if no motion mode was set. In the absence of any programmed motion, the drive applies zero voltage to the motor. Alternately, after ENDINIT you can set a first motion and then execute AXISON

See also:

TML Description