I have managed to get a D1mini (ESP8266) to read the serial output from P1 port on my Sagemcom T211 power meter.
Using smart meter interface according to the instruction and example script found here
and the Web UI from the device shows accurate reading with Unit of measurement, but the sensor that is auto discovered in Homeassistant has no unit of measurement.
I wonder if anyone has managed to set up something similar and if there is a possibility to use the script in Tasmota to send the MQTT label including unit of measurement?
Also I have tried to use customise function but no change in the attributes of the sensors.

Here is my script for reference.
>D
>B
;smlj=0
->sensor53 r
>R
;smlj=0
>S
;if upsecs>22
;then
;smlj=1
;endif
>M 1
+1,3,o,16,115200,,1
1,1-0:1.8.0(@1,Meter reading import,kWh,enrg_imp,3
1,1-0:2.8.1(@1,Meter reading export,kWh,enrg_exp,3
1,=h—————————————
1,0:1.7.0(@1,power import,kW,power_imp,3
1,0:2.7.0(@1,power export,kW,power_exp,3
;1,13.7.0(@1,Power factor,,factor,3
1,32.7.0(@1,L1 Voltage,V,volt_l1,1
1,52.7.0(@1,L2 Voltage,V,volt_l2,1
1,72.7.0(@1,L3 Voltage,V,volt_l3,1
;1,0:14.7.0(@1,Frequency,Hz,freq,2
1,31.7.0(@1,L1 Current,A,amp_l1,2
1,51.7.0(@1,L2 Current,A,amp_l2,2
1,71.7.0(@1,L3 Current,A,amp_l3,2
1,0:3.8.0(@1,Reactive import,kvarh,renrg_imp,3
1,0:4.8.0(@1,Reactive export,kvarh,renrg_exp,3
;1,0:98.1.0(@(0:#,Month date,,month_date,3
1,=h—————————————
;1,0:96.13.0(@#),Message,,msg,0
;1,0-0:96.1.0(@#),Serial no,,sn,0
#