7/17/2009 2:34 AM | |
Posts: 7 Rating: (0) |
Hello, Thanks to all for the interest. Here goes the datasheet of a pH sensor that it's avaliable on my local electronic store. I can't really tell if the output is in V or A.. :-/ Attachment20-1005_data_en.pdf (591 Downloads) |
7/17/2009 2:10 PM | |
Joined: 1/5/2007 Last visit: 4/7/2023 Posts: 1690 Rating: (580)
|
Hi jbrazio, AttachmentJUMO_pH_en_Infos.zip (603 Downloads) |
==> Meine TAG-Listen: "deut." |
|
7/17/2009 2:45 PM | |
Joined: 1/5/2007 Last visit: 4/7/2023 Posts: 1690 Rating: (580)
|
Hello jbrazio, hello LOGO!Barbarian, I have a diverging opinion concerning a possible solution of your setting of a task with a LOGO!-0BA6 which I want to represent in the following one shortly. Notes on calculations with optimization of the LOGO!: The most important facts and restrictions concerning the LOGO! Programming already informed you of LOGO!Barbarian. to a) for the application here: to b) for the application here: Through some tricky modifications to allow the calculation and display resolution still significantly improve ( "DEMO_CO2_calculation__Math_equations_with_LOGO_V2 (0BA6). Lsc"). For this purpose the "table values with greater number of digits" are pre-set (see Note below). Ultimately, it is now one text box of three possible text message texts selected (because, unfortunately, can the number of decimal places not by reference to program define) and then display the best possible resolution automatically adjusted. The so achieved calculation is much better than for the solution version of LOGO! Barbarian and the version in "DEMO_CO2_calculation__Math_equations_with_LOGO_V1 (0BA6). Lsc" (compare the EXCEL Table2)! A disadvantage is simply that the further processing of the combined output value (in block B029 "CO2_mod) in the context of circuit (of course only if requested or required) differrenziert be! However, in this case also reached the precision of calculation block B026 "CO2_x" with one decimal place for all values suffice! b) divisions should be (only) in the last block ( = final calculation result) done. The EXCEL file demonstrated in "Table2" and "Table3" these concepts and their impact on the respective calculation results with a LOGO! module. The processed data also show how EXCEL-files the action in a LOGO! -program can be exercised ... To the version "DEMO_CO2_calculation__Math_equations_with_LOGO_V2 (0BA6). Lsc": Even the (previous) multiplying the values "10 ** (7-pH)" by a factor of 3 (the original equation) and a factor of 10 (for display one digit after decimal point) and the definition of these values, "30 * 10 ** (7-pH)" as the table output values for the function f (pH) leads to improved calculation results .... Another "advancement" of the multiplier 100 for the requested additional 2 decimal places after decimal point, in conjunction with a "switching" or "recalculation with this factor" during the subsequent multiplication with the variable value of kH then leads to a mathematic correct calculation of 1 or 2 decimal places after decimal point as rounded values for CO2. Only the 3rd position after the decimal point indicates partial small deviations from rounding errors! In this case the predetermined table values for f (pH) (Parameters of the multiplexers) are no longer multiplied with 1000, but each with individual factors multiplied by the maximum large values (only slightly smaller than a maximum of 32767). In calculating the final values for CO2 (separated by number of decimal places) must then also these individual factors are taken into account. They are (must be) also in a table multiplexers available. Look at the comments in EXEL-Table3 - At this time i have not programed a version V3 to work with this last concept! Please look and test the attached files as help to understand the concept to optimize this (or other) calculation(s) with a LOGO! module... Best regards Perhaps helpful links: AttachmentDEMO_CO2_calculation__Math_equations_with_LOGO (0BA6).zip (1296 Downloads) |
==> Meine TAG-Listen: "deut." |
|
This contribution was helpful to2 thankful Users |
7/18/2009 10:14 AM | |||||
Joined: 1/5/2007 Last visit: 4/7/2023 Posts: 1690 Rating: (580)
|
Hi jbrazio, with my helpful link "Scalingof signals with analog blocks" you can find an EXCEL-tool from me to calculate the parameters of LOGO! analog amplifivers in an easy way.... Look at the attachment here to see witch inputs solve your question: 0 pH: 400 mv = 0,4 V puts the value 40 into LOGO!-analog input block 12pH: 12000 mv =12,0 V puts the value12000 into LOGO!-analog input block OK, i remember LOGO! analog inputs are onlo 0 to 10 V means 1000 as the value into LOGO!-analog input block, but for the calculation of the needed block parameters this values are possible (and easy) to use. You must save, that the analog input signal is every time maximal 10,00 V !!! OUTPUT wanted in 0,0 pHto 12,0 pH means 0 to 120 LOGO! units The result is, that you must only change the parameters of the block B001 to GAIN = 0,1 and OFFSET = -4. Of cause, if you connect the signal to I7 (= AL1). AND see for big values of pH there is a smal difference between LOGO! amplifier output (pH = 11[,]6) and the correct value (pH = 12[,]0) OK with some blocks more you can solve this effect: Replace
To do this, you need 2 amplifiver in series (because GAIN is > 10,00). Use for the first amplifier GAIN = 10,00 and OFFSET = 0 Use for the second amplifier GAIN = 1,04 and OFFSET = -414 Now add a block analog math to divide the value from the second amplifier output with 100 to get the needed resolution of pH and use the output pin of that block in the same way as before B001 !!! Remember that the LOGO! program from me display in the range from 0 pH to 10 pH withthe correct value, but the value for CO2 is only corect in the range pH = 6,0 to 7,6 !!!You can add 1 or 2 blocks threshold trigger to test this condition and display 1 or 2 different alarms... Best regards Betel _______________________________________________ Perhaps helpful links: AttachmentCalculation_of_GAIN_and_OFFSET_for_analoge_amplifier (LOGO) pH.zip (598 Downloads) |
||||
==> Meine TAG-Listen: "deut." |
|||||
8/2/2009 9:40 PM | |
Joined: 1/5/2007 Last visit: 4/7/2023 Posts: 1690 Rating: (580)
|
hi jbrazio, here my answers to you:
The infos inside the handbook and under http://support.automation.siemens.com/WW/view/en/17967360contains the following facts: a) Analoge input range 0 to 10,00 V (gives integer values 0 to 1000 to a LOGO! circuit b) input volgage over 10,00 V gives every time the value 1000 to the LOGO! circuit c) input voltage of 12 V DC are no problem d) because the input pins for analoge voltage at the LOGO! basic modules are also digital input pins with maximum voltage values of 24 V DC, i think that the maxumum analoge input value should be 24 V too (of cause only with 0 to 10 V as measure range !!!)
Yes, that is correct...without changes of the circuit - only changes of values of the (or some) multiplexers are necessary - you can add two values/points more: pH 6,0 to 7,6 --->> 5,8 to 7,6 or 5,9 to 7,7 or 6,0 to 7,8 (values calculated with the given EXCEL-sheed. OR with changes of the circuit - add more blocks anlog multiplexer and threshold trigger - and with additional calculation points with the EXCEL-sheed you can use a bigger pH range to calculate CO2. Look at the modified EXCEL-file for the needed values to set the block parameters... Best regards Betel _______________________________________________ Perhaps helpful links: AttachmentDEMO_CO2_calculation__Math_equations_with_LOGO_pH5to9 (0BA6).zip (538 Downloads) |
==> Meine TAG-Listen: "deut." |
|
This contribution was helpful to1 thankful Users |
8/4/2009 12:36 PM | |
Posts: 7 Rating: (0) |
Hello Betel, I think I've made the correct modifications to the circuit, could you please check ? I'm still missing the extra trigers to be able to display a wider CO2 value correctly. What I'm not understading yet is how to work with the excel gain calculator.. and how do inline amplifiers work.. :-/ For instance, the Ai maximum value shouldn't be the 10V that LOGO can handle ? On the example you gave you're using the 0,4-12V range for Ai, the pH output should be 0 to 120 LOGO units, because gain is <10 then only one amp is needed with offset=-4 and gain=0,10. But when I increase the Ax max from 120 to 12000 the GAIN is > than 10, so two amps are needed. The first one GAIN=10 and the second one GAIN=1,04. BUT the calculator gives GAIN=10,35.. does this mean that en serializing amps, the gain value of the second one is always 1 + TOTAL_GAIN - 10 ? But despite the fact that the pH probe works on 0,4 to 12V. I would like to restrict the min and max pH display between 5 and 9.. how to find the correct values for the two amps ? Last question, is for any special reason that blocks 12 and 10 have the sensor type setup ? The other blocks like 04 and 06 do not have that. Best regards, JB. AttachmentDEMO_CO2_calculation__Math_equations_with_LOGO_V2_pH_5_to_9 (0BA6).zip (521 Downloads) |
8/8/2009 6:17 PM | |
Joined: 1/5/2007 Last visit: 4/7/2023 Posts: 1690 Rating: (580)
|
Hi jbrazio, your circuit is ok - look my modification to display the correct pH range for CO2-calculation... The EXCEL-sheed calculate a linear translation from a input range to an output range. The basis are two datapoints at the linear kurve. Because the input and outputrange of the block "amplifier" is from -32768 to 32767 the calculation is possible for this range - the range of analog input pins is only 0 to 1000!!! If the calculation results a value GAIN bigger as 10,00 we need more than one blocks amplifier (0BA5) or, if we have a LOGO!-0BA6, one block "analog Math" is also possible... a) If we use two (or more) blocks amplifier at one signal line, we must calculate now the parameters GAIN and OFFSET for all this amplifiers. Set all parameters OFFSET = 0, only OFFSET of the last amplifiermust set by the calculated EXCEL-value (if bigger than +/- 10000 we need more blocks amplifier to add the complet value). The parameters GAIN of all amplifiers we calculated Gain(EXCEL) = GAIN_1 * GAIN_2 .... with the best fitting!!! b) If we use a block analog math, it is possible the real value GAIN(EXCEL) to translate as two integer values n and z with "n / z": V1 = Bxxx V2 = n V3 = z V4 = OFFSET (excel) ...((V1 * V2) / V3) +/- V4 10,35...n = 1035 and z = 100 B010 and B012 sensor type:Sorry, i only have made no change of the default values! REMEMBER that this settings in the window have only the effect to set the parameters GAIN and OFFSET for some given sensor types in an easy way - i used this never - i only set the parameters Gain and OFFSET by myself... Best regards Betel _______________________________________________ Perhaps helpful links: AttachmentDEMO_CO2_calculation__Math_equations_with_LOGO_V2b_pH_5_to_9 (0BA6).zip (503 Downloads) |
==> Meine TAG-Listen: "deut." |
|
Follow us on