Verilog Assignment Explain In Telugu || continuous assignments and procedural assessment

VLSI_badi
23 Dec 202309:27

Summary

TLDRThe script discusses the concept of assignments in programming, distinguishing between continuous and procedural assignments. It explains the process of using continuous assignments to drive values, utilizing variables and operations like 'sin' in a module. The tutorial covers the execution of code in initial and always blocks, the update of variables in procedural assignments, and the use of events and sensitivity lists to control the flow of simulation. It also touches on the differences between synchronous and asynchronous circuits in the context of hardware description languages.

Takeaways

  • 📌 The topic discussed is about 'Assignments' in the context of continuous and procedural assignments.
  • 🔁 Continuous assignments are used to define signals in terms of other signals, using the syntax 'y = a * b' where 'a' and 'b' are values assigned.
  • 💡 Procedural assignments are used to update values of variables under control of control statements, such as loops and conditionals.
  • 🔧 The script provides an example of procedural code using the 'always' block, which is executed every time there is a change in the simulation time.
  • 🔄 The concept of 'initial block' is introduced, which contains code that is executed only once at the start of the simulation.
  • 🔢 The script explains how to use the 'always' block with a '#delay' construct to simulate time delays in procedural assignments.
  • 🔀 The difference between synchronous and asynchronous loops is highlighted, with synchronous loops executing in parallel and asynchronous loops executing sequentially.
  • 📈 The script discusses the use of 'sensitivity lists' to specify which signal changes should trigger the execution of procedural blocks.
  • 🚦 The importance of 'event controls' is emphasized for defining the conditions under which procedural blocks should execute, such as on the positive or negative edge of a signal.
  • 🛠️ The script provides insights into how to structure code within 'always' blocks to handle different types of events and conditions in hardware description languages.

Q & A

  • What are the two types of assignments mentioned in the script?

    -The two types of assignments mentioned are continuous and procedural assignments.

  • What does the acronym 'FPGA' stand for in the context of the script?

    -FPGA stands for Field Programmable Gate Array, which is a type of programmable logic device discussed in the script.

  • What is the significance of 'asynchronous' and 'synchronous' in the script?

    -Asynchronous and synchronous refer to the timing of events in digital circuits. Asynchronous means that events do not depend on a clock signal, while synchronous events are coordinated by a clock signal.

  • What is the role of the 'initial block' in the script's context?

    -The 'initial block' is used to execute statements once at the beginning of the simulation, typically used for initializing variables.

  • What does the 'always block' represent in the script?

    -The 'always block' is used to define a set of actions that should be performed whenever a change occurs on its sensitivity list, which includes clock signals and other events.

  • How is the 'for loop' described in the script?

    -The 'for loop' is described as a way to repeat a block of code a certain number of times, with the loop variable being updated at each iteration.

  • What is the purpose of the 'sensitivity list' in the script?

    -The 'sensitivity list' specifies the set of signals that can trigger the execution of an 'always block' in a dataflow model.

  • What is the difference between 'positive edge' and 'negative edge' triggers as mentioned in the script?

    -A 'positive edge' trigger occurs when a signal transitions from low to high, while a 'negative edge' trigger occurs when a signal transitions from high to low.

  • What is the concept of 'simulation time' explained in the script?

    -Simulation time refers to the time progression in a digital simulation, which is often measured in units such as nanoseconds or time steps.

  • What is the function of the 'end' keyword in the context of the script?

    -The 'end' keyword is used to signify the end of a block of code such as loops, conditional statements, or module definitions.

  • How are 'events' utilized in the script?

    -Events are used to trigger certain actions or processes in the script, often related to changes in signal values or other conditions.

Outlines

00:00

🧮 Introduction to Continuous Assignments in Asynchronous Programming

The paragraph introduces the concept of continuous assignments in asynchronous programming, distinguishing them from procedural assignments. It explains that continuous assignments are used to drive values onto nets and are either concurrent or procedural. The focus is on concurrent continuous assignments, which are used to drive values onto nets and variables. The paragraph uses the keyword 'always' to illustrate how continuous assignments are defined in Verilog. It provides an example of a simple continuous assignment using the 'assign' statement with variables 'a' and 'b', and explains how the output 'y' is derived using the sine function. The discussion also touches on the execution of these assignments in parallel and the concept of zero simulation time, which is crucial for understanding the behavior of continuous assignments in simulation environments.

05:00

