4966 views|26 replies

14

Posts

0

Resources
The OP
 

RXD outputs a high level, how can we make it output a low level to turn on Q2? [Copy link]

 

Help, there is a problem with the debugging circuit.

哈哈哈.png (17.07 KB, downloads: 0)

哈哈哈.png
This post is from Analog electronics

Latest reply

That depends on how you want the relay to work.   Details Published on 2020-9-10 13:20

2w

Posts

0

Resources
2
 

Where does the RXD signal come from?

If the signal is a pin on the microcontroller, then instructions can be used to change the state of the pin.

This post is from Analog electronics
 
 

1w

Posts

142

Resources
3
 

Just add an NPN transistor common emitter circuit to form an inverter. However, it is better to talk about the requirements of the subsequent circuit, which may not be required by the Q2 circuit.

This post is from Analog electronics
 
Personal signature上传了一些书籍资料,也许有你想要的:http://download.eeworld.com.cn/user/chunyang
 
 
 

1w

Posts

142

Resources
4
 

The author's description is ambiguous and can easily be misunderstood.

This post is from Analog electronics

Comments

I guess you want the LED to light up when the microcontroller receives serial port data and turn off when there is no data transmission. If this is the case, then just use an NPN tube.  Details Published on 2020-9-9 17:07
 
Personal signature上传了一些书籍资料,也许有你想要的:http://download.eeworld.com.cn/user/chunyang
 
 
 

14

Posts

0

Resources
5
 
maychang posted on 2020-9-9 16:48 Where does the RXD signal come from? If the signal is a pin on the microcontroller, then the state of the pin can be changed using instructions.

It is an IO port on the microcontroller. Can it be short-circuited directly to the ground?

This post is from Analog electronics

Comments

What is your purpose of shorting to ground?  Details Published on 2020-9-9 17:59
What is your purpose of shorting to ground?  Details Published on 2020-9-9 17:02
 
 
 
 

14

Posts

0

Resources
6
 
chunyang posted on 2020-9-9 16:48 Just add an NPN transistor common emitter circuit to form an inverter. However, it is better to talk about the requirements of the subsequent circuit, which may not be required for the Q2 circuit.

The collector of Q2 is connected to a relay coil, and I want the relay to work.

This post is from Analog electronics

Comments

Then Q2 is turned on when the IO output is low. Explain the relationship between the IO output state and whether the relay is energized.  Details Published on 2020-9-9 17:04
 
 
 
 

1w

Posts

142

Resources
7
 
A black spot appeared in front of my eyes. Published on 2020-9-9 16:54 It is an IO port on the microcontroller. Can it be short-circuited directly to the ground?

What is your purpose of shorting to ground?

This post is from Analog electronics
 
Personal signature上传了一些书籍资料,也许有你想要的:http://download.eeworld.com.cn/user/chunyang
 
 
 

1w

Posts

142

Resources
8
 
A black screen appeared in front of my eyes. Published on 2020-9-9 16:55 The collector of Q2 is connected to a relay coil. I want the relay to work.

Then Q2 is turned on when the IO output is low. Explain the relationship between the IO output state and whether the relay is energized.

This post is from Analog electronics
 
Personal signature上传了一些书籍资料,也许有你想要的:http://download.eeworld.com.cn/user/chunyang
 
 
 

1w

Posts

142

Resources
9
 

Since you are "completely in the dark", please be patient and explain the problem clearly.

This post is from Analog electronics
 
Personal signature上传了一些书籍资料,也许有你想要的:http://download.eeworld.com.cn/user/chunyang
 
 
 

2w

Posts

0

Resources
10
 
chunyang posted on 2020-9-9 16:51 The description of the original poster is ambiguous and can easily be misunderstood.

I guess you want the LED to light up when the microcontroller receives serial port data, and turn off when there is no data transmission.

If this is the case, then just use an NPN tube.

This post is from Analog electronics
 
 
 
 

14

Posts

0

Resources
11
 
chunyang posted on 2020-9-9 17:02 What is your purpose of short-circuiting to the ground?

Can a short connection to ground make its output low? I don't quite understand.

This post is from Analog electronics

Comments

It would be better for the original poster to clearly state what the purpose of this circuit is, whether it is lighting up a light-emitting diode or operating a relay, do you want a certain pin of the microcontroller to control it?  Details Published on 2020-9-10 13:17
It would be better for the original poster to clearly state what the purpose of this circuit is, whether it is lighting up a light-emitting diode or operating a relay, do you want a certain pin of the microcontroller to control it?  Details Published on 2020-9-9 18:01
 
 
 
 

2w

Posts

0

Resources
12
 
A black spot appeared in front of my eyes. Published on 2020-9-9 16:54 It is an IO port on the microcontroller. Can it be short-circuited directly to the ground?

Of course, the left end of R17 can be short-circuited to ground, but in this case the microcontroller will not be able to control the light-emitting diode.

Instead of shorting the left end of R17 to ground, it is better to short the upper end of R13 to the power supply and save R17 and Q2.

