Ideal diode vs practical Diode

Hello, Students here I am present to cover an article on a series of Electronic devices and circuit theory. The foremost article of this series is Ideal diode vs practical diode. I try to elaborate on basic to modern theory related to the diode. This component act as fundamental to many important circuit devices such as rectifiers, transformers, etc. The question which we cover in this article are;

  • What is a diode?
  • How a diode is formed? Which methodology manufacturer utilized while the formation of the diode?
  • What is the concept of doping and PN junction in diode theory?
  • How does a Diode work?
  • What type of biasing allows a diode to conduct? Under which situation of biasing diode offers a restriction while conducting?
  • Upon which characteristics do we categorize the diode as an ideal diode and practical diode?
  • Which factor makes a diode ideal? And how practical diode is different from an ideal diode?

Along with these questions, numerous questions may arise in your mind related to diode because it is a very vast concept in circuit theory. If you want to know the answer to these questions, keep sticking with our article. The best step taken by our platform for the easiness of our readers is to provide two things in a single platform. A short video of this article is also tried to cover on our YouTube channel. You may visit. The link is given at end of the article.

What is a diode?

A diode is a two-terminal device that worked as a one-way conductor. A diode may assume as a simple solid-state component. This solid-state component is formed when the intrinsic semiconductor such as germanium or silicon Crystal is grown in such a way that one end is doped with pentavalent and the other end is doped with a trivalent impurity. It is also referred to as PN-junction Diode. Here word doped comes from techniques of doping which is used during the manufacturing of diode.

Doping

The process of adding an impurity to an intrinsic semiconductor I.e germanium and silicon. Semiconductors are those materials whose conductivity lies between a conductor ( good to conduct electricity) and an insulator ( bad to conduct electricity). To enhance the conducting capacity of semiconductors they are doped with different Impurities. Here the word impurity is used for those elements which are doped to pure semiconductor, after they are doped the germanium or silicon Crystal no longer remains pure.

Which element is used for doping?

Basically, elements from a fifth and third group of the periodic tables are commonly used in this process. Which refer to as pentavalent impurity (5the group) and trivalent impurity. Byword pentavalent means there are five electrons present in the outermost shell they lose one electron to complete their Octate and to become stable. That’s why these impurities are also named Donor impurity examples of such impurity are phosphorus, bismuth, etc. When we add such impurity to a semiconductor then N-type material is formed. Trivalent are those which have 3 electrons in the outermost shell and they need 1 electron to become stable due to this reason they are also named acceptor impurities. Examples of such impurities are Aluminum, Boron, etc. When they are doped with pure semiconductors then P-type material is formed.

How a diode is formed?

When intrinsic semiconductors is doped with two different Impurities then a junction is formed which I explain you in video of our Engineering prove t channel and I try to explain this also in my article;

When an N-type material is combined with P-type material then a PN junction is formed. In N-type material, there is the availability of a large number of free electrons which act as a majority charge carrier and holes act as minority charge Carriers. While in P-Type materials the doped material belongs to a trivalent group, they need 1 more electron to complete their covalent bond tendency. To complete one hole an electron jump from one shell to another. This creates another hole in the second shell which results in more than holes these holes act as majority charge carrier and electrons act as a minority charge carriers in P-Types material. As soon as these material are combine electrons from the N-side start to attract toward holes in P-side where they both diffuse and as soon as electron diffuse in the P-side this leave behind a positive ion and holes from the P-side move toward N-side and leave behind a negative ion result information depletion layer where there is lack of Carrier but still, there is the availability of negative and positive ions. This creates a natural potential difference between the two sides, thus forming a junction which refer to as PN-junction. Given below energy diagram and other pictorial representation helps to understand my concept.

Symbolic representation of a PN junction diode.

Symbolically a diode is represented as follows: Here N-side of the diode acts as the cathode and the P-side of the diode act as the anode. Current flow in direction to the arrow. There is a positive charge on the p-side and a negative charge on N-side.

How diode works

Under which biasing diode conduct and which biasing make diode poor to Conduct?

Biasing;

Biasing is a process in which to obtain the desire mode of operation we apply potential to both sides of the diode. This potential also helped us to control the width of the depletion layer.

Forward Biasing;

