Program analysis , Electrical Engineering

Assignment Help:

Program Analysis

We have to find the greater of two given  number. We  can store the given  numbers  in two  different  registers ( suppose register A and B). Then we will compare the  contents  of  register B with  the contents of accumulator A. If the contents A are greater than B  Both  CY and Z  flag is reset.  If  the contents of A are equal  to B, Z  flag is  set and CY  flag is  reset. Here we assume for simplicity  of the  program that the  given  numbers are not  equal   then only carry flag can decide that which  number is greater. F carry flag  is set  the content of accumulator  A are less  than the contents  of B otherwise  the contents  of B  are greater  than the contents  of accumulator A.

Flow chart   : it is better  to draw  the flow  chart before  writing the program.


Related Discussions:- Program analysis

Microprocessor, Write a program to count how many from your data set called...

Write a program to count how many from your data set called MYDATA, which is a set of signed single-byte numbers, has positive value and are odd numbers. Save the result in POSOD

Characteristics of transformer, Q. Characteristics of Transformer? The ...

Q. Characteristics of Transformer? The characteristics of most interest to power engineers are voltage regulation and ef?ciency. The voltage regulation of a transformer is a me

Calculate rotor copper losses, A 20 h.p. , 3 phase, 400 volt, 60 hertz, 4 p...

A 20 h.p. , 3 phase, 400 volt, 60 hertz, 4 pole induction motor delivers full load at 5% slip. The mechanical rotational losses are 400W. Calculate (a) The electromagnetic torqu

Explain explanatory notes on a/d conversion, Explain explanatory notes on A...

Explain explanatory notes on A/D conversion. The digital inventory is working a revolution into the field of microcontrollers, technology and microprocessors are used more effi

Explain the types of power plants, Explain in detail the various energy res...

Explain in detail the various energy resources and their availability. Explain the following: (a) Types of power plants (b) Selection of power Plants

Dc machine closed-loop dynamics, i) Calculate the eigenvalues of a 100 hp,...

i) Calculate the eigenvalues of a 100 hp, 1150 rpm dc machine at rated flux with no extra load inertia. Use the "hot" value of the armature resistance. Calculate estimates of t

What do you mean by retention of risk, Q. What do you mean by Retention of ...

Q. What do you mean by Retention of Risk? Retention of Risk: In case of this method, the organization voluntarily accepts the risk since either the risk is insignificant or its

Scr, What is finger voltage in a scr?

What is finger voltage in a scr?

Calculate the resistance of a 2 km length of aluminium, Calculate the resis...

Calculate the resistance of a 2 km length of aluminium overhead power cable if the cross-sectional area of the cable is 100 mm 2 . Take the resistivity of aluminium to be 0.03x10 -

Find the expressions for the inductor current, Consider the RL circuit of F...

Consider the RL circuit of Figure with R = 2, L = 5H, and v(t) = V = 20 V (a dc voltage source). Find the expressions for the inductor current i L (t) and the inductor voltage v L

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd