Download Vector VN8950 User manual

Transcript
Transceiver – Technical Data
Manual
The setCanCabsMode function has four parameters: ntype, nchannel, nmode and
nflags each of type long. For Single Wire CANcabs/CANpiggies the following values
are valid:
setCanCabsMode
Transmission rate
ntype
Meaning
0
Reserved and must be set to 0
nchannel
Meaning
0…n
CAN channel to be set
nmode
Meaning
0
NORMAL
1
SLEEP
2
HIVOLTAGE
3
HISPEED
nflags
Meaning
1
AUTOWAKEUP, only with SLEEP
2
HIGHPRIO, only CANcab 5790c, 1 = clear send buffer
For normal data exchange, normal mode is used with a transmission rate of up to
40 kbit/s. The high-speed mode is available for transmission rates up to 100 kbit/s, for
example for flash programming. However, in this mode the number of bus nodes is
limited. The high-voltage mode is needed to send the high-voltage wakeup message
(12 V). The transceiver’s transmitter is deactivated in sleep mode. Additionally, there
is a high priority flag which clears all send buffers.
Example: Example of a CAPL program for sending a high-voltage wakeup message
on CAN channel 1. CAN channel 2 is unused in normal mode.
variables
{
message 0x100 msg;
}
on start
{
msg.CAN = 1;
msg.DLC = 0;
}
on key 'w'
{
// Switch transceiver of channel 1 in high-voltage mode,
// transceiver of channel 2 in normal mode.
setCanCabsMode(0, 1, 2, 0);
setCanCabsMode(0, 2, 0, 0);
// Send message.
output(msg);
// After wake-up message switch transceivers of both channels
© Vector Informatik GmbH
Version 4.1
- 52 -