🔁 Looping and Event Control in Asynchronous Programming

This paragraph delves into the mechanics of looping and event control in asynchronous programming. It discusses the use of 'initial' and 'always' blocks, explaining that 'initial' blocks execute only once, similar to a procedural block, while 'always' blocks can be set to execute repeatedly. The paragraph provides an example of a code snippet within an 'initial' block, which is executed only once, and contrasts this with an 'always' block that is set to repeat. It also covers the concept of loops, specifically 'for' loops, and how they are used to iterate over a set of values. The discussion includes the update of variables within the loop and the impact of these updates on the loop's execution. Additionally, the paragraph touches on the use of event controls, such as '@' and 'negedge', to trigger actions based on specific events, and the importance of sensitivity lists in defining which events should trigger the execution of a block of code.

Mindmap

Keywords

💡Assignments

Assignments refer to the process of assigning values to variables in programming. In the context of the video, assignments are used to define and update the values of variables like 'a', 'b', and 'c' during the execution of code. For instance, the script mentions 'a = 1' and 'b = a + 1', illustrating how variables are assigned values that are used in subsequent operations.

💡Continuous Assignments

Continuous assignments are a type of assignment in programming that continuously updates the value of a variable as long as the condition is true. The video discusses continuous assignments in the context of driving values on to nots or variables, indicating that these values are dynamically updated throughout the program's execution.

💡Procedure

A procedure in programming is a set of instructions that perform a specific task. The video script mentions 'procedure' in relation to procedural assignments, which are likely a type of assignment that follows a defined procedure or process within the program.

💡Simulation Time

Simulation time refers to the time during which a simulation or a program is running. The script discusses the concept of zero simulation time, indicating the start of the simulation process, and how certain operations or events are triggered based on the simulation time.

💡Initial Block

The initial block in programming is a section of code that is executed only once when the simulation starts. The video explains that code placed in the initial block, such as 'initial begin', is executed a single time at the start, setting up initial conditions or performing one-time calculations.

💡Always Block

An always block is a construct in programming that allows for repeated execution of a block of code. The video mentions that code within an always block is executed repeatedly, which is crucial for creating loops or continuous checks within a simulation.

💡For Loop

A for loop is a control flow statement that allows code to be executed repeatedly based on a given condition. The script discusses the use of for loops, such as 'for nano seconds', to iterate over a range of values, performing operations multiple times within the loop.

💡Event Control

Event control in programming refers to the management of events and their triggers within a program. The video talks about positive and negative edge events, which are types of events that are triggered based on the change in signal values, such as rising or falling edges in digital signals.

💡Sensitivity List

A sensitivity list in programming, particularly in simulation contexts, defines a set of variables that the block of code is sensitive to. The video explains that the sensitivity list determines which changes in variable values will trigger the re-execution of the always block, ensuring that the code reacts to relevant changes.

💡Asynchronous

Asynchronous operations in programming are those that do not wait for other processes to complete before proceeding. The video discusses asynchronous behavior in the context of signal processing, where certain operations may not depend on the completion of previous operations, allowing for parallel processing.

💡Synchronous

Synchronous operations are those that occur in a coordinated manner, often waiting for certain conditions to be met before proceeding. The script mentions synchronous circuits, indicating that certain operations are performed in a sequence that is dependent on the completion of previous steps.

Highlights

Introduction to the concept of 'Topic' being discussed as 'Various Assignments'.

Explanation of two types of assignments: Continuous and Discrete.

Discussion on Continuous Assignments and their role in driving values.

Introduction to the concept of 'Always' block in continuous assignments.

Explanation of how to use 'Always' block to define continuous assignments.

Description of the 'Initial' block and its purpose in defining starting values.

Detailing the difference between 'Initial' and 'Always' blocks in terms of execution.

Explanation of the 'For' loop and its continuous nature in assignments.

Description of how values are updated in a 'For' loop during continuous assignments.

Discussion on the zero simulation time and its impact on the execution of continuous assignments.

Explanation of the process and timing of variable updates in procedural assignments.

Detailing the role of 'Begin' and 'End' keywords in defining the timing of procedural assignments.

Description of the 'If' statement and its use in conditional assignments.

Explanation of how to handle positive and negative edge-triggered events in event controls.

Discussion on synchronous and asynchronous circuit design using event controls.

Detailing the use of sensitivity lists to define which signals trigger an event.

Explanation of how to write code for synchronous and asynchronous circuit designs.

