I am getting a weird pin out error with the Cobra II and its extender board. The SPI socket on the Cobra II board is 6, I am using pin number 6 on socket 6 as a regular Digital Output Pin for an analog to digital(ADC) converter. I am also using the serial interface for another digital to analog converter(DAC) however the ChipSelect for this DAC is pin 6 on socket 7 on the extender board.
The problem is that when the SPI socket is instantiated pin 6 on socket 6 becomes high and outputs 3.3 volts even though the output is supposed to be set to 0V.
The following is the initialization code
//Digital output ADC initialization private GTI.DigitalOutput _ADCpin; private GT.Socket _ADCsocket = null; _ADCsocket = GT.Socket.GetSocket(6, true, module, null); _ADCpin = new GTI.DigitalOutput(_ADCsocket, pin.Six, false, module); _ADCpin.Write(false); //Serial DAC initialization private GTI.DigitalOutput _DACpin; private GT.Socket _DACsocket = null; _DACsocket = GT.Socket.GetSocket(7, true, module2, null); _DACpin = new GTI.DigitalOutput(_DACsocket, pin.Six, false, module2); GT.Socket _spiSocket; = GT.Socket.GetSocket(6, true, this, null) GTI.SPI.Configuration spiConfig = null; spiConfig = new GTI.SPI.Configuration(false, ChipSelectSetupTime, ChipSelectHoldTime, false, true, ClockRateKHz); GTI.SPI spiControl = new GTI.SPI(_spiSocket, spiConfig, GTI.SPI.Sharing.Shared, _DACsocket, _DACpin, this); }
Right until the last line of code the output for pin 6 on Socket 6 is low however when the last line returns the output becomes high, would anyone know the reason for this?