User guide
48
VTB USER GUIDE
SER_PRINTF
Formatting print of a FLOAT value. It is the same as ser_printl but use a float value
Hardware All
Syntax
SER_PRINTF (const char *Format, float Val)
Parameters
Format String corresponding to the format to be printed
Val Any integer value or expression
SER_PUTBLK
Sends a precise number of characters to the serial port. Unlike the function ser_puts it allows to send also the
character with 0 code enabling the managing of binary protocols, furthermore it starts the background transmission
setting in appropriate mode the RTS signal useful to work with RS485 lines.
Hardware All
WARNING: This function allows to manage BINARY and RS485 protocols.
Syntax
SER_PUTBLK (char *Buffer, int Len)
Parameters
*Buffer Pointer to the data buffer to send
Len Number of bytes to send
Example
Ser_putblk(Vect(),11) ‘ Send 11 bytes of array vect
SER_PUTST
Reads the state of background transmission started by ser_putblk.
Hardware All
Syntax
SER_PUTST () as int
Return value:
-1 Transmit error
>=0 Number of characters to be transmitted
Example
Ser_putblk(Vect(),11) ‘ Send 11 bytes
while Ser_putst() ‘ Wait for the complete transmission
loop