Logging Rainforest EMU-2 data snapshot

I have a Rainforest Automation EMU-2.
It’s connected just fine to my utility meter.
And the data displays just fine on HA.

I am on a 6 tiered rate structure. 3 in the summer and
3 in the winter.

The EMU-2 provides copies of the two registers in the meter.
One for KWh in and one for KWh out.

Rate changes at Midnight, 3pm, 4pm, and 9pm

I would like to log the two registers into one or more txt? files
so I can do some rate planning and optimize PV system operation.

The plots in HA are very nice but the information I am trying to grab
is KWh usage during each rate period. Off Peak, Part Peak, and Peak.

Any pointers or example code would be much appreciated.

WB9VXY