annotate modules/bluespec/Pygar/core/AudioCoreSystem.h @ 76:8bd0e4d37ad2 pygar svn.77 tip

[svn r77] I don't know why my last change didn't go through grumble grumble....
author rlm
date Wed, 12 May 2010 08:58:23 -0400
parents a15cc186e07d
children
rev   line source
punk@13 1 //
punk@13 2 // INTEL CONFIDENTIAL
punk@13 3 // Copyright (c) 2008 Intel Corp. Recipient is granted a non-sublicensable
punk@13 4 // copyright license under Intel copyrights to copy and distribute this code
punk@13 5 // internally only. This code is provided "AS IS" with no support and with no
punk@13 6 // warranties of any kind, including warranties of MERCHANTABILITY,
punk@13 7 // FITNESS FOR ANY PARTICULAR PURPOSE or INTELLECTUAL PROPERTY INFRINGEMENT.
punk@13 8 // By making any use of this code, Recipient agrees that no other licenses
punk@13 9 // to any Intel patents, trade secrets, copyrights or other intellectual
punk@13 10 // property rights are granted herein, and no other licenses shall arise by
punk@13 11 // estoppel, implication or by operation of law. Recipient accepts all risks
punk@13 12 // of use.
punk@13 13 //
punk@13 14
punk@13 15 // possibly use include paths to hide existing modules?
punk@13 16
punk@13 17 #ifndef __AUDIO_CORE_CONNECTED_APPLICATION__
punk@13 18 #define __AUDIO_CORE_CONNECTED_APPLICATION__
punk@13 19
punk@13 20 #include <stdio.h>
punk@13 21 #include <pthread.h>
punk@13 22 #include <semaphore.h>
punk@13 23
punk@13 24 #include "asim/provides/virtual_platform.h"
punk@13 25
punk@22 26 #include "asim/rrr/client_stub_AUDIOCORERRR.h"
punk@13 27
punk@13 28 typedef enum {
punk@13 29 EndOfFile = 0,
punk@13 30 Data = 1
punk@13 31 } AudioProcessorControl;
punk@13 32
punk@13 33
punk@13 34 typedef class CONNECTED_APPLICATION_CLASS* CONNECTED_APPLICATION;
punk@13 35 class CONNECTED_APPLICATION_CLASS : public PLATFORMS_MODULE_CLASS
punk@13 36 {
punk@13 37 private:
punk@13 38 AUDIOCORERRR_CLIENT_STUB clientStub;
punk@13 39 static sem_t throttle;
punk@13 40 static pthread_mutex_t lock;
punk@13 41 static pthread_cond_t cond;
punk@75 42 static bool areAllFilesComplete(int numVoices, bool isFini[]);
punk@75 43
punk@13 44 public:
punk@13 45 CONNECTED_APPLICATION_CLASS(VIRTUAL_PLATFORM vp);
punk@13 46 ~CONNECTED_APPLICATION_CLASS();
punk@13 47 static void EndSimulation();
punk@13 48 static void UpdateSemaphore();
punk@13 49
punk@13 50 // init
punk@13 51 void Init();
punk@13 52
punk@13 53 // main
punk@13 54 void Main();
punk@13 55 };
punk@13 56
punk@13 57 #endif