Description of the concept of a clock and its importance in synchronous designs.

Detailing the process of defining a clock and its impact on synchronous circuit behavior.

Explanation of the role of 'Always' block in procedural continuous assignments.

Description of the 'Initial' block's role in setting up initial conditions for simulation.

Transcripts

play00:00

హాయ్ ఫ్రెండ్స్ ఈరోజు మనం తెలుసుకోబోయే

play00:02

టాపిక్ అనేది వేరే అసైన్మెంట్స్ అన్నమాట

play00:04

సో అసైన్మెంట్స్ అనేవి రెండు రకాలు

play00:06

అన్నమాట ఒకటి కంటిన్యూస్ ఇంకోటి ప్రొసీజర్

play00:09

సో ఫస్ట్ కంటిన్యూస్ అసైన్మెంట్ గురించి

play00:11

తెలుసుకుందాం కంటిన్యూస్ అసైన్మెంట్స్ ఆర్

play00:13

యూస్డ్ టు కంటిన్యూస్ టు డ్రైవ్ ద

play00:15

వాల్యూస్ ఆన్ టు నట్స్ ఆర్ వేరియబుల్ సో

play00:18

కంటిన్యూస్ కంటిన్యూస్ గా అసైన్మెంట్స్

play00:20

అనేవి జరగా డ్రైవ్ చేయడానికి వాల్యూస్

play00:22

తెలుసుకోవడానికి మనం కంటిన్యూస్

play00:23

అసైన్మెంట్స్ అనేవి యూస్ చేస్తాం అన్నమాట

play00:25

సో కంటిన్యూస్ అసైన్మెంట్స్ లో మనం

play00:27

కంపల్సరీ అసైన్ కీ వర్డ్ అనేది మనం యూస్

play00:29

చేస్తాం అన్నమాట కీవోర్డ్ అనేది యూస్

play00:30

చేస్తాం సో ఎగ్జామ్పుల్ గా మనం ఇక్కడ

play00:32

చూసుకున్నట్లయితే ఫస్ట్ ఆ వెరిలా కోడ్

play00:35

అనేది మాడ్యూల్ దానికి

play00:38

రాశాను మాడ్యూల్ అనేది రాశాను సో ఇక్కడ

play00:41

మీరు చూసుకున్నట్లయితే అసైన్ అని రాసి y=

play00:44

a అండ్ బి అని ఇచ్చాను అన్నమాట సో ఇక్కడ

play00:45

ఏమవుతుంది అసైన్ అనేది యూస్ చేయడం వల్ల y=

play00:47

a అండ్ బి మనం ఆ ఏ అండ్ బి కి ఏవైనా

play00:50

వాల్యూస్ ఇచ్చినప్పుడు దాని ఔట్ పుట్ అండ్

play00:51

ఆపరేషన్ చేసి y కి అనేది అసైన్ అవుతది

play00:53

అన్నమాట సో ఇలాగ ఈ ఒక్క దాన్ని కొనడం వల్ల

play00:56

కంటిన్యూషన్ అనేది జరుగుతుంది లేదా మీరు

play00:58

నెంబర్ ఆఫ్ ఎస్ అండ్ వాల్యూస్ సో ఇది ఒక

play00:59

sn మైనస్ ఇదొక నెంబర్ ఆఫ్ ఎస్ ఎన్

play01:01

వాల్యూస్ రాసాం అనుకోండి ఫస్ట్ ఇది ఏ అండ్

play01:03

బి ఇది ఏ ఆర్ బి ఇది ఏ ఎక్స్ ఆర్ బి సో

play01:05

ఇలా నెంబర్ ఆఫ్ ఎస్ ఎన్ వాల్యూస్

play01:06

రాసినప్పుడు కూడాను మనకి అవుట్ పుట్ అనేది

play01:09

ఓకే పార్లల్ గా జరుగుతుంది ఎగ్జిక్యూషన్

play01:10

అనేది పార్లల్ గా ఎన్ని నెంబర్ ఆఫ్ ఎస్

play01:12

ఎన్ వాల్యూస్ ఎన్ని ఉంటే అవన్నీ కూడా

play01:15

పార్లల్ గా జరుగుతాయి

play01:17

అన్నమాట ఎగ్జిక్యూషన్ ఇన్ పార్లల్

play01:20

నెక్స్ట్ చూసుకున్నట్లయితే ఇక్కడ మీరు

