Hi
I will assume you have a trailer with the 7 pin plug with the 7th pin in the center of the plug.
On the 7 pin plug your brakes are on pin #2 I am not familiar with the new built in controllers so I am not sure what they might do without the load connected.
Pin 4 should be 12 V or your truck battery voltage. This is the one that charges your battery while you are traveling.
Pin 7 is the center pin and is normally used for backup lights.
You don’t need the trailer battery to make the brakes work but without the battery your break-A-way braking system would not work.
If I were working on the system I would first determine I had proper voltage on all of the pins in the socket on the truck at the proper time
Pin 1 is ground
Pin2 is brake controller
Pin 3 is Tail and running lights
Pin 4 is 12 v battery
Pin 5 is left turn
Pin 6 is right turn
Pin 7 Backup lights
When holding the trailer plug with the key up.
Pin 1 & 2 are on the bottom opposite the key
Pin 3 & 4 are on top either side of the key
Pin 5 & 6 are across from each other at the center line of the plug
Pin 7 is the center pin.
Phil P