Read in 10-bits Magnetic Encoder AEAT-6010-A06 into Arduino Uno

Dear members,

for a school project I have to implement a 10-bits magnetic encoder on a plant.
To explain the plant, I will give you a similar example:
http://www.youtube.com/watch?feature=player_embedded&v=ttsKhNZZTHU
I have to inplement PID controle with LabVIEW and an Arduino Uno..

Instead of the potentiometer to check the angle of the bar, and use PID depending on the angle, I now have to use a 10-bits magnetic encoder.

The following one: AEAT-6010-A06 10-bits Magnetic Encoder

Link tot the datasheet: http://www.avagotech.com/docs/AV02-0188EN

The AEAT-6010 magnetic angular based rotary detector uses a serial data stream and clock to be able to read out the absolute position in digital form.
The CLOCK and DATA signals are transmitted according RS-422 standards.

About the code:

As you can see in the characteristics in datasheet I have to "produce" a 10 times "HIGH" and "LOW" signal for the CLOCK.
I also have to watch the delay times which are given in the datasheet and making the Chip select and CLK high as given in the characteristics.

My pin connection is the following one:

1: VDD (5V supply voltage): 5V power supply Arduino
2: CSn (Chip select): Digital output 4 Arduino
3: VSS (GND): GND Arduino
4: CLK (Serial clock-input): Digital output 7 Arduino
5: DO (Serial Data-Output): Digital output 8 Arduino

I have allready made the following code, but on the Serial Monitor I only get a "1" out..

Does anyone has some experience with reading this kind of sensor into the Arduino?
I would appreciate your help a lot!

//*************************************************************************************************************
//
//  Firmware to control the SSI Interface for the AEAT-6010 magnetic encoder
//
//
//  2013-04-12  HB
//
//
//
//*************************************************************************************************************

// Definitions for the AEAT-6010
int SSI_CLK = 7;
int  DataIN = 8;
int  NCS = 4;
int Test = 13;

// Definitions for variables
unsigned int reading;

// program starts here
// **************************

void setup() {                
  
  Serial.begin(9600);
  
  // initialize the digital pin as an output.
  pinMode(NCS, OUTPUT);   // Chip select
  pinMode(SSI_CLK, OUTPUT);   // Serial clock
  pinMode(DataIN, INPUT);   // Serial data IN/OUT
  pinMode(Test, OUTPUT);   

  digitalWrite(SSI_CLK, HIGH);  
  digitalWrite(Test, LOW);   
}

//***********************************************************************
// Main program loop
//***********************************************************************
void loop() {

unsigned int reading;
  
  ReadSSI();
  Serial.println(reading,DEC);
  delay(10);
  
}

 
//***********************************************************************
// Main Loop ends here
// Start of subroutines
//***********************************************************************

void ReadSSI(void)
{
int i;
char Res = 10;
unsigned int mask;

	reading = 0;
        mask = 0x0200;
	digitalWrite(NCS, LOW);
	delayMicroseconds(1);
	digitalWrite(SSI_CLK, LOW);

	for(i=(Res-1);i>0;i--)
	{
  	digitalWrite(SSI_CLK, HIGH);
  	delayMicroseconds(1);
	if (digitalRead(DataIN)) reading |= mask;	
	digitalWrite(SSI_CLK, LOW);
	mask = mask >> 1;

	if (i == 1) 
          {
          digitalWrite(SSI_CLK, HIGH);
 	  if (digitalRead(DataIN)) reading |= mask;	
          }
	}

	digitalWrite(NCS, HIGH);
}

/////////////////////////////////

Best regards,

Robin