You might not have waited long enough between shutting off the generator and plugging into the campground power. Then you would need to wait about 6 minutes before turning the thermostats to 'cool'.
You can turn on the fans right away when you plug in, they have no problem restarting. But the compressor needs to be off for about 3 minutes - 6 minutes is much better. If the fan keeps running, all the better.
As for starting the generator before unplugging at home, while it is 'safe' you probably should also let the compressors be off during the transition time, or they might lose power for 1/2 second, and restart before stopping. If you just set the thermostats to about 85F for the 5 minutes while you are starting the generator and unplugging from your home or campground, it will work fine. Then after the 5 minutes is over, set the thermostat to the desired temp.
Good luck,
Fred.