Could you please enable the Aref block too before using the SAR ADC.
status_aref = Cy_SysAnalog_Init(&Cy_SysAnalog_Fast_Local);
/* Turn on the hardware block. */
I have attached one sample code I have generated too which was tested to be working at my end.
test.zip 59.0 MB
Thank you Vasanth,
I was trying to get AREF enabled but it was asking me for an OPAMP reference I didn't realize the reference can be local.
and enabling the hardware block was missing