As shown in figure when biasing is applied in such a way that we provide the positive potential to cathode or P-Side of diode which makes it positive and negative potential of battery is connected with N-side of diode this makes the N-side more negative than P-side. This meets the necessary condition for a diode to conduct. This allows the flow of charges with little opposition almost negligible along with the depletion layer which reduces its width. Once a diode starts to conduct, there is slight opposition faced by carriers. This opposition is a referee to as bulk resistance. It combines the resistance of N-type and p-type. Its value is a most 5 ohm or less.

R(B)= R(N) + R(P)

As the value of R(B) is very low therefore there is little voltage drop across the resistance. Thus negligible in circuitry calculations. When the diode conduct fully the forward voltage becomes greater than the barrier potential. Typically the value of barrier potential or forward voltage for silicon and germanium are;

V(f) =0.7V for silicon

V(f)= 0.3V for germanium

Thus we can drive a diode to conduct by making the N-side more negative than the P-side of a diode.

Reverse Bias

When the potential is applied in such a way that the N-side is connected to positive terminal and P-side of diode is connected to the negative terminal of the battery then no electron and hole move through the junction they attracted toward their own attached pole side of the battery thus enhancing the width of depletion layer, junction current becomes reduces to zero. This means that there is large opposition faced by carriers in reverse biasing. However, there is a small few Milliampere current drawn in reverse biased condition due to some thermal agitation process which causes electron and hole pair combination. We can set a reverse biased condition by applying a potential to the N-side such that it drives more positively than the P-side of diode.

The conclusion which we drawn from these two biasing methods is;

Under forward biased conditions n-type is more negative then p-type, depletion layer width, junction Resistance are at minimum value. And device current is at peak value. Under reverse bias every situation becomes reversed p-type is more negative than the n-side. The width of the depletion layer increase and junction resistance meet to peak value we can say it becomes infinite and the device current become negligibly zero.

Want are the characteristics that make a diode ideal?

Ideal diode act as switch. There might be two possibilities which we attain while studying ideal diode. One is open switch and other is close switch. Let’s put a through back on some characteristics which a switch possess:

Ideal diode have following properties, which I also explain in my video whose link is given below of our article source.

Ideal diode can acts as a good conductor and good insulator under varying biasing schemes.

Under reverse biased condition it act as open switch;

In such situation a diode have;
  • Infinite Resistance
  • There is no flow of current across the junction. And diode acts as prefect insulator.
  • All voltage dropped across terminal component.

Under forward biased diode act as close switch

which have following properties;

  • Zero forward resistance
  • Maximum current is dream from diode. AMD Diode acts as perfect conductor.
  • No voltage drop across the components.

Characteristics curve of ideal diode

Now consider a characteristics algorithm for an ideal diode;

Characteristics curve of a circuit is the curve which is dream between the current and voltage to explain the manner in which device work under different situation.

Forward voltage is measured along positive x- axis and reverse voltage along negative x-axis. Similarly forward current and reverse current are measured along positive y-axis and negative y-axis respectively. 1st quadrant represent the forward bias region and 3rd quadrant represent reverse biased operating system. For vertical line in forward bias region the value of forward voltage increases with increase in forward voltage. For horizontal line in reverse bias mode we see that value of reverse current remains at zero level no matter what the value of reverse voltage. This implies diode act as perfect Insulator or open switch under reverse bias condition.

Now we discuss

how practical diode is different from ideal diode and what characteristics it posses?

(a) A practical diode can’t act as a perfect conductor and perfect insulator.

(b)Under reverse bias conditions there are a few milli-ampere current flows. Its value is very low. Now the question is why its Draws a small amount of current when reverse biased, it might be due to some thermal agitation process. Let’s try to explain this query. Consider the characteristics curve of the diode in both situations ideal and practical. in an ideal diode under reverse bias, the curve starts from the origin and there is no reverse current. And knee voltage is zero. Byword knee voltage we consider a point on the current-voltage curve at which there is a sudden increase or decrease of current. When a reverse voltage is increased beyond a limit then a breakdown occurs. Which break the electron-hole pair, and provides us a flow of free charge carrier due to this reason a small current is drawn even under reverse condition for practical diode due to electron-hole pair recombination. The value of knee voltage for silicon PN-junction is 0.7 V.

( c) In an ideal diode under forward biasing there is no voltage drop. While in practical diode there is a finite voltage drop across the terminal component whose value is different for silicon and germanium PN-junction.

