Sounds simple. It may not be.
You’ll need to know when you’re generating excess solar. This will require at least three energy monitoring channels: solar generated, energy being exporting, energy being consumed by the HVAC unit. I’ll reference Open Energy Monitor here.
Under what conditions would the HVAC unit be turned on? When there is an excess? When there is sufficient excess if you know what the HVAC is going to require? And off? When you are importing?
If the HVAC is on and a light is turned on, this may put you into importing, but shortly there after, the light is turned off. How would are transients handled?
How is the comfort vs efficiency to be handled?
Can the energy consumption of the HVAC unit be controlled?
I’ve considered a scenario like the following because I’m on net metering. When I have exported sufficient energy to run the HVAC for 1 hour, I turn on the HVAC. After and hour, I determine the energy exported during that hour. If energy was exported, I continue to run the HVAC for a time that is proportionate to the energy exported. After that time, I redo the calculation and continue to run the HVAC or turn it off for the rest of the day.
In my area we have Time-of-Use metering. Exported energy is “stored” as dollars, meaning if I generate 3kW during the off-peak period, I get back 1kW during on-peak period. Consideration for crossing into another time period should be made.
In my opinion, what you need to get started is a clear understanding of what you’re trying to do. Though, setting up a system that has most of the major elements and then after running for a while, modifying the system to fit your needs, works, too.