I've never tried to do this, so others may have a better solution.
Search for "camper mode". This should do what you want as long as you don't need to charge at the same time. I don't know if this works with the windows open.
If you do need to charge, you will need to use one of the third-party apps with this capability on your smartphone to activate it.