# Floating value in S7 node

**URL:** <https://discourse.nodered.org/t/floating-value-in-s7-node/30953>\
**Category:** Industrial\
**Created:** [31 July 2020 03:19 UTC](https://discourse.nodered.org/t/floating-value-in-s7-node/30953 "2020-07-31T03:19:37Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![munirazam1989](https://avatars.discourse-cdn.com/v4/letter/m/94ad74/32.png) [@munirazam1989](https://discourse.nodered.org/u/munirazam1989)\
**Post date:** [31 July 2020 03:19 UTC](https://discourse.nodered.org/t/floating-value-in-s7-node/30953/1 "2020-07-31T03:19:37Z")

</div>

I am using Siemens S7 node to extract floating value from plc but the value it is showing is quite big and not showing me real numbers of debug node.

Let's i store 10.1 at MD10 but the value in node is very big integer number

---

<div class="post-metadata">

**Author:** ![machadotiago](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/machadotiago/32/23776_2.png) [@machadotiago](https://discourse.nodered.org/u/machadotiago)\
**Post date:** [1 August 2020 02:36 UTC](https://discourse.nodered.org/t/floating-value-in-s7-node/30953/2 "2020-08-01T02:36:23Z")

</div>

Could you please post your flow here, together with what is shown on Node-RED and what should be the value on the PLC (maybe a screenshot from SIMATIC)

---

<div class="post-metadata">

**Author:** ![Cristiano](https://avatars.discourse-cdn.com/v4/letter/c/b5e925/32.png) [@Cristiano](https://discourse.nodered.org/u/Cristiano)\
**Post date:** [23 August 2020 22:01 UTC](https://discourse.nodered.org/t/floating-value-in-s7-node/30953/3 "2020-08-23T22:01:09Z")

</div>

Hello

You need to use something like msg.payload.tag.toFixed(2)) for 2 decimal places

---

<div class="post-metadata">

**Author:** ![munirazam1989](https://avatars.discourse-cdn.com/v4/letter/m/94ad74/32.png) [@munirazam1989](https://discourse.nodered.org/u/munirazam1989)\
**Post date:** [24 August 2020 00:17 UTC](https://discourse.nodered.org/t/floating-value-in-s7-node/30953/4 "2020-08-24T00:17:38Z")

</div>

Thanks for your reply, I have used MR instead of MD and use round function to round for 2 decimal place

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [7 September 2020 00:17 UTC](https://discourse.nodered.org/t/floating-value-in-s7-node/30953/5 "2020-09-07T00:17:42Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