play01:22

ఫస్ట్ sn అనేది y1 ఏ అండ్ బి సో ఇదొకటి

play01:25

జరిగింది ఇదొకటి జరిగింది సో ఇక్కడ మీరు

play01:26

చూసిన ఇవన్నీ పార్లల్ గానే జరుగుతాయి

play01:28

బిగిన్ ఎండ్ లో రాసినట్టు పార్లల్ గానే

play01:29

జరుగుతుంది కాకపోతే ఇది వచ్చినప్పుడు జీరో

play01:32

సిములేషన్ టైం లో వచ్చేస్తది ఇది

play01:34

వచ్చినప్పుడు ఆ 2

play01:37

రెండు టు టూ నానో సెక్షన్స్ డిలే వస్తది

play01:40

ఇది ఫైవ్ నానో సెక్షన్స్ డిలే కింద సో ఈ

play01:42

డిలే కింద అవుతది కానీ కాకపోతే

play01:43

ఎగ్జిక్యూషన్ అనేది ఇప్పుడు పార్లల్ గానే

play01:45

జరుగుతది అన్నమాట సో ఇది కంటిన్యూస్

play01:48

అసైన్మెంట్స్ అన్నమాట నెక్స్ట్ ప్రొసీజరల్

play01:50

అసైన్మెంట్స్ ప్రొసీజరల్ అసైన్మెంట్స్

play01:52

అప్డేట్ ద వాల్యూ ఆఫ్ వేరియబుల్స్ అండర్

play01:54

ది కంట్రోల్ ఒక్కొక్క మనం అప్డేట్

play01:56

చేసినప్పుడు ఒక్కొక్క వాల్యూ అనేది అదే

play01:58

వాల్యూస్ అనేది అసైన్ చేసినప్పుడు

play02:00

ఒక్కొక్కసారి అప్డేట్ అవుతుంది అందులో

play02:01

ఫస్ట్ ఇనిషియల్ బ్యాక్ నెక్స్ట్ ఆల్వేస్

play02:03

బ్లాక్ ఇనిషియల్ అంటే జస్ట్ ఒకసారి

play02:05

ఎగ్జిక్యూట్ మాత్రమే ఎగ్జిక్యూట్ స్టార్ట్

play02:07

జీరో సిములేషన్ టైం ఓన్లీ వన్ టైం

play02:09

ఎగ్జిక్యూటబుల్ మనం ఏదైనా కోడ్

play02:11

రాసినప్పుడు దాన్ని ఇనిషియల్ బ్లాక్ లో

play02:12

రాసిన రాసినట్లయితే ఆ కోడ్ అనేది ఒకసారి

play02:15

మాత్రం ఎగ్జిక్యూట్ అవుతుంది అన్నమాట

play02:16

ఇక్కడ మీరు చూసుకున్నప్పుడు ఇక్కడ ఒక కోడ్

play02:18

రాశాను ఇదొక కోడ్ రాశాను దీన్ని ఇనిషియల్

play02:22

ఇనిషియల్ పెట్టి ఇనిషియల్ లో రాశాను సో

play02:24

ఇనిషియల్ రాసినప్పుడు ఈ కోడ్ ఏమవుతుంది

play02:26

అనుకోండి ఓన్లీ ఒక్కసారి మాత్రమే

play02:27

ఎగ్జిక్యూట్ అవుతుంది అన్నమాట ఓన్లీ

play02:29

ఒక్కసారి మాత్రమే కోడ్ ఎగ్జిక్యూట్ అవుతది

play02:31

దాన్నే ఇనిషియల్ బ్లాక్ ఇనిషియల్ బ్లాక్

play02:32

అన్నమాట సో ఇనిషియల్ బ్లాక్ ఎగ్జిక్యూట్

play02:34

ఓన్లీ వన్ టైం నెక్స్ట్ ఆల్వేస్ బ్లాక్

play02:36

ఆల్వేస్ బ్లాక్ అంటే ఏంటి రిపీటెడ్ గా

play02:38

జరుగుతది అన్నమాట ఇది ఒకసారి జరుగుతది ఇది

play02:40

రిపీటెడ్ గా జరుగుతుంది సో ఈ కోడ్ అనేది

play02:42

సేమ్ కోడే ఇది ఒకసారి రిపీట్ లో

play02:44

పెట్టినప్పుడు ఆల్వేస్ దీన్ని సేమ్ సేమ్

