Solar panels that cannot be connected to the grid don’t have to be declared, but it is based on ability, not intention. So a solar panel so far away from civilization that you physically couldn’t connect it is fine, but if it’s at your house and you could connect it, then you have to register it. (Registration is a 5min online form though, it’s very hassle-free for a system that the German Government came up with lol)
I’m not very knowledgeable on Inverters, they don’t come up much in the legal material I juggle around at work lol
Balcony Units have them built in as far as I know. The only big regulation when it comes to wiring is that anyone who has solar needs their Electricity Counter replaced with a bidirectional “Smart Meter”, because classical Counters can’t really count down when you feed into the Grid. I’m guessing that the Smart Meters themselves would have some sort of safety mechanism to prevent wildly miswired connections.
I think there was some sort of requirement to at least have an electrician check the solar setup before it gets connected too, but German law in most parts is “If you decide not to hire a licensed professional, then anything that happens is your own fault”.