ChannelBtsCAN

Summary

Represents a BTS CAN Channel Adapter object.

Methods
Properties

Structure

class ChannelBtsCAN
configure(bitrate: int32, sampling_point: uint8, ack: bool, fd_bitrate: int32 or None = None, fd_sampling_point: uint8 or None = None)

Configures the BTS CAN channels (sets the bitrate, data rate, sampling point, data sampling point of the channel and determines if an ack is sent or not).

Note: This function is not supported in old BTS.

Parameters
  • bitrate (int32) – The desired bitrate of the channel.

  • sampling_point (uint8) – The desired sampling point of the channel.

  • ack (bool) – Whether or not the channel answers with an ack.

  • fd_bitrate (int32 or None) – The desired data rate of the channel.

  • fd_sampling_point (uint8 or None) – The data sampling point of the channel.

encode(message: MessageCAN, request_counter: int64 = 0) Array[uint8]

Returns the encoded CAN message as a byte array.

Parameters
  • message (MessageCAN) – the encoded CAN message

  • request_counter (int64) – request counter

Returns

the encoded CAN message as a byte array

Return type

Array[uint8]

start_record(file: str, filter: Filter = None) IRecordHandler

Starts recording the traffic on the adapter to an output file.

Parameters
  • file (str) – The file to record into.

  • filter (Filter) – Filter to use to narrow down packets to capture

Returns

The record handler responsible for recording.

Return type

IRecordHandler

stop_record()

stops capturing transmission

cluster_name

The name of the cluster that is mapped to the channel.

Type

str

name

The channel name. This Property is Read Only.

Type

str