play02:47

కోడ్ ఇక్కడ

play02:48

రాశాను కాకపోతే దీన్ని ఆల్వేస్ బ్లాక్

play02:51

రాశాను సో ఆల్వేస్ బ్లాక్ లో ఏమవుతుంది

play02:52

అంటే వన్స్ ఈ కోడ్ ఇక్కడికి వచ్చిన తర్వాత

play02:54

మళ్ళా మొదటికి వెళ్తాది అన్నమాట సో రిపీట్

play02:56

కంటిన్యూస్ గా కంటిన్యూస్ గా లూప్ లూప్

play02:58

ఫామ్ అవుతూ ఉంటది అన్నమాట రిపీట్ కంటిన్యూ

play03:00

త్రూ ద డ్యూరేషన్ ఆఫ్ ది సిములేషన్ టైం

play03:02

ఎగ్జిక్యూషన్ ఇది కూడా జీరో సిములేషన్ టైం

play03:05

లో స్టార్ట్ అవుతుంది సో ఇక్కడ మీరు

play03:06

చూసుకున్నట్లయితే ఇది జీరో సిములేషన్ ఇది

play03:08

జీరో సిములేషన్ టైం లోనే స్టార్ట్

play03:10

అవుతుంది అన్నమాట సో ఇప్పుడు

play03:11

చూసుకున్నట్లయితే ఇది ఇనిషియల్ కి ఇది

play03:13

ఆల్వేస్ కి ఒక ఎగ్జాంపుల్ చేసుకొని

play03:15

చూద్దాము సో రెండు ఏ విధంగా కోడ్

play03:17

రాసినప్పుడు ఆక్ట్ అవుతాయి అనేది ఫస్ట్

play03:19

ఇనిషియల్ గా జీరో సిములేషన్ టైం లో

play03:21

ఏమవుతది a = 1 ఉంది సో మనం బి వాల్యూస్ బి

play03:24

వాల్యూస్ సి వాల్యూస్ ఏవి తీసుకోలేదు

play03:26

కాబట్టి సో బి అనేది సి వాల్యూస్ డైరెక్ట్

play03:28

గా అలా వన్ అని వచ్చేస్తది అన్నమాట

play03:30

నెక్స్ట్ టు నానో టు నానో సెక్షన్ డిలే

play03:34

దగ్గర ఏమవుతది b= a + 1 మనకి ఏ వాల్యూ ఎంత

play03:38

ఉంది ఏ వాల్యూ వన్ ఉంది సో వన్ ప్లస్ వన్

play03:41

సో బి = 2 అవుతది అన్నమాట సో మనకి ఇక్కడ

play03:43

బి వాల్యూ 2 వచ్చిందన్నమాట నెక్స్ట్ సి

play03:45

దగ్గర సేమ్ టు నానో సెకండ్స్ దగ్గరే 2నో

play03:49

సెకండ్స్ దగ్గర ఏమవుతది నెక్స్ట్ c = b

play03:52

ప్లస్ వన్ బి వాల్యూ ఎంత దగ్గర వచ్చింది

play03:53

ఇక్కడ 2 వచ్చింది 2+1 3 సో c = 3

play03:56

వచ్చిందన్నమాట నెక్స్ట్ a ఏ వాల్యూ 8

play03:59

అవుతుంది ఇది కూడా 29 వచ్చింది ఎందుకంటే

play04:00

మధ్యలో ఇంకా డిలేలు ఏమి లేవు అన్నమాట

play04:02

నెక్స్ట్ a = b+1 b వాల్యూ ఎంత

play04:05

2+1=3 సో 3 వచ్చిందన్నమాట నెక్స్ట్ ఇక్కడ

play04:09

ఇదేంటి బ్లాకింగ్ ఎక్స్మెంట్ కాబట్టి సో

play04:11

e2 + e2 నెక్స్ట్ మొత్తం కలిపి ఫోర్

play04:13

అవుతది అన్నమాట సో ఫోర్ నానో సెకండ్స్

play04:16

అవుతది అన్నమాట సో ఈ ఫోర్ నానో సెకండ్స్

play04:18

తర్వాత b = b + 1 మనకి ఇంతకు ముందు

play04:20

చూసుకున్నట్లయితే బి వాల్యూ ఎంత వచ్చింది

play04:21

2 వచ్చింది ఆ 2+1 సో మనకి బి వాల్యూ కూడా

play04:26

