Mercurial > pygar
comparison modules/bluespec/Pygar/core/AudioCoreSystem.h @ 13:6d461680c6d9 pygar svn.14
[svn r14] more stuff
author | punk |
---|---|
date | Tue, 27 Apr 2010 09:03:28 -0400 |
parents | |
children | 0cfbb1e2de22 |
comparison
equal
deleted
inserted
replaced
12:394aa40fd812 | 13:6d461680c6d9 |
---|---|
1 // | |
2 // INTEL CONFIDENTIAL | |
3 // Copyright (c) 2008 Intel Corp. Recipient is granted a non-sublicensable | |
4 // copyright license under Intel copyrights to copy and distribute this code | |
5 // internally only. This code is provided "AS IS" with no support and with no | |
6 // warranties of any kind, including warranties of MERCHANTABILITY, | |
7 // FITNESS FOR ANY PARTICULAR PURPOSE or INTELLECTUAL PROPERTY INFRINGEMENT. | |
8 // By making any use of this code, Recipient agrees that no other licenses | |
9 // to any Intel patents, trade secrets, copyrights or other intellectual | |
10 // property rights are granted herein, and no other licenses shall arise by | |
11 // estoppel, implication or by operation of law. Recipient accepts all risks | |
12 // of use. | |
13 // | |
14 | |
15 // possibly use include paths to hide existing modules? | |
16 | |
17 #ifndef __AUDIO_CORE_CONNECTED_APPLICATION__ | |
18 #define __AUDIO_CORE_CONNECTED_APPLICATION__ | |
19 | |
20 #include <stdio.h> | |
21 #include <pthread.h> | |
22 #include <semaphore.h> | |
23 | |
24 #include "asim/provides/virtual_platform.h" | |
25 | |
26 #include "asim/rrr/client_stub_AUDIOCORERRRSYSTEM.h" | |
27 | |
28 typedef enum { | |
29 EndOfFile = 0, | |
30 Data = 1 | |
31 } AudioProcessorControl; | |
32 | |
33 | |
34 typedef class CONNECTED_APPLICATION_CLASS* CONNECTED_APPLICATION; | |
35 class CONNECTED_APPLICATION_CLASS : public PLATFORMS_MODULE_CLASS | |
36 { | |
37 private: | |
38 AUDIOCORERRR_CLIENT_STUB clientStub; | |
39 static sem_t throttle; | |
40 static pthread_mutex_t lock; | |
41 static pthread_cond_t cond; | |
42 | |
43 public: | |
44 CONNECTED_APPLICATION_CLASS(VIRTUAL_PLATFORM vp); | |
45 ~CONNECTED_APPLICATION_CLASS(); | |
46 static void EndSimulation(); | |
47 static void UpdateSemaphore(); | |
48 | |
49 // init | |
50 void Init(); | |
51 | |
52 // main | |
53 void Main(); | |
54 }; | |
55 | |
56 #endif |