Welcome.The P0332 is the knock sensor under the upper intake manifold. There is a 2 wire connector at the rear drivers side of the intake that go to the knock sensors. These get water down in the hole that they are in and this damages the sensors. I suggest you test the resistance of each of these wires, light blue and dark blue to ground. Spec is 93K ohm to 107K ohm, and they usually sit at 99,9K ohm. Replace the one that is out of spec.
As for the HVAC, that will not set the check engine light at all, it is likely a bad or failing temp door actuator. Take the HVAC/ECAS fuse out for 10 seconds, then put it back in. Start the engine and wait 5 mins for the system to fully recalibrate. Do this 3 times and this should clean the feedback circuit off in the actuator and stop that code.