త్రీ అవుతది అన్నమాట బి వాల్యూ త్రీ ఉంది

play04:29

ఇక్కడ చూసుకున్నట్లయితే 313 ఇదే ఇది ఈ

play04:31

కోడ్ అనేది ఒకసారి మాత్రమే ఎగ్జిక్యూట్

play04:33

అయ్యింది నెక్స్ట్ ఆల్వేస్ బ్లాక్

play04:35

చూసుకున్నట్లయితే ఇక్కడ ఏమవుతుంది అంటే

play04:37

ఫస్ట్ ఇనిషియల్ గా జీరో నానో సెకండ్స్

play04:38

దగ్గర a అనేది ఎంత ఉంది a = 1 ఉంది

play04:41

నెక్స్ట్ టు నానో సెకండ్స్ దగ్గర b = a +

play04:45

1 b మనకి a = 1 ఉంది కాబట్టి b=

play04:48

ఏమవుతుంది సో ఈ రెండు అన్నోన్ నెక్స్ట్ టు

play04:50

నానో సెకండ్స్ దగ్గర a = ఫస్ట్ టూ నైన్స్

play04:53

దగ్గర b=a+1 మనకి చూసుకున్నట్లయితే ఏ

play04:56

వాల్యూ వన్ ఉంది సో వన్ ప్లస్ వన్ టు సో

play04:58

బి వాల్యూ ఈక్వల్ టు 2 నెక్స్ట్ సి

play05:00

చూసుకున్నట్లయితే బి ప్లస్ వన్ బి బి

play05:01

వాల్యూ ఎంత మనకి 2 b వాల్యూ మనకి 2

play05:04

వచ్చిందన్నమాట సో 2+1 సో c =

play05:08

3 నెక్స్ట్ a ఏ చూసుకున్నట్లయితే a కూడా

play05:11

29 సెకండ్స్ దగ్గర ఉంది సో a = b+1 మనం

play05:14

ఇక్కడ చూసుకున్నట్లయితే బి ఎంత మనకి 2

play05:16

అన్నమాట 2+1

play05:21

a=3 ఇక్కడ మీరు ఫోర్ నానో సెక్షన్

play05:24

చూసుకున్నట్లయితే a ఈక్వల్

play05:27

టు బి = b+1 బి బి ఎంత

play05:31

మనకి ఇక్కడ అప్డేట్ అయ్యింది సో ఇక్కడ

play05:35

2+2+1= b=3 అవుతుంది

play05:38

అన్నమాట ఇక్కడ బి వాల్యూ 3 వచ్చింది ఇక్కడ

play05:41

మీరు చూసుకున్నట్లయితే సి లేదు ఏ లేదు సో

play05:43

ఇక్కడ ఇక్కడ మీరు చూసుకున్నట్లయితే ఇక్కడ

play05:45

ఆల్వేస్ అనేది లూప్ కంటిన్యూస్ అవుతది

play05:47

కాబట్టి సో ఇక్కడి నుండి వచ్చింది మళ్ళా

play05:49

ఇక్కడికి వెళ్తది అన్నమాట సో అప్పుడు ఈ

play05:51

ఫోర్త్ నానో సెక్షన్స్ దగ్గర ఏమవుతది a =

play05:54

1 అసైన్ ఉంది సో a = ఇక్కడ వన్ వస్తది

play05:57

అన్నమాట సి కి మనం ఫోర్ నానో సెక్షన్స్

play05:59

దగ్గర ఏం లేదు సో ఫోర్ హ్యాండ్స్ దగ్గర సి

play06:01

వాల్యూ ఎంత ఉందో దాన్ని ఇక్కడ వస్తుంది

play06:03

మీరు ఇక్కడ చూసుకున్నట్లయితే ఇక్కడ ఎక్కడ

play06:04

చేంజ్ అవుతుంది ఇనిషియల్ కి ఆల్వేస్ కి సో

play06:07

ఇది మాత్రం చేంజ్ అవుతుంది సో ఇది వన్స్

play06:10

ఎగ్జిక్యూట్ అవుతది ఇది వన్స్ ఎగ్జిక్యూట్

play06:12

అయితే మళ్ళా లూప్ లోకి వెళ్తాది అన్నమాట

play06:13

మీరు ఇక్కడ చూసుకున్నట్లయితే ఏ వాల్యూ

play06:14

అనేది ఇక్కడ లేదు ఎండింగ్ లో ఏ వాల్యూ

play06:17

అనేది ఇక్కడ లేదు సో అందువల్ల ఇది అనేది

play06:19

ఇక్కడ స్టాప్ అయిపోయింది ఏ వాల్యూ ముందు

play06:21

ఎంత ఉందో ఇప్పుడు కూడా అంతే వచ్చింది

play06:22

అన్నమాట కాకపోతే ఇక్కడ చూసుకున్నట్లయితే

play06:24

మళ్ళా లూప్ కి వెళ్ళింది కాబట్టి ఇక్కడ ఏ

play06:26

వాల్యూ మళ్ళా స్టార్టింగ్ కి వచ్చినప్పుడు

play06:28

ఆ ఫోర్ నానో స్టేషన్ దగ్గరే a = 1 అయింది

play06:30

అన్నమాట సో అందువల్ల a = 1 అనేసి ఫోర్

play06:34

నానస్ దగ్గర మనకి ఇక్కడ డిస్ప్లే అయ్యింది

play06:35

అన్నమాట ఈ విధంగా ఇనిషియల్ ఆల్వేస్ బ్లాక్

play06:38

అనేది యూస్ చేస్తాం అన్నమాట నెక్స్ట్

play06:42

ఈవెంట్ కంట్రోల్స్ అన్నమాట మనం ఏ విధంగా ఈ

play06:44

ఈవెంట్ ని చేస్తున్నప్పుడు మనం కోడ్

play06:46

రాసినప్పుడు ఆల్వేస్ @ పాజిటివ్ క్లాక్

play06:48

నెగేజ్ క్లాక్ సో ఈ విధంగా యూస్ చేస్తాం ఏ

play06:50

చేంజ్ ఇన్ వాల్యూ ఆఫ్ రిజిస్టర్ నెట్ ది

play06:53

ఈవెంట్ కంట్రోల్ అంటే మనం డైరెక్ట్ గా

play06:55

పాజిటివ్ గాని నెగేజ్ గాని ఈ విధంగా మనం

play06:58

ఇచ్చిన ట్రిగ్గరింగ్ ట్రిగ్గర్ ఇవన్నీ

play07:00

ట్రిగ్గరింగ్ అన్నమాట ట్రిగ్గరింగ్

play07:01

ఇచ్చినప్పుడు మనకి ఆ ఈవెంట్ అనేది

play07:03

జరుగుతది అన్నమాట ఫస్ట్ ఆల్ ద పాసెజ్

play07:05

క్లాక్ పాసేజ్ క్లాక్ ఎప్పుడు అవుతది అంటే

play07:08

మనం క్లాక్ ఇచ్చినప్పుడు అది ఎప్పుడు

play07:10

పాసేజ్ క్లాక్ తగులుతదో అప్పుడు అన్నది

play07:12

ట్రిగ్గర్ అయ్యి మనకి ఆ కోడ్ లో ఏది

play07:15

రాసామో అదంతా ఎగ్జిక్యూట్ అవుతది అన్నమాట

play07:17

నెక్స్ట్ ఆల్ నెగజ్ నెగజ్ అన్నప్పుడు

play07:19

ఎప్పుడైతే మనకి నెగజ్ నెగజ్ అనేది అవుతాదో

play07:23

అప్పుడనేది ఆ కోడ్ అనేది ఎగ్జిక్యూట్

play07:26

అవుతది అన్నమాట సో ఈ రెండు సింక్రనస్ కి

play07:28

అన్నమాట సింక్రోనస్ సింక్రోనస్

play07:31

సర్క్యూట్లు మాత్రమే ఈ రెండు యూస్

play07:32

చేస్తారు అసింక్రనస్ సర్క్యూట్ కి

play07:33

డైరెక్ట్ గా ఆల్వేస్ పాజిటివ్ నెగిటివ్ ఈ

play07:36

విధంగా మనం డిఫైన్ చేస్తాం అన్నమాట

play07:38

అసింక్రోనస్ కి అసింక్రోనస్ కి మనం ఈ

play07:41

విధంగా రాస్తాం ఇప్పుడు కోడ్ రాసినప్పుడు

play07:44

ఆల్వేస్ అడ్జ్ పాసేజ్ క్లాక్ ఆర్ నెగేజ్

play07:47

క్లాక్ అని రాస్తాం సింక్రోనస్ లో మనకి

play07:50

