annotate modules/bluespec/Pygar/core/audioPipeTypes.bsv @ 50:2b18894f75e2 pygar svn.51

[svn r51] fixed processor- it works
author punk
date Wed, 05 May 2010 15:19:32 -0400
parents 7e1510b47336
children
rev   line source
punk@16 1
punk@16 2 // The MIT License
punk@16 3
punk@16 4 // Copyright (c) 2009 Massachusetts Institute of Technology
punk@16 5
punk@16 6 // Permission is hereby granted, free of charge, to any person obtaining a copy
punk@16 7 // of this software and associated documentation files (the "Software"), to deal
punk@16 8 // in the Software without restriction, including without limitation the rights
punk@16 9 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
punk@16 10 // copies of the Software, and to permit persons to whom the Software is
punk@16 11 // furnished to do so, subject to the following conditions:
punk@16 12
punk@16 13 // The above copyright notice and this permission notice shall be included in
punk@16 14 // all copies or substantial portions of the Software.
punk@16 15
punk@16 16 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
punk@16 17 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
punk@16 18 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
punk@16 19 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
punk@16 20 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
punk@16 21 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
punk@16 22 // THE SOFTWARE.
punk@16 23
punk@16 24 // Author: Ker
punk@16 25 // min Fleming kfleming@mit.edu
punk@16 26
punk@16 27 import Connectable::*;
punk@16 28 import GetPut::*;
punk@16 29 import ClientServer::*;
punk@16 30
punk@16 31 typedef Int#(16) Sample;
punk@16 32
punk@16 33 typedef enum {
punk@16 34 EndOfFile = 0,
punk@16 35 Data = 1
punk@16 36 } AudioProcessorControl deriving (Bits,Eq);
punk@16 37
punk@16 38
punk@16 39 typedef struct {
punk@16 40 Sample left;
punk@16 41 Sample right;
punk@16 42 } StereoSample deriving (Bits,Eq);
punk@16 43
punk@16 44 typedef union tagged{
punk@16 45 Sample Sample;
punk@16 46 void EndOfFile;
punk@16 47 } AudioProcessorUnit deriving (Bits,Eq);
punk@16 48
punk@50 49 interface AudioPlugIn;
punk@50 50 interface Put#(AudioProcessorUnit) sampleInput;
punk@50 51 interface Get#(AudioProcessorUnit) sampleOutput;
punk@50 52 endinterface