The WHO_AM_I is 0x68 of course, unless you have an other chip. Sometimes a similar chip is put on a module, an other genuine chip or a counterfeit or something else.
Could you try again with minimal code ?
Code not tested.
// WHO_AM_I is 0x68
#include <Wire.h>
void setup()
{
Serial.begin(9600);
Serial.println( "The sketch has started");
Wire.begin();
}
void loop()
{
Wire.beginTransmission( 0x68);
Wire.write( 0x75);
Wire.endTransmission();
int n = Wire.requestFrom( 0x68, 1);
if( n == 1)
{
int data = Wire.read();
Serial.print( "0x");
Serial.println( data, HEX);
}
else
{
Serial.println( "Sensor not found");
}
delay( 1000);
}
[UPDATE] I have tested this code
void some_function( uint8_t *data)
{
int size = sizeof(*data);
Serial.println( size);
}
and it does indeed return 1. However, everyone else uses a integer for the number of bytes to read.