1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Nutka1998 [239]
3 years ago
10

Consider the following program that monitors two sensors. Here sensor1 and sensor2 denote

Computers and Technology
1 answer:
dusya [7]3 years ago
5 0

Answer:

Check the explanation

Explanation:

a)

It is a technical impossible for the update in the value of sensor1 in ISR while the main function is still evaluating whether sensor1 is with a fault or not at the point of execution in the critical section block because in this block no other instructions are not executed until the completion of instructions in the critical section.

Also semaphores are used to execute instructions when they are get lock to execute. if we write the code in operating system in such a way that at any instant of time shared resources cannot be executed in parallel, then only it is not possible to update ISR value of sensor1 while main function checking for sensor1 faultiness.

-> It is possible that  to update ISR value of sensor1 while main function checking for sensor1 faultiness if operating system and compilers are coded for parallel execution even though shared resources.

for example:

int i=5;

main()

if (i==5)

{print "i is %d",i}

other()

i=7;

//if above program executes parallel boh main() and other() functions are parallel executed

then at first clock cycle in main method i=5 so goes to next instruction print.

but in the first clock cycle also in other method i value changes to 7.

so in the next clock cycle in main method result as " i is 7.

b)

if there is an occurrence of error related to only for faulty value of sensor 1 or sensor 2 then only it is possible for this code would report "Sensor1 faulty" or "Sensor2 faulty" when there is no error related to other issues.

Like power interrupt etc.

if a spurious error can cause not only sensor1 or sensor2 to be a faulty value but also interrupting whole program or suspending entire program etc may possible for this code would not report  "Sensor1 faulty" or "Sensor2 faulty".

c)

if we Assume the interrupt source for ISR() is timer-driven , then there are conditions could cause this code to never check whether sensors are faulty or not.

timer driven means set a clock for its execution how can we set the clock. if we set clock for ISR() method to stop the entire program or repeated continuously at setting up interrupts and enabling interrupts.

these two conditions 1)set clock to stop the program would not enter into checking sensors faultiness.

2)set the clock to spare entire time to execute  at setting up interrupts and enabling interrupts. repeated continuously.

It means never run ":while(1) {} " block instructions for checking faultiness of the sensors.

You might be interested in
When you add encryption to a powerpoint presentation what does it do
abruzzese [7]

Answer: your document will be inaccessible

5 0
2 years ago
Which phrase suggests feedback?
butalik [34]

Answer:

They also gave suggestions on some modules and said they would like to work with his team in the future.

Explanation:

This statement suggests feedback because, here the client gives Richard and his team some suggestions on what they can do with the modules. It implies that the client must have tested the software application and observed its functionality.

7 0
3 years ago
Why should information technology NOT be taught in school?​
tatiyna

Explanation:

Technology should not be used to teach in school as it can lead to distractions. With kids wanting to explore other sights, cheating, and communicating with others. Also, it can be expensive to purchase the technology for everyone as it can be a major investment with hundreds or thousands going into it. Technology also requires a lot of training by having to adapt lessons compatible with the systems and making sure the software is secure.

5 0
3 years ago
What is the main idea of this article? Please someone help me. I will give brainliest answer
mart [117]
The main idea of this article is that theme parks are conducting scientific research that is benefiting the community. Hope this helps!
8 0
3 years ago
In python:
egoroff_w [7]

Python can be used to implement central of tendencies such as mean, median and mode using the statistic module

The program in Python, where comments are used to explain each line is as follows:

#This imports the statistics module

import statistics

#This defines the function that calculates the mode

def calcMode(myList):

   #This prints the mode

   print(statistics.multimode(myList))

#This defines the function that calculates the median

def calcMedian(myList):

   #This prints the median

   print(statistics.median(myList))

#The main method begins here

#This initializes the list

myList = []

#The following iteration gets input for the list

for i in range(10):

   myList.append(int(input()))

#This calls the calcMode method

calcMode(myList)

#This calls the calcMedian method

calcMedian(myList)

Read more about similar programs at:

brainly.com/question/25026386

8 0
3 years ago
Other questions:
  • There are many differenttypes of models, but an individual DSS can consist of onlyone.
    15·1 answer
  • What type of device is built into a tablet computer and can send data over radio waves to another device such as a laser printer
    10·1 answer
  • For which punctuation symbol will you use the ring finger of your right hand?
    9·1 answer
  • Which style of leadership would be most helpful to Charles in the following situation? Charles has just started an internship at
    15·1 answer
  • Suppose the length of each packet is L bits. Also, assume the path from a server to a client includes N links each of rate R (i.
    8·1 answer
  • Chunking is a good strategy for completing large assignments because it makes the work
    7·2 answers
  • How many bytes are there in 256 Kbytes?
    6·1 answer
  • Fill in the blank with the correct response.
    5·2 answers
  • Using the Insert tab, you can convert text into a table and a table into text.
    15·1 answer
  • Which statement best describes what happens when a computer starts?
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!