Energy panel settings / battery entity

Hi, I’d want to integrate the battery storage in my energy panel, but I need to calculate the energy feed into the batteries: I put a current meter (pzemDC) so I can measure current, voltage and power but the same meter is active in both charge /discharge. How can I create an entity (utility meter) only for charge? Thanks.