The pins of the microcontroller generally cannot be short-circuited to ground.

This post is from Analog electronics
 
 
 
 

2w

Posts

0

Resources
13
 
A black screen appeared in front of my eyes. Posted on 2020-9-9 17:47 Can a short connection to the ground make its output low? I don’t quite understand.

It would be better for the original poster to clearly state what the purpose of this circuit is, whether it is lighting up a light-emitting diode or operating a relay, do you want a certain pin of the microcontroller to control it?

This post is from Analog electronics
 
 
 
 

14

Posts

0

Resources
14
 

The MCU IO port outputs a high level by default. Now I want the U1-RXD port to output a low level to power the relay. (The MCU program is directly burned into it, and I don't understand the program).

123456789.png (30.18 KB, downloads: 0)

123456789.png
This post is from Analog electronics

Comments

Outputting low level depends on instructions, you have to program it. If you don’t understand, either learn it or find someone who knows to help you program it.  Details Published on 2020-9-10 13:18
 
 
 
 

14

Posts

0

Resources
15
 
maychang posted on 2020-9-9 18:01 It is better for the OP to make it clear what the purpose of this circuit is, whether it is to light up the LED or to operate the relay, or to hope that a certain pin of the microcontroller will...

Hi, I have attached a slightly more complete picture, please take a look.

This post is from Analog electronics

Comments

"I have posted a slightly more complete picture, take a look" I have seen it. The I/O port of some models of microcontrollers is at a high level by default after power-on.  Details Published on 2020-9-10 10:08
"I have posted a slightly more complete picture, take a look" I have seen it. The I/O port of some models of microcontrollers is at a high level by default after power-on.  Details Published on 2020-9-10 10:07
"I have posted a slightly more complete picture, take a look" I have seen it. The I/O port of some models of microcontrollers is at a high level by default after power-on.  Details Published on 2020-9-10 10:05
 
 
 
 

2w

Posts

0

Resources
16
 
A black spot appeared in front of my eyes. Published on 2020-9-10 09:54 Hello, I have posted a slightly more complete picture. Take a look.

"I've posted a slightly more complete picture, take a look"

I have read that the I/O ports of some microcontroller models are at a high level by default after power-on.

This post is from Analog electronics
 
 
 
 

2w

Posts

0

Resources
17
 
A black spot appeared in front of my eyes. Published on 2020-9-10 09:54 Hello, I have posted a slightly more complete picture. Take a look.

"Now I want U1-RXD port to give a low level to power the relay"

Only instructions can change a certain I/O port of the microcontroller; it cannot be changed from an external circuit.

This post is from Analog electronics
 
 
 
 

2w

Posts

0

Resources
18
 
A black spot appeared in front of my eyes. Published on 2020-9-10 09:54 Hello, I have posted a slightly more complete picture. Take a look.

If it is a 51 series single-chip microcomputer, the I/O port is allowed to short-circuit to the ground when outputting a high level, but this is not necessarily the case for other types of single-chip microcomputers.

This post is from Analog electronics
 
 
 
 

14

Posts

0

Resources
19
 
maychang published on 2020-9-10 10:07 "Now I want U1-RXD port to give a low level to power the relay." Only instructions can change a certain I/O port of the microcontroller...

OK, thank you for the guidance.

This post is from Analog electronics
 
 
 
 

14

Posts

0

Resources
20
 
maychang posted on 2020-9-10 10:08 If it is a 51 series microcontroller, the I/O port is allowed to short-circuit to the ground when it outputs a high level. This is not necessarily the case for other models of microcontrollers.

It's not the 51 series, so is there any way to make the relay work without changing the circuit and program?

This post is from Analog electronics

Comments

If you want the relay to work without changing the circuit or the program, you can only connect a resistor between the base of Q2 and GND. The resistor value can be 2 to 3 kilo-ohms. When the resistor is connected, the relay should be attracted. When the resistor is disconnected, the relay should be released. Obviously, this method can only be used to test whether the relay is damaged.  Details Published on 2020-9-10 13:20
If you want the relay to work without changing the circuit or the program, you can only connect a resistor between the base of Q2 and GND. The resistor value can be 2 to 3 kilo-ohms. When the resistor is connected, the relay should be attracted. When the resistor is disconnected, the relay should be released. Obviously, this method can only be used to test whether the relay is damaged.  Details Published on 2020-9-10 11:32
If you want the relay to work without changing the circuit or the program, you can only connect a resistor between the base of Q2 and GND. The resistor value can be 2 to 3 kilo-ohms. When the resistor is connected, the relay should be attracted. When the resistor is disconnected, the relay should be released. Obviously, this method can only be used to test whether the relay is damaged.  Details Published on 2020-9-10 11:30
 
 
 
 

Guess Your Favourite
Find a datasheet?

EEWorld Datasheet Technical Support

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews

Room 1530, Zhongguancun MOOC Times Building, Block B, 18 Zhongguancun Street, Haidian District, Beijing 100190, China Tel:(010)82350740 Postcode:100190

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list