Exemple #1
0
        public DataCollectorRadarSD()
        {
            Debug.Print("Initializing LCD ....");
            lcd = new Samraksh.SPOT.Hardware.EmoteDotNow.EmoteLCD();
            lcd.Initialize();
            lcd.Clear();


            Debug.Print("Initializing ADC .....");

            channelIBuffer = new BufferStorage(bufferSize);
            channelQBuffer = new BufferStorage(bufferSize);

            adcCallbackPtr = AdcCallbackFn;
            Samraksh.SPOT.Hardware.EmoteDotNow.AnalogInput.InitializeADC();
            Samraksh.SPOT.Hardware.EmoteDotNow.AnalogInput.InitChannel(Samraksh.SPOT.Hardware.EmoteDotNow.ADCChannel.ADC_Channel1);
            Samraksh.SPOT.Hardware.EmoteDotNow.AnalogInput.InitChannel(Samraksh.SPOT.Hardware.EmoteDotNow.ADCChannel.ADC_Channel2);
            if (!Samraksh.SPOT.Hardware.EmoteDotNow.AnalogInput.ConfigureContinuousModeDualChannel(sampleBuffer1, sampleBuffer2, bufferSize, sampleTime, AdcCallbackFn))
            {
                throw new InvalidOperationException("ADC Initialization failed \n");
            }

            Debug.Print("Initializing NOR ...");
            lcd.Write(Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_E, Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_R, Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_A, Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_S);
            storage = new NorStore();

            Debug.Print("Initializing SD ...");
            removableStorage = new SDStore();
        }
Exemple #2
0
        public DataCollectorMicrophoneSD()
        {
            Debug.Print("Initializing LCD ....");

            lcd = new Samraksh.SPOT.Hardware.EmoteDotNow.EmoteLCD();

            lcd.Initialize();

            lcd.Clear();

            Debug.Print("Initializing Serial ....");

            serialPort           = new SerialPort("COM1");
            serialPort.BaudRate  = 115200;
            serialPort.Parity    = System.IO.Ports.Parity.None;
            serialPort.StopBits  = StopBits.One;
            serialPort.DataBits  = 8;
            serialPort.Handshake = Handshake.None;

            Debug.Print("Initializing ADC .....");

            stopExperiment.OnInterrupt += stopExperiment_OnInterrupt;

            adcCallbackPtr = AdcCallbackFn;
            Samraksh.SPOT.Hardware.EmoteDotNow.AnalogInput.InitializeADC();
            Samraksh.SPOT.Hardware.EmoteDotNow.AnalogInput.InitChannel(Samraksh.SPOT.Hardware.EmoteDotNow.ADCChannel.ADC_Channel1);
            Samraksh.SPOT.Hardware.EmoteDotNow.AnalogInput.ConfigureContinuousMode(sampleBuffer, Samraksh.SPOT.Hardware.EmoteDotNow.ADCChannel.ADC_Channel1, bufferSize, sampleTime, AdcCallbackFn);



            buffer = new BufferStorage(bufferSize);
            //transferBuffer = new BufferStorage(bufferSize);

            Debug.Print("Initializing NOR ...");
            lcd.Write(Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_E, Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_R, Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_A, Samraksh.SPOT.Hardware.EmoteDotNow.LCD.CHAR_S);
            storage = new NorStore();



            Debug.Print("Initializing SD ...");
            removableStorage = new SDStore();
        }