resolve the force parallel to the slope, and resolve for the pan and mass.
for the slope its T - component of gravity = 5a, for the mass and pan its 7g - T = 7a
use that to calculate acceleration, then you know that for A, using F=ma, 2g - F = 2a, since you know have A you can solve.