Tranform number from tasmota counter

i am getting a number from a tasmota counter i have setup for my natural gas consumption.The number that i get is for example : 6553445 and that is in m㎥ so to see it in ㎥ i have to divide with 1000 to like 6553.445㎥.How can i do it from channel’s incoming transformation?Now i have


If using mqtt as connection, simply use the UoM feature:

UID: mqtt:topic:mosquitto:device
label: My Device
thingTypeUID: mqtt:topic
configuration: {}
bridgeUID: mqtt:broker:mosquitto
location: mqtt
  - id: counter
    channelTypeUID: mqtt:number
    label: Counter
    description: null
      retained: false
      postCommand: false
      step: 1
      stateTopic: tele/mydevice/SENSOR
      transformationPattern: REGEX:(.*C1.*)∩JSONPATH:$.COUNTER.C1
      unit: mm³

Setup a Number:Volume Item and set unit to m³ (here as text, works through UI, too):

Number:Volume myVolume "Volume" ["Measurement","Gas"] {unit="m³", stateDescription=""[pattern="%.1f m³"], channel="mqtt:topic:mosquitto:device:counter"}

Please be aware that mm³ to m³ is 1/1000 * 1/1000 * 1/1000, so maybe the counter does not mm³ but dm³ (aka litre → l)

thnx mate it was d㎥ not mm³…