HoneyWell ABP2 Sensor is not responding

Hi everyone,
I am trying to work with a 20Bars Gauge ABP2 pressure sensor from honey well using a wiring exactly similar to the diagram found in the documentation :

ABP2 Series

When I use an oscilloscope at both the SCL or the SDA, the master sends the commands, but nothing comes out of the sensor. The address from the sensor I bought is 0x28, I have checked! I have changed both sensor and Arduino Zero, but nothing happened... I have verified the wiring multiple time, but nothing seems wrong.

Here is my code, please tell me if you see something wrong :

#include <Arduino.h>
#include <Wire.h>


byte id = 0x28;          // I2C address
uint8_t data[7];            // Sensor output
uint8_t cmd[3] = {0xAA, 0x00, 0x00};

double press_counts = 0;
double temp_counts = 0;
double pressure = 0;
double temperature = 0;

double outputmax = 15099494;
double outputmin = 1677722;
double pmax = 20;
double pmin = 0;

double percentage = 0;

char printBuffer[200];

void setup() {
  Serial.begin(115200);

  
  // Allow time for USB Serial but don't block forever
  unsigned long start = millis();
  while (!Serial && millis() - start < 2000);
  Wire.setClock(200000);
  Wire.begin();

  Serial.println(
    "\nStatus | Raw Data | Counts | %FS | Pressure | Temp"
  );
}

void loop() {

  // Send command
  Wire.beginTransmission(id);
  Wire.write(cmd, 3);
  int tmp = 10;
  tmp = Wire.endTransmission(true);
  
  delay(5);

  // Request 7 bytes
  Wire.requestFrom(id, (uint8_t)7);

  int i = 0;
  while (Wire.available() && i < 7) {
    data[i++] = Wire.read();
    Serial.println(Wire.available())
  }

  // Combine bytes (24‑bit values)
  Serial.println(data[0]);
  press_counts = (double)(
      (uint32_t)data[3] +
      (uint32_t)data[2] * 256 +
      (uint32_t)data[1] * 65536
  );

  temp_counts = (double)(
      (uint32_t)data[6] +
      (uint32_t)data[5] * 256 +
      (uint32_t)data[4] * 65536
  );

  // Calculations
  temperature = (temp_counts * 200.0 / 16777215.0) - 50.0;
  percentage  = (press_counts / 16777215.0) * 100.0;

  pressure = ((press_counts - outputmin) * (pmax - pmin)) /
             (outputmax - outputmin) + pmin;

  // Use snprintf (works on SAMD21)
  snprintf(printBuffer, sizeof(printBuffer),
    "%02X | %02X %02X %02X | %.1f | %.3f | %.3f | %.3f %01X \n",
    data[0],
    data[1], data[2], data[3],
    press_counts,
    percentage,
    pressure,
    temperature,
    tmp
  );

  Serial.print(printBuffer);

  delay(150);
}

DO you have a link to the datasheet of the sensor?

OK found - https://docs.rs-online.com/ba73/A700000015374509.pdf

#include <Arduino.h>
#include <Wire.h>


byte id = 0x28;          // I2C address


void setup() 
{
  Serial.begin(115200);

  // Allow time for USB Serial but don't block forever
  unsigned long start = millis();
  while (!Serial && millis() - start < 2000);
  Wire.setClock(200000);
  Wire.begin();

  // Send command
  Wire.beginTransmission(id);
  int status = Wire.endTransmission(true);
  Serial.print("status: ");
  Serial.println(status);
}

void loop() {

}

give this a try

What I don't see is any clear, well lit, in focus pictures of your wiring. Providing those will prevent playing 20 questions of "have you done this, have you done that".

I kind of did a similar thing in my code using the tmp variable. It yields a 2 everytime! :(

Return value 2 means a not ACKnowledge of the address.

Run an I2C scanner to see what addresses are found when connecting the sensor.
e.g. from Arduino | How to Scan and Detect I2C Addresses | Adafruit Learning System

// SPDX-FileCopyrightText: 2023 Carter Nelson for Adafruit Industries
//
// SPDX-License-Identifier: MIT
// --------------------------------------
// i2c_scanner
//
// Modified from https://playground.arduino.cc/Main/I2cScanner/
// --------------------------------------

#include <Wire.h>

// Set I2C bus to use: Wire, Wire1, etc.
#define WIRE Wire

void setup() {
  WIRE.begin();

  Serial.begin(9600);
  while (!Serial)
     delay(10);
  Serial.println("\nI2C Scanner");
}


void loop() {
  byte error, address;
  int nDevices;

  Serial.println("Scanning...");

  nDevices = 0;
  for(address = 1; address < 127; address++ )
  {
    // The i2c_scanner uses the return value of
    // the Write.endTransmisstion to see if
    // a device did acknowledge to the address.
    WIRE.beginTransmission(address);
    error = WIRE.endTransmission();

    if (error == 0)
    {
      Serial.print("I2C device found at address 0x");
      if (address<16)
        Serial.print("0");
      Serial.print(address,HEX);
      Serial.println("  !");

      nDevices++;
    }
    else if (error==4)
    {
      Serial.print("Unknown error at address 0x");
      if (address<16)
        Serial.print("0");
      Serial.println(address,HEX);
    }
  }
  if (nDevices == 0)
    Serial.println("No I2C devices found\n");
  else
    Serial.println("done\n");

  delay(5000);           // wait 5 seconds for next scan
}


Here is the wiring.

I have tried that before and it does return the right address, being 0x28!

Strange that if one only test 0x28 it fails on that address...
(time to think)

New info just dropped : I also have an ms5837-30ba.pdf sensor... It uses different code but the exact same circuit. And it works with my setup! So the error is definitely not wiring related.

Try photographing without the strong lighting, show where the wires go and add a sketch of your circuits

I noticed that in the scanner code the standard I2C clock freq is used but in your original code you set the freq to 200kHz.

Why not use the standard 100kHz

Have you tried commenting out the setClock() line from your sketch in post #1, going with the default?

  Wire.setClock(200000);

I vaguely remember, age is taking its toll, strange I2C speeds with the Zero. I think I only messed with 100K and 400K at the time though.

EDIT: @jim-p beat me to it.

Here are the two pictures. Thanks!


Turns out I tried every clock frequency 100000-200000 and 400000. The sensor is rated for that range...

What is the exact type number again?
something like ABP2DANT001BA2A3XX

ABP2DNXG020BG2A3XX (DIP Pins, No tube, 20bar gauge [disclaimer : not the issue, the pressure doesn't read at all], 0x28, Liquid environment [disclaimer : I have tried putting water on the hole, it does not change anything], 3.3V)

As @robtillaart mentioned:
Strange that if one only test 0x28 it fails on that address...

So in your original code if you first send the wrong address in setup()

  Wire.beginTransmission(0x20);
  tmp = Wire.endTransmission(true);

Does it work?

If I put the wrong address it does output 2, which, as mentionned before, means the sensor is not ACK. When I put the right one, we go back to status 0... Meaning it should work, but I see nothing :frowning:

the status byte returned by the sensor should be 00000010 (0x02) but I get an 0x00 instead, which reading the documentation, should tell us the sensor is not powered.