the solar panels should be connected to a controller, that is connected to the house batteries under the step
with out knowing the panel wattage and the battery type and amphrs
we can only give the most general advice
the inverter should be connected to the 'house' batteries NOT the engine battery
the engine has nothing to do with the inverter or solar, it will in 'most' cases
charge the engine battery first and house batteries second, while the engine is running
i do not see a signature in your post
you might have put some info in your 'profile', i have not looked at that