Problem with linking sensor

Hi everyone! I am new to SimpleFOC, so please excuse me, if the problem, i am about to talk about, has really obvious solution, but i am feeling out of options. I am trying to make a closed-loop position-controlled bldc servo actuator. I am using B-G431-ESC1 board and AS5600 magnetic sensor in i2c mode. I have pieced together prototype code from the examples. Sensor works fine and gives out valid data, when i am trying to access it from the sensor instance. But when i link it to motor and try to initFOC, motor moves a bit back and forth and prints out “Failed to notice movement”. After that, if i try to access shaftAngle from the motor instance, i am always getting 0, even when sensor itself returns valid data