qt的can

The QLoggingCategory class represents a category, or ‘area’ in the logging infrastructure.
日志系统的一个种类

The QCanBusDevice class is the interface class for CAN bus

enum QCanBusDevice::ConfigurationKey
This enum describes the possible configuration options for the CAN bus connection.
//对can bus可能的配置选项
enum ConfigurationKey {
RawFilterKey = 0,
ErrorFilterKey,
LoopbackKey,
ReceiveOwnKey,
BitRateKey,
CanFdKey,
DataBitRateKey,
UserKey = 30
};

The QCanBusDeviceInfo provides information about CAN bus interfaces.
//can bus接口的信息

[static] bool QDesktopServices::openUrl(const QUrl &url)
Opens the given url in the appropriate Web browser for the user’s desktop environment,
//打开给定的url

[virtual slot] void QDialog::accept()
Hides the modal dialog and sets the result code to Accepted.

[virtual slot] void QDialog::reject()
Hides the modal dialog and sets the result code to Rejected.

The QCanBus class handles registration and creation of bus plugins.
处理注册和插件的创建

[static] QCanBus *QCanBus::instance()
Returns a pointer to the QCanBus class.

QStringList QCanBus::plugins() const
Returns a list of identifiers for all loaded plugins.

QList QCanBus::availableDevices(const QString &plugin, QString *errorMessage = nullptr) const
Returns the available interfaces for plugin.
//返回对plugin可用的接口

QString QCanBusDeviceInfo::name() const
Returns the interface name of this CAN bus interface,
//返回can bus的接口名字

QString QCanBusDeviceInfo::description() const
Returns a textual description of the CAN bus interface,
//返回can bus接口的文字描述

QString QCanBusDeviceInfo::serialNumber() const
Returns the serial number of the CAN bus interface as string,
//返回can bus接口的串行号

int QCanBusDeviceInfo::channel() const
Returns the sequential channel number of the CAN bus interface,
//返回顺序的通道号

bool QCanBusDeviceInfo::isVirtual() const
Returns true, if the CAN bus interface is virtual
//can bus接口是virtual

bool QCanBusDeviceInfo::hasFlexibleDataRate() const
Returns true, if the CAN bus interface is CAN FD (flexible data rate) capable.
灵活的数据速率

enum QValidator::State
This enum type defines the states in which a validated string can exist.

uint QString::toUInt(bool *ok = nullptr, int base = 10) const
Returns the string converted to an unsigned int using base base,
返回由string转换成的unsigned int

The QRegularExpression class provides pattern matching using regular expressions
//pattern matching使用regular expressions

QCanBusFrame is a container class representing a single CAN frame
//容器类,代表一个can frame

enum QCanBusFrame::FrameType
This enum describes the type of the CAN frame.
//描述了can frame的类型

enum FrameType {
UnknownFrame = 0x0,
DataFrame = 0x1,
ErrorFrame = 0x2,
RemoteRequestFrame = 0x3,
InvalidFrame = 0x4
};

void QCanBusFrame::setFrameType(QCanBusFrame::FrameType newType)
Sets the type of the frame to newType.
//设置frame的类型

void QCanBusFrame::setExtendedFrameFormat(bool isExtended)
Sets the extended frame format flag to isExtended.
//设置extended frame

void QCanBusFrame::setFlexibleDataRateFormat(bool isFlexibleData)
Sets the Flexible Data-Rate flag to isFlexibleData
//设置Flexible Data-Rate

void QCanBusFrame::setBitrateSwitch(bool bitrateSwitch)
Set the Flexible Data-Rate flag Bitrate Switch flag to bitrateSwitch.
//设置Flexible Data-Rate Bitrate

QVariant QComboBox::itemData(int index, int role = Qt::UserRole) const
Returns the data for the given role in the given index in the combobox
//按照给定的index和role 返回数据

QIntValidator
top : int
This property holds the validator’s highest acceptable value
//最高可接受的值

currentIndex : int
This property holds the index of the current item in the combobox.
//当前的item的index

[static] void QLoggingCategory::setFilterRules(const QString &rules)
Configures which categories and message types should be enabled through a a set of rules.
哪种类型和消息类型应该使能

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值