当前位置:网站首页>Keil simulation and VSPD
Keil simulation and VSPD
2022-06-22 15:01:00 【Weiwenjie top】
Read a lot of articles , It's all very simple ( It's also very simple :)). Give a more detailed tutorial .
1. utilize VSPD take PC Connect the two virtual serial ports on the . As shown in the picture, I will COM2 and COM3 Connect . Click on Addr pair.

2. You can see Virtual ports Connect the two virtual serial ports together .
3. The virtual serial port is ready . First, debug by directly entering the command . We turn on KEIL MDK Of , Set to simulation mode . spot DEBUG. stay COMMAND Serial port input :MODE COM2 38400, 0, 8, 1

explain :
MODE The function of the command is to set the parameters of the bound computer serial port . The basic usage is :
MODE COMx baudrate, parity, databits, stopbits
among :
COMx(x = 1,2,…) Represents the serial port number of the computer ;
baudrate Represents the baud rate of the serial port ;parity Represents the verification method ;
databits Represents the length of data bits ;
stopbits Represents the stop bit length .
for example :MODE COM1 9600, n, 8, 1
Set the serial port 1. The baud rate is 9 600, No parity bit ,8 Bit data ,1 Bit stop bit .
MODE COM2 19200, 1, 8, 1
Set the serial port 2. The baud rate is 19 200, Odd check ,8 Bit data ,1 Bit stop bit .
4、 Click enter , Input again ASSIGN COM2 <S1IN> S1OUT

explain :
COMx Represents the serial port of the computer , It can be COM1、COM2、COM3 Or others ;
inreg and outreg Represents the serial port of single chip microcomputer . For an ordinary single chip microcomputer with only one serial port , namely SIN and SOUT; For a single chip microcomputer with two or more serial ports , namely SnIN and SnOUT(n=0,1,… Serial port number of single chip microcomputer ).
for example :ASSIGN COM1 < SIN > SOUT
Connect the serial port of the computer 1 Serial port bound to MCU ( For single chip microcomputer with only one serial port ).
ASSIGN COM2 < SIN > SOUT
Connect the serial port of the computer 2 Serial port bound to MCU 0( For single chip microcomputer with multiple serial ports , Pay attention to the position of serial port number ).
It should be noted that , The parentheses of parameters cannot be omitted , and outreg There are no parentheses .
5、 Then debug the program . You can see the serial port COM3 Print out the serial port 1 The data of the .

边栏推荐
- Thoroughly understand the builder mode (builder)
- "Forget to learn again" shell process control - 38. Introduction to while loop and until loop
- C # paging calculation total pages, current page data set
- Data collection: skillfully using Bloom filter to extract data summary
- Thoroughly understand the factory mode
- D security can call the system
- 轻松上手Fluentd,结合 Rainbond 插件市场,日志收集更快捷
- Sikulix选取相对位置的图片(进阶版)
- 作为过来人,写给初入职场的程序员的一些忠告
- KEIL仿真和vspd
猜你喜欢
![[PR] basic process](/img/e6/13a5703cfb8e5c51ed06fe9b0d9485.png)
[PR] basic process

【直播回顾】战码先锋第六期:共建测试子系统,赋能开发者提

RealNetworks vs. Microsoft: the battle in the early streaming media industry

How location coding (PE) works in transformers

嵌入式中的强符号和弱符号是什么?

大会倒计时 | 亚马逊云科技创新大会邀您一起构建AI新引擎 !

Specific methods and steps of PROFINET communication between s7-200smart and Fanuc robot

数据库连接池:连接池功能点的实现

Common real machine debugging plug-ins for unity commercial games

PowerPoint tutorial, how to add watermarks in PowerPoint?
随机推荐
Unity's rich text color sets the color to be fully transparent
[Zhejiang University] information sharing of the first and second postgraduate entrance examinations
Struggle, programmer -- Chapter 44: eight hundred miles under one's command, fifty strings turning over the Great Wall
机器学习之随机森林
开源SPL重新定义OLAP Server
Struggle, programmer -- Chapter 47 the so-called Iraqis are on the water side
What are strong and weak symbols in embedded systems?
嵌入式中的强符号和弱符号是什么?
Flutter video Le lecteur écoute et joue automatiquement la prochaine chanson
Network address translation nat
数据采集之:巧用布隆过滤器提取数据摘要
keil MDK 中使用虚拟串口调试串口
Mobile learning notes of u++ programming
Software architecture
Deadlock found when trying to get lock; Try restarting transaction
Sword finger offer46 -- translate numbers into strings
C # define and implement interface interface
C # WinForm photo album function, picture zooming, dragging, preview Pagination
本周四晚19:00战码先锋第7期直播丨三方应用开发者如何为开源做贡献
数据库连接池:连接池功能点的实现