(d) Piratical diode offers some finite Resistance under forward biasing which can’t be ignored and under reverse biased conditions there is no infinite Resistance.

The result we obtained about the Practical diode are:

(a) As Long as the knee voltage is not reached, the diode current is zero.

(b) When the knee voltage is achieved the diode begins to work and draws forward current.

Comparison between characteristics curve of ideal diode and practical diode

Lastly, there is an observable difference between the characteristics curve of both diodes.

In an ideal diode for forward biasing the forward current is maximum and the voltage drop is zero. And under reverse conditions no matter what’s the voltage, the reverse current is zero.

While in practical diode under forwarding biased, no current is drawn until the knee voltage that is 0.7 V is reached. Once this voltage is reached and the diode start to conduct the value of knee voltage is approximately equal to forward voltage I.e 0.7 regardless of the value of forwarding current.

The comparison between voltage and current values calculated in both diodes is summarized in below pictorial representation.

Some other considerations which we should make while dealing with practical diode are;

  • Peak reverse voltage
  • Average forward current
  • Forward power dissipation

This is the article from the series of electronic devices and circuit theory. I hope this material might be helpful for you. If you have any queries you may mention your problem in the comment section. Thanks to All.

How to Use a Raspberry Pi as a DNS Server

Welcome to the next tutorial of our Raspberry Pi programming course. Our previous tutorial taught us to set up a free media server on Raspberry Pi. We also learned how to connect with different devices and stream media files. This tutorial will teach us how to use a Raspberry pi as a DNS server.

Prerequisites

You must have access to the following resources to follow this tutorial:

  • Raspbian Pi OS on Raspberry Pi (2-4).
  • Internet access is required.

There must be a unique identifier for every machine on the Internet to speak with each other Using IP addresses; clients can identify the servers they need to contact. However, no one is expected to remember the digits of an address; thus, DNS names are used instead. This DNS can be built on a Raspberry. It's a number-to-domain converter. Clients first need to get the internet address by querying Domain name servers. This can take up valuable time. As a result, it is possible to accelerate Internet connection by configuring a dedicated Domain name server.

What is a DNS server?

The DNS helps you navigate IP-based networks. You typically type in a domain name like www.example.org in your browser's address bar. Computers use iPv4 and IPv6 addresses to communicate across the Internet. However, the server must transform the memorable domain for the transmission to work. Domain name servers are utilized for name resolution. Using a cache first is necessary for this. It may not be necessary to look for the individual system's IP address in some cases.

As a result, DNS queries are routed to single or multiple servers. The internet service provider's DNS server is the first to be called upon most of the time. This DNS offers an optimum result by comparing the search with its database. Otherwise, a request is sent directly to one of the Thirteen Internet core nameservers. This database contains all of the URLs on the Internet.

Static IP addresses are rare among internet users, especially those who aren't the owners of their routers. This property goes hand in hand with the use of dynamic DNS. Internet service providers only assign IP addresses for up to 24 hours. This assignment is followed by a brief forced separation, network disconnection, and a new IP address assignment for the user. Since clients are rarely addressed from outside the home network and only make an HTTP request to the server– rather than vice versa – this usually is not an issue.

However, setting up a DNS server may be necessary for the following situations: Remote desktops and mini-game servers are two examples of this type of technology. As a result, dynamic DNS is employed. A DDNS server assigns a domain name to the domestic server, allowing it to be accessed. DynDNS is a good option if you want a web-based Domain name server that clients from anywhere in the world can access at any time.

What is the purpose of a DNS server?

For several reasons, users prefer to use Domain name servers instead of manually looking up external IP addresses. When you have a large family, numerous roommates, or an office, having your server is a no-brainer when everyone uses the same devices and shares the same network.

  • Speed: A website query may have to traverse numerous gateways and servers before reaching the user's browser. If connecting to the internet service provider's Domain name server is not required, this process can hasten the procedure.
  • Privacy: Queries must be directed to external servers to maintain the DNS functionality. Many people don't like the idea of having to follow a trail on the Internet. Much of the information is kept in your possession when using a dedicated domain name server.
  • Security: Control of Domain name server entries is available to everyone operating their server. Cyber crooks frequently try to tamper with Domain name server requests to return wrong IP addresses. Instead of displaying the intended webpage, a different one gets displayed. You can never be too careful with internet banking. Fraudsters can quickly gain control of your funds and bank account by entering your personal information on a replica of the bank's website.
  • Adblocking:Using several commercial servers to avoid advertisements blockers working around the web. Individual Domain name servers can also perform this task. Even your entire home network is untethered from the Internet.
  • Child filters:Setting up child filtering functions makes sense, like in adverts. Networks can use domain name servers to prohibit servers that deliver content inappropriate for minors.
  • Learning curve: Installing one's Domain name server is a popular approach for curious Internet users to learn more about how things work on the Internet. Wall outlets provide power, and online browsers provide content. However, like many other Raspberry projects, this one has a lot of potentials if anyone wants to get to the bottom of the technology.

How can we use a Raspberry to create a domain name server?

Step 1 - Update raspbian

To begin, use the commands below to update the software packages:

Step 2 - Installation of the DNSMasq package on Pi 4.

Once the DNSMasq tool installs, the Domain name server is configured. The Domain name server forwarder is configured with the aid of DNSMasq.

Several devices on the same network can use it to get their Domain name server queries answered. It also manages limited resources utilized while configuring the Domain name server on a Raspberry.

Step 3 – Configure DNSMasq

Increasing the DNS server's responsiveness is the goal of this stage.

Modify the dnsmasq.conf file by following the steps outlined below:

CTRL plus W will locate and delete any # symbol from the lines:

  • domain-needed ensures the Domain name server will not send out any wrong names. The local network is kept up to date by looking for names without a dot.
  • bogus-priv prohibits the server from relaying requests inside local Internet protocol ranges to extern servers. It serves as a safeguard to keep local IPs from being leaked to external services.
  • no-resolv instructs the Domain name server to utilize DNSMasq rather than /etc/resolv.conf when resolving addresses.

To remove the line displayed below, press CTRL followed by W to locate it.

Then, add these lines:

We will ensure the upstream is the Google Domain name server by completing the preceding steps.

If you want to increase the size of the cache to 1000, delete the # symbol and do the following:

It is possible to speed up response times by increasing the cache's capacity. Performance is also boosted by storing more domain name server responses.

Next, save the changes, then run the following command to reboot DNSMasq:

Use the following command to see if the DNS is up and running:

Step 4: Test the domain name server

Dig is used to verify the server's functionality. If you want to gather info about DNS servers, static IP, and other things, you can use dig in Linux.

For example:

The query execution time is shown in the preceding image.

Keep in mind that the server's response time of 1091 msec is all that matters here.

The time it takes to make a query is reduced since the address is saved in the cache. The image below makes this quite evident.

Keep in mind that the Request Time is all that matters.

Step 5 – Configure the domain name server on your device

Ifconfig is used to get the raspberry network address.

For example, our server Ip is 10.0.2.15.

The next step is to configure devices to use this Ip as their Domain name server. To make this happen on your Windows PC, follow these steps:

Press Windows key Plus R to access run, access the Control panel by typing control, and press Enter.

In the control panel, select Network and Internet.

Afterwards, click on the View networks option in the newly opened window that appears.

Choose adapter configuration from the left-hand menu of the new pane.

You may do this by right-clicking on the interface you're using, such as Wlan0 or Eth0, and selecting Preferences.

Right-click on TCP/IPv4 and choose Preferences once more.

Then choose those Domain name server addresses from the drop-down menu that appears inside the new window.

Using a Raspberry, you can maximize the speed of the network. Domain name server query response times can be sped up by storing IPs in a local cache.

Keeping a Domain name server safe is essential since it is a common target for fraudsters.

Ensure that the upgrades automatically keep it running smoothly. Use the following command to upgrade.

DNS Query Resolution by DNS Servers

Whenever you enter a web link into the browser's address bar, a Domain name server searches for the desired address. As a result, various Domain name servers are queried, and each of them performs a translation of the domain you entered. The following are the several servers that are contacted:

  • DNS Resolver: Converts the domain name to an IP address when a request is made. When looking for a specific website, this server conducts the heavy lifting of determining its location on the Internet.
  • Root Server: After receiving a request, the server tells Domain name server resolvers where to find information about the top-level domain server of the site. In another way, the .com part of your domain is known as the top-level domain.
  • TLD Server: As a result, the Domain name server resolvers query this server, which returns the actual authorized name server.
  • Authoritative Name Server: Lastly, the Domain name server makes a query to this server to get the unique IP of that website you are attempting to access.

