Engee documentation

CAN Setup

Configuring the CAN port of the module.

blockType: EngeeFunction

Path in the library:

/Interfaces/CAN/CAN Setup

Description

To work with the block, install/update the support package. equipment.

Block CAN Setup It is used to configure the CAN port of the module.

Ports

None.

Parameters

Main group

# Интерфейс: — implementation of drivers for working with the CAN bus
socketcan | pcan | kvaser | vector | systec | cantact | canalystii | ETAS | gs_usb | iscan | ixxat | neousys | neovi | nican | nixnet | robotell | seeedstudio | serial | slcan | socketcand | udp_multicast | usb2can | virtual | marathon

Details

Available interfaces:

Interface name

Decoding

socketcan

SocketCAN

pcan

PCAN Basic API

kvaser

Kvaser’s CANLIB

vector

Vector

systec

SYSTEC interface

cantact

CANtact CAN Interface

canalystii

CANalyst-II

ETAS

ETAS

gs_usb

Geschwister Schneider and candleLight

iscan

isCAN

ixxat

IXXAT Virtual Communication Interface

neousys

Neousys CAN Interface

neovi

Intrepid Control Systems neoVI

nican

National Instruments NI-CAN

nixnet

National Instruments NI-XNET

robotell

Robotell CAN-USB interface

seeedstudio

Seeed Studio USB-CAN Analyzer

serial

CAN over Serial

slcan

CAN over Serial / SLCAN

socketcand

socketcand Interface

udp_multicast

Multicast IP Interface

usb2can

USB2CAN Interface

virtual

Virtual

marathon

Marathon

Values

socketcan | pcan | kvaser | vector | systec | cantact | canalystii | ETAS | gs_usb | iscan | ixxat | neousys | neovi | nican | nixnet | robotell | seeedstudio | serial | slcan | socketcand | udp_multicast | usb2can | virtual | marathon

Default value

socketcan

Program usage name

m_interface

Tunable

No

Evaluatable

Yes

# Port: — ID of the CAN interface (port) to be used for sending and receiving messages

Details

How to get the port ID depends on the OS and the driver/adapter.:

Linux (for example, SocketCAN interface):

  1. View the list of CAN interfaces with the command:

    ip a

    The output will have interfaces like can0, can1 and so on. These are the values that are specified in the Port parameter.

  2. Before using it, make sure that the interface is loaded and activated. An example for can0:

    sudo modprobe can
    sudo ip link set can0 type can bitrate 125000
    sudo ip link set can0 up

Windows:

  1. Install the drivers for the adapter you are using.

  2. Open the utility provided with the driver and see the list of available ports.:

    • For KvaserKvaser CanKing devices;

    • For PEAKPCAN-View equipment.

      The names of the ports can look like PCAN_USBBUS1, PCAN_USBBUS2 etc.

Before using the unit, make sure that the selected CAN interface is correctly configured and active in the system.

Default value

"can0"

Program usage name

m_port

Tunable

No

Evaluatable

Yes

# Скорость передачи: — network transfer rate

Details

Network transfer rate (from 10 Kbit/s to 1 Mbit/s). All nodes in the network must operate at the same speed.

Default value

500.0

Program usage name

m_speed

Tunable

No

Evaluatable

Yes

# Восстановление шины в состоянии Bus-off: — the time to restore the active state of the interface after entering the Bus-off state

Details

The number 0 means — do not recover after Bus-off.

Default value

true (switched on)

Program usage name

m_bus_off

Tunable

No

Evaluatable

Yes

# Шаг расчёта, с: — the time interval with which data is processed and exchanged over the CAN bus

Details

Defines the sampling period of the block with which CAN messages are sent and received during the simulation.

Default value

-1

Program usage name

m_sample_time

Tunable

No

Evaluatable

Yes