Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Information about a machine serving in the X factory is as follows; a. The number of machines working in the factory is only 2. b.

Information about a machine serving in the X factory is as follows;

a. The number of machines working in the factory is only 2.

b. The band capacity is 10 for waiting materials in the production line.

c. Each machine produces only 1 piece at a time.

D. Machines produce parts if material is available. After each piece is produced, it is checked whether there is any material waiting in the production line. If there are parts, production is made, otherwise the machine switches itself to stand-by.

to. When new material is added to the production line, the status of the machines is checked. If the machine is in stand-by mode, it is started and the material is directly put into production. In machine production, the production line is controlled. If there is space, the material is placed on the production line, otherwise the material is not placed on the production line.

f. 2 machines use the 10 chamber production line jointly. In other words, there are 1 production line and 2 machines.

Code the problem mentioned above in c language using MUTEX without any deadlocks. Draw the flowchart of your code

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions