System bus (CAN) with Ser vo PLC & Drive PLC
LenzeCanDrv.lib – Functions
8.2 Deactivation L_CanClose)
8-4
L
PLC-Systembus EN 1.1
8.2 Deactivation L_CanClose)
BOOL L_CanClose (wDrvNr)
This function deactivates the CAN driver.
• All transmit and receive requests not carried out yet are cancelled when this function is
activated.
L_CanClose
wDrvNr
Fig. 8-3 Deactivation L_CanClose)
Transfer parameters
Identifier Data type Possible settings Info
wDrvNr Word 10
11
System bus
FIF CAN (in preparation)
Return value
Data typ e Value Meaning Priority
Bool 0 A n error occurred when deactivating the driver
(wrong driver number or driver has not been initialised)
-
1 Driver has been deactivated.
Example
Calling the function in ST:
(* close CAN driver - returns g_bCanCloseState *)
g_bCanCloseState := L_CanClose (10)