smcarrera memory V5

I took V4 and added the functionality again to generate your own memory
size