Posted 25 Jan 2019 Hello! I am new at PLC programming. I am using TM221CE16R PLC with TM3AI8 analog input module and SoMachine Basic v1.6. I am trying to scale analog input value. I am using 4-20 mA pressure sensor. I managed my wiring so that I get raw values in SoMachine Basic. But I don't know how to scale these values to usable values. My sensor works in range 0 - 16 bar. What is best way to get values? Is it PID function block or multioperand function block using equations to get range 0 - 16? I will appreciate your help. Thanks in advance! Share this post Link to post Share on other sites
Posted 26 Jan 2019 PID has nothing to do with scaling. Share this post Link to post Share on other sites
Posted 26 Jan 2019 For scaling in M221 you need to follow by scale equations as this link below. https://stackoverflow.com/questions/5294955/how-to-scale-down-a-range-of-numbers-with-a-known-min-and-max-value Then I have create program example to scaling input. Please check it. M221_Analog_IP_Scale.smbp 2 people like this Share this post Link to post Share on other sites
Posted 28 Jan 2019 Thanks a lot for your replies. @Wasan, scale equations work great, also your program example is perfect. It's all clear to me. Thanks! Share this post Link to post Share on other sites
Posted 9 Jan 2020 Wasan: Your example is very good, but could to explain to me why you convert to double word and floating? To help me understand better. Thanks in advance Share this post Link to post Share on other sites
Posted 9 Jan 2020 I have convert to DWORD and floating because if you use normal 16 bit word you can have maximum value at 65535 then I convert to Dword or float 32 bit to can have result more thn 65535 espicially when you multiply them You can use for dword if you need to only integer resule and float for accurancy for fraction. Share this post Link to post Share on other sites
Posted 29 Jan 2020 (edited) Can HMI GXU3512 connect with altivar12HU22M2 with cables TCSMCNAM3M002PTCSMCNAM3M002P ? i need help im newbie Edited 29 Jan 2020 by SaukiBullah Share this post Link to post Share on other sites
Posted 3 Feb 2020 @SaukiBullah You should create your own cable first by followwiring diagram from these link below. Magelis HMIGXU3512 at page 35 https://download.schneider-electric.com/files?p_enDocType=User+guide&p_File_Name=GXU_+User+Manual.pdf&p_Doc_Ref=BR082018FP037 Inverter Altivar12 ATV12HU22M2 at page 8 https://download.schneider-electric.com/files?p_enDocType=User+guide&p_File_Name=ATV12_Modbus_EN_BBV28590_02.pdf&p_Doc_Ref=BBV28590 Share this post Link to post Share on other sites
Posted 24 Jun 2020 What about PID in M22 Can you get an example Share this post Link to post Share on other sites