I2C on Arduino to a Maxin 6651 Fan Controller

I am trying to interface an Arduino Duemilanove with a max6651 chip.
I am unsure if I am communicating with it properly and I am attempting to change the Ktach value to control the speed of the fan; however, the chip does not change the fan’s RPM. When I ask the 6651 over I2C for the tach value it does send back a number; however, this number does not change with the speed of the fan but rather with the Ktach. I would really appreciate it if someone could take a look at the data-sheet and my code and see what the problem is. I’m trying to use the closed-loop mode of operation with a 12volt fan.

#include <Wire.h>
byte KtachCommand=00000000;
byte ConfigCommand=00000010;
byte ConfigData= 00101000;
byte GPIODEFCommand=00000100;
byte DACCommand=00000110;
byte AlarmEnableCommand=00001000;
byte AlarmCommand=00001010;
byte Tach0Command=00001100;
byte Tach1Command=00001110;
byte Tach2Command=00010000;
byte Tach3Command=00010010;
byte GPIOSTATCommand=00010100;
byte COUNTCommand=00010110;
byte COUNTData=00000011;
int RPM;
byte Ktach=100;
int FanControllerAddress=72; 
int Tach0RPM;
int Tach1RPM;
int Tach2RPM;
int Tach3RPM;
byte TachInput;
int counter;

void setup(){
  Wire.begin(); // join i2c bus (address optional for master)
  Wire.beginTransmission(FanControllerAddress); // transmit to device
  Wire.send(ConfigCommand);   // transmits command 
  Wire.send(ConfigData);     // transmits data
  Wire.endTransmission();    // stop transmitting
  Wire.beginTransmission(FanControllerAddress); // transmit to device 

void loop(){
  if (counter==0){
  if (counter==20){

void KtachUpdate(){
      byte input=Serial.read();
      if (input=='u')
      else if (input=='d')
      if (Ktach<64)
      if (Ktach>250)
void UpdateFans(){
  if (Wire.available()>0){
  if (TachInput>0){
void ScreenUpdate(){
  Serial.print("RPM= ");
  Serial.print("Ktach= " );
 /Serial.print("Tach0 RPM = ");
  Serial.println(" "); 

The Data-sheets are here: http://datasheets.maxim-ic.com/en/ds/MAX6650-MAX6651.pdf http://www.maxim-ic.com/quick_view2.cfm/qv_pk/2296

Wire.send(Tach0Command); Wire.requestFrom(FanControllerAddress,1);

You need a Wire.endTransmission before the Wire.requestFrom.

Thanks I tried it and now it works great. Thank you for your help.