Hi,
Have a re-read of the datasheet specs, page 4: "Zero Current Output Voltage"
This is the Allegro Micro datasheet.
Without any further information I would guess your supply voltage is 5V? Or with the motor on do you get a constant 2.5V at the sensor output pin?
"The value never changes even when I connect the sensor or switch it on/off." - Could you elaborate a little, please? Switch what on or off (the sensor has no "enable" pin...)? Connect the sensor to what? Are you reading the 2.5V on the ADC output/input or on the ACS output pin?
Have you seen Application 4 on page 12? Maybe it can help.
Personal interest in this subject (I want to learn how to connect an ADC to a Pi-style device sooner or later) - Where did you get the code from for the project, if it isn't private/your own work, thanks?