Important
The retrieved value can be converted to the Bitrate type. Example (C#): Bitrate bitrate = (Bitrate)uintBuffer;
This parameter is used to obtain information about the bit rate of a Channel, that was initialized to work with classic CAN communication.
It is available since PCAN-Basic version 4.0.0.
It can be read without initialization since PCAN-Basic version 4.4.0.
This parameter can only be read. It cannot be modified.
This value has a resolution of Word (range [0... MaxValue]), which represents bit rate registers (BTR0/BTR1), for a CAN controller SJA1000. It matches the type Bitrate.
Does not apply.
Get: It can be read on initialized or uninitialized PCAN-Channels.
The following code shows how to retrieve classic CAN bit rate information from a USB Channel:
PcanChannel channelUsed = PcanChannel.Usb01;
uint bitrate;
if (Api.GetValue(channelUsed, PcanParameter.BitrateBtrInformation, out bitrate) == PcanStatus.OK)
Console.WriteLine($"The channel {channelUsed} uses following bit rate: 0x{bitrate:X} ({(Bitrate)bitrate})");Dim channelUsed As PcanChannel = PcanChannel.Usb01
Dim bitrate As UInteger
If Api.GetValue(channelUsed, PcanParameter.BitrateBtrInformation, bitrate) = PcanStatus.OK Then
Console.WriteLine($"The channel {channelUsed} uses following bit rate: 0x{bitrate:X} ({CType(bitrate, Bitrate)})")
End IfPcanChannel channelUsed = PcanChannel:: Usb01;
UInt32 bitrate;
if (Api::GetValue(channelUsed, PcanParameter::BitrateBtrInformation, bitrate) == PcanStatus::OK)
Console::WriteLine("The channel {0} uses following bit rate: 0x{1:X} ({2})", channelUsed, bitrate, (Bitrate)bitrate);