-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
18 changed files
with
134 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
title: 8051单片机知识积累 | ||
date: 2024-10-28 15:27:39 | ||
tags: | ||
--- | ||
|
||
PSEN: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
title: CANoe通信理念 | ||
date: 2024-10-30 15:29:34 | ||
tags: | ||
--- | ||
CANoe通信的关键概念是应用部分和传输媒体的严格分离,基于这个理念,canoe在两者之间提供了一个通信层,叫做中间件 | ||
|
||
仿真:仿真包含所有在真实控制单元中可能出现的基本传输行为,控制单元的行为被全部仿真 | ||
激励:刺激的目的是诱导网络中控制单元的反应,例如,这里可以简单地只发送消息 | ||
|
||
## canoe分析(analysis)功能 | ||
关键词:展示、解释、记录、回放数据(总线数据、变量、和诊断参数) | ||
- 接收数据:在线分析和离线分析都是可能的。 | ||
1. 在线数据源是通过硬件连接的仿真总线或真实总线上的数据(例如CANcardXL) | ||
2. 离线数据源是一个包含记录数据的文件 | ||
- 处理数据 | ||
为了提供数据的清晰表示,可以使用过滤器来指定允许哪些数据,哪些数据要显式过滤掉。过滤器可以在测量期间或之后激活,并且可以过滤从单个信号到整个总线系统通道的数据。 | ||
-数据的表示 | ||
数据有不同的表示方式,取决于分析的需求,例如: | ||
1. 使用信号图表进行图形化表示 | ||
2.展示信号值 | ||
3.展示测量的序列和状态 | ||
4.位的值和状态的图形化表示 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
title: Qt核心模块的一些特性 | ||
date: 2024-10-29 20:45:45 | ||
tags: | ||
--- | ||
Qt核心模块在C++中添加了以下特性: | ||
- 信号和槽机制 | ||
- 可查询和可设计的对象属性 | ||
- 分层和可查询的对象树,用保护指针以自然的方式组织对象所有权(QPointer) | ||
- 跨库边界工作的动态强制转换 | ||
以下页面为Qt的核心特性提供了更多信息 | ||
|
||
## 元对象系统(Meta-Object System) | ||
Qt的元对象系统为内部对象通信提供了信号和槽机制,运行时类型信息,动态属性系统 | ||
1. QObject类为所有可以从元对象系统受益的对象提供了一个基类 | ||
2. Q_OBJECT宏用于打开元对象系统; | ||
3. 元对象编译器(MOC)支持每一个带有必要代码的QObject的子类实现元对象特性 | ||
moc工具读取C++源文件,如果发现其中包含Q_OBJECT宏,它会生成一个额外的C++源文件,其中包含元对象代码,这个生成的源文件会被包含进类的源文件里面,或者更一般地,编译并且链接到类的实现。 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
--- | ||
title: 'Qt工程打包流程(保姆级)' | ||
date: 2024-10-24 10:11:00 | ||
tags: | ||
--- | ||
|
||
## 环境及工具准备 | ||
1. windows环境 | ||
2. 安装Qt开发环境,包含Qt Creator(过程略); | ||
3. 下载安装Inno setup compiler打包工具,下载地址:[Inno setup compiler](https://www.jrsoftware.org/isdl.php)(过程略); | ||
## 工程构建 | ||
1. 使用Qt Creator打开工程,选择Release或Minimum Size Release模式(具体差异不太清楚),构建工程: | ||
![图1](build.png) | ||
2. 找到构建后生成的文件夹,将里面产生的exe文件拷贝到另一个空文件夹: | ||
![图2](release.png) | ||
使用qt提供的deploy工具,在命令窗口中执行以下命令: | ||
```bash | ||
windeployqt release.exe | ||
``` | ||
如果提示没有该工具,将该工具所在的路径添加到环境变量中,一般在构建套件的bin目录下: | ||
![部署工具](windeployqt.png) | ||
执行后会产生一些dll文件,如下图: | ||
![图3](windeploy.png) | ||
|
||
## 打包 | ||
1. 打开Inno setup compiler,根据脚本向导新建一个脚本文件,如下图: | ||
![新建脚本文件](scriptWizard.png) | ||
2. 填入安装包的基本信息: | ||
![填写应用信息](scriptWizard2.png) | ||
3. 选择exe文件的位置: | ||
![选择exe文件位置](exeFileSelect.png) | ||
4. 依次选择安装包的输出路径,安装包名称,选择安装包的图标文件,如下图: | ||
![设置应用图标](setIcon.png) | ||
一路下一步,直到脚本文件的创建,将其保存,然后编译脚本文件,如果有错误,修复错误直到编译通过,然后点击运行按钮,等待打包完成,会在输出路径下生成一个安装包。双击即可安装运行。 | ||
![编译脚本文件](compileAndRun.png) | ||
|
||
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
title: 利用qt的上下文属性将C++对象嵌入到QML中 | ||
date: 2024-10-25 14:45:40 | ||
tags: | ||
--- | ||
## 目的 | ||
当我们在C++应用中加载QML的时候,直接嵌入一些C++数据到QML代码中是非常有用的,这使得调用嵌入对象中的C++方法或者使用C++对象实例作为数据模型成为可能。 | ||
使用QQmlContext类即可将C++对象注入到QML中,这个类将数据暴露到QML的上下文中,以便于在QML范围内能被直接引用。 | ||
|
||
## 设置简单的上下文属性 | ||
|
||
有如下代码,在QML范围内引用了一个不存在的值currentDateTime: | ||
```QML | ||
// MyItem.qml | ||
import QtQuick 2.0 | ||
Text {text: currentDateTime} | ||
``` | ||
这个值可在加载QML的C++中直接设置,使用QQmlContext::setContextProperty(): | ||
```QML | ||
QQuickView view; | ||
view.rootContext()->setContextProperty("currentDateTime", QDateTime::currentDateTime()); | ||
view.setSource(QUrl::fromLocalFile("MyItem.qml")); | ||
view.show(); | ||
``` | ||
|
||
## 将对象设置为上下文属性 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
title: 怎样学习编程? | ||
date: 2024-10-17 16:58:05 | ||
tags: | ||
--- | ||
|
||
## 编程四大件 | ||
|
||
数据结构与算法,操作系统... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
title: 资源积累 | ||
date: 2024-10-28 11:51:40 | ||
tags: | ||
--- | ||
|
||
你必须有一张地图,不管它有多粗糙。否则你将会到处乱逛,在指环王中我从来不会让任何人在一天之中走得更远。----J.R.R.托尔金 | ||
|
||
工程师三大思维:产品思维,技术思维,工程思维 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters