-
VC++ to achieve the relationship between producers and consumers! (OS)
VC++实现生产者与消费者关系!(操作系统OS)-VC++ to achieve the relationship between producers and consumers! (OS)
- 2022-03-03 04:39:04下载
- 积分:1
-
操作系统兔子吃草
#include "stdafx.h"
#include
#include
#include
/*信号量的定义,它是负责协调各个线程, 以保证它们能够正确、合理的使用公共资源。 用于控制进程间的同步与互斥*/
typedef HANDLE Semaphore;
Semaphore g_semBuffer,g_semGlass, g_mutex; //mutex 为互斥锁
// 利用 Windows 下的 API 函数(视窗操作系统应用程序接口)来定义 P、V 操作
#define P(S) WaitForSingleObject(S,INFINITE)
#define V(S) ReleaseSemaphore(S,1,NULL)
#define rate 1000
#define CONSUMER_NUM 4 // 消费者个数
#define PRODUCER_NUM 4 // 生产者个数
#define BUFFER_NUM 4 // 缓冲区个数
char *thing[4]={"glass1","glass2","glass3","glass4"};
//公共的队列缓冲区
struct Buffer
{
int product[BUFFER_NUM];
int front,rear;
}g_buf;
//兔子线程
DWORD WINAPI Rabbit(LPVOID para)
{
int i =*(int*)para; //第 i 只小白兔&
- 2022-05-23 06:18:02下载
- 积分:1
-
操作系统程序,计算县城个数,进程名称,进程的管理
操作系统程序,计算县城个数,进程名称,进程的管理-Operating procedures, the county calculated the number, the process name, process management
- 2022-03-26 19:01:24下载
- 积分:1
-
真正的
实模式操作系统的设计与实现-Real-mode operating system design and implementation. . . . . . . . . . . . . . . . . . .
- 2022-01-22 05:20:17下载
- 积分:1
-
uC/OS
uC/OS-II在X86下的全部源代码,可进行基于PC机的嵌入式uC/OS-II开发,还可以嵌入ucGUI和uCLAN。-uC/OS-II in the X86 under all source code, can be PC-based embedded uC/OS-II development, also can be embedded ucGUI and uCLAN.
- 2022-02-20 06:52:08下载
- 积分:1
-
网络实验 LWIP无操作系统移植
本实验将实现如下功能:本实验利用STM32F10开发板上的DM9000网络芯片实现联网功能,网络协议栈使用的LWIP,版本为1.4.1。默认开启了DHCP,将开发板连接到路由器上以后就会自动获取IP地址,当DHCP失败以后就会使用默认IP地址,默认IP地址为:192.168.1.30。DHCP成功后就可以在电脑上通过ping命令来测试LWIP移植是否成功。
- 2022-07-11 03:17:23下载
- 积分:1
-
这是帮别人做的程序,模拟操作系统中进程控制块(包括多道系统中动态优先级进程调度和动态内存分配),用tc2.0做的,带有图形界面和简陋的控制台。现在把源代码贴出来
这是帮别人做的程序,模拟操作系统中进程控制块(包括多道系统中动态优先级进程调度和动态内存分配),用tc2.0做的,带有图形界面和简陋的控制台。现在把源代码贴出来。-This to help procedure that others make, simulation operating system process control piece (whether including many dishes of system dynamic PRI process dispatcher and dynamic memory assign), use tc2. 0 ones that make, there are figure interfaces and simple and crude control cabinets. Stick the source code out now
- 2022-03-24 11:11:29下载
- 积分:1
-
本程序为操作系统处理机优先数调度算法,附带源码和可运行的程序,VC下编译通过,基本用C的函数写的。...
本程序为操作系统处理机优先数调度算法,附带源码和可运行的程序,VC下编译通过,基本用C的函数写的。-This procedure has priority to count dispatcher s algorithm , the procedure that attach the source code and can be operated for the operating system processor , compile passing under VC, wrote with the function of C basically.
- 2023-05-19 02:35:03下载
- 积分:1
-
银行家算法,还不错。有好的请与我联系!
银行家算法,还不错。有好的请与我联系!-bankers algorithm, is not bad. Good please contact me!
- 2022-02-16 03:06:59下载
- 积分:1
-
Bochs this virtual machine
Bochs这个虚拟机的源代码。学习虚拟机的编写和操作系统的编写有帮助。-Bochs this virtual machine
- 2023-03-10 11:35:04下载
- 积分:1