You'll see the web page you were looking for after the Ip has been found in the internet browser. Even while it sounds complicated, the process is relatively simple and takes only a few seconds to get you back to the website of your choice.

Types of DNS attacks that are most common

A denial-of-service

A single denial of service assault can overwhelm a web server with just one machine and one internet connection. When it comes to overloading the high-capacity systems today, they don't work very well.

Domain name server amplification attack

Another sort of Cyberattack known as a DNS magnification is where attackers exploit open Domain name servers to overwhelm domain name server responses. As part of an attack, the intruder spoofs the user's Domain name server source address and sends another request to the open DNS. The Domain name server response is sent to the destination rather than the Domain name server.

Domain name server hijacking

Domain name server hijacking can take place in three ways:

  1. A registrar domain account can be hacked, and the DNS can be modified to one that the intruders have control over.
  2. Malicious people target you by changing the A record on the IP of your domain.
  3. The router is compromised when an intruder modifies the Domain name server that is automatically dragged down to every device whenever a user connects.

Domain name server tunnelling

Domain name server tunnelling uses the Domain name server protocol, which is used to determine the network id to transfer data.

When a client sends a domain name server request, the only info included is that which is necessary for the server and the client to communicate. By using Domain name server tunnelling, an extra set of data is routed over the network. Communication can proceed unhindered by filtering, firewall, or sniffing software.

As a result, it is challenging to identify and trace its origins. It is possible to establish command structure and control via Domain name server tunnelling. It is also capable of leaking data. When information travels via a Domain name server, it is often broken down into smaller bits and reconstructed.

poisoning of DNS and the poisoning of the cache

Web traffic can be redirected to infected sites using security holes in the domain name server protocol known as domain name server poisoning or server spoofing.

When you visit a website, your internet browser first asks for a local Domain name server for the Ip. The local domain name server will contact the root servers of the domain and authoritative name servers to obtain the address of your domain.

How can we avoid, identify, and respond to domain name server attacks?

  1. You should be familiar with your complete domain name server infrastructure. To begin, safeguarding a network necessitate familiarity with all of your company's DNS records. Occasionally, network administrators lack total visibility due to Domain name server silos, orphan zones, or shadow technologies.
  2. Domain name server responses and queries should be logged and monitored—first, spot anomalies by logging in and monitoring outgoing and incoming requests. An in-depth forensic investigation might be aided by collecting more responses.
  3. Secure your Domain name server recursive servers.Recursive servers can be protected from unauthorized access and modification with DNSSEC and other design changes.
  4. Secure your Domain name servers by limiting administrator privileges.

What are DNS servers used for?

For the Internet to function, a company's ICT department must support the DNS servers as a critical piece of infrastructure. A well-maintained authoritative Domain name server is required for this.

The most important thing to remember is that a server going offline is impossible with an adequately designed anycast Domain name server. It is possible to maintain each server at a time while providing a fast and reliable Domain name server by connecting geographically distributed endpoints with redundancy servers at every station.

Do you need a "perfect" domain name server? Yes, Outages to your external Domain name server can have a direct impact on the following departmental activities:

  • Primary websites
  • Marketing campaign website
  • Email server
  • Client support website
  • Online resource library
  • Webinar service
  • Instant message tool
  • IoT devices

This is an extensive list, but there are likely many more devices and programs that rely on the Domain name server to work correctly. Although outages and poor performance can harm your bottom line, the ROI is robust and measurable. As long as a Domain name server outage spares your team from having to meet with the above departments, the service will pay for itself.

Conclusion

This tutorial taught us how to use a raspberry pi as a DNS server. We also learned the possible attacks on a domain name server and how to prevent these attacks. In the following tutorial, we will learn how to use a raspberry pi as a VPN server.

Syed Zain Nasir

I am Syed Zain Nasir, the founder of <a href=https://www.TheEngineeringProjects.com/>The Engineering Projects</a> (TEP). I am a programmer since 2009 before that I just search things, make small projects and now I am sharing my knowledge through this platform.I also work as a freelancer and did many projects related to programming and electrical circuitry. <a href=https://plus.google.com/+SyedZainNasir/>My Google Profile+</a>

Share
Published by
Syed Zain Nasir