SCIBR        Set RS232/RS485 serial communication interface baud rate

Syntax                        

SCIBR value16

Set Serial Communication Interface Baud Rate to value16

SCIBR VAR16

Set Serial Communication Interface Baud Rate to VAR16

 

Operandsvalue16: 16-bit integer immediate value between 0 and 4

       VAR16: integer variable

PlaceTMLOnline

Binary code

DescriptionSets the baud rate on the RS232/RS485 serial communication interface (SCI). The new baud rate can be provided either as an immediate value or by the value of a TML variable. In both cases, the possible values are:

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 the 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.

 

Example                

SCIBR 4;                // sets the SCI baud rate to 115200 baud