If I connect an MCU, for example a Cortex M4, what is the minimum memory size needed?

It depends on the use case. Currently the minimum requirement for the least complex use case ”power bins” is  200 kB flash, 60 kB RAM.