If you're looking for a technical job, the easier path would be to find a PM/Designer job at one of your target companies and try switching to a dev role within the company. When you apply as a junior developer, your previous work experience will not be considered relevant. You'll be competing with other junior developers (who also likely don't have any relevant work experience) and it's much harder to differentiate yourself. Whereas if you want to switch roles inside a company, people who are familiar with your skills are likely to take a bet on you (if you have a good track record).
On the other hand, the masters program will introduce you to a new network of people, and working towards a goal with a cohort is much more motivating than learning by yourself.
I agree with your suggestion with one caveat: having a Master's degree when switching to a dev role would be very beneficial. Both in terms of how it looks on paper and in terms of competency.
On the other hand, the masters program will introduce you to a new network of people, and working towards a goal with a cohort is much more motivating than learning by yourself.