ఐదర్ పాసేజ్ అయినా నెగజ్ అయినా ఎందుకంటే

play07:52

సింక్రోనస్ డైరెక్ట్ గా మనం అన్నిటికీ ఒకే

play07:55

క్లాక్ ఇస్తాం అన్నమాట సో ఒకే క్లాక్ ఇది

play07:57

పాసేజ్ క్లాక్ నెగజ్ క్లాక్ అని మనం

play07:59

డిసైడ్ చేస్తాం సో అసింక్రోనస్ క్లాక్

play08:01

ఏమవుతది దీని యొక్క అవుట్పుట్ దీనికి

play08:03

క్లాక్ గా వెళ్తది సో ఈ విధంగా మనం

play08:05

అసింక్రోనస్ ని పాసివ్ ఆర్ నెగటివ్ క్లాక్

play08:07

కింద మనం ఈ విధంగా డిఫైన్ చేస్తాం అన్నమాట

play08:09

నెక్స్ట్ సెన్సిటివిటీ లిస్ట్ సో

play08:11

సెన్సిటివ్ లిస్ట్ అంటే ఇక్కడ మీరు

play08:14

చూసుకున్నట్లయితే ఒక ఎగ్జాంపుల్

play08:16

సెన్సిటివిటీ వితౌట్ సెన్సిటివ్ లిస్ట్ ద

play08:18

ఆల్వేస్ బ్లాక్ విల్ లూప్ కంటిన్యూస్లీ

play08:20

వితౌట్ వెయిటింగ్ ఫర్ ద ట్రిగ్గరింగ్

play08:22

ఈవెంట్ ఇక్కడ ఒక ఎగ్జాంపుల్ దీన్ని బట్టి

play08:24

మీకు అర్థం అవుతుంది సో ఇక్కడ ఇక్కడ

play08:26

చూశాను చూడండి @ a b సెలెక్షన్ లైన్ సో

play08:29

ఇక్కడ మీరు చూసుకుంటే ఉన్నట్లయితే ఇవి మనం

play08:30

ఇనిషియల్ గా మోడ్యూల్ లో

play08:33

రాసినప్పుడు ఆ 2*1 మార్క్స్ అనుకో 2*1

play08:36

మార్క్స్ సో దీనికి ఏముంటాయి ఏ బి

play08:40

సెలెక్షన్ లైన్ అన్నమాట సో అవుట్పుట్ సో ఈ

play08:42

విధంగా మన ఎప్పుడైనా ఈ సెన్సిటివిటీ

play08:45

లిస్ట్ లో ఇన్పుట్స్ సెలెక్షన్ లైన్స్

play08:47

మాత్రం రాస్తాం సో a b సెలెక్షన్ లైన్ సో

play08:50

a b ఇన్పుట్స్ మనం

play08:52

ఏవేవనే ఉంటాయో వాటిని మాత్రమే ఇందులో

play08:54

రాస్తాం అన్నమాట లేదా స్టార్ కిందనే మనం

play08:57

మెన్షన్ చేయొచ్చు ఇన్ కేస్ మనం ఈ

play08:59

సెలెక్షన్ సెలెక్షన్ తీసాం అనుకోండి ఈ

play09:02

వితౌట్ హావ్ సెట్టింగ్ ట్రిగ్గరింగ్

play09:04

ఈవెంట్ సో లూప్ కంటిన్యూస్ గా అయిపోద్ది

play09:07

అన్నమాట ఈ సెలెక్షన్ లిస్ట్ మిస్ అయినట్టే

play09:09

వితౌట్ సెన్సిటివ్ లిస్ట్ సో అందువల్ల మనం

play09:11

ఎప్పుడైనా సెన్సిటివిటీ యూస్ చేసినప్పుడు

play09:14

అదే మనం మాక్సిమం ఈ సెన్సిటివిటీ లిస్ట్

play09:16

అనేది యూస్ చేస్తాం సో అందువల్ల ఇవన్నీ

play09:18

రాసుకునే బదులు ఓన్లీ ఒక స్టార్

play09:20

పెట్టుకుంటే మనకి ఈ అవుట్పుట్ అనేది ఈజీగా

play09:23

ఉంటది

play09:25

థాంక్యూ

Rate This

5.0 / 5 (0 votes)

相关标签
ProgrammingAssignmentsContinuousProceduralCodingExamplesSin FunctionsControl StructuresLoopsEvents
您是否需要英文摘要?