User Tools

Site Tools


gama300

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
gama300 [2021/11/09 10:56] – created emozolyakgama300 [2022/01/15 05:22] (current) – ↷ Links adapted because of a move operation 127.0.0.1
Line 1: Line 1:
 +{{ network:meter_2_pic.jpg?nolink&200|}}
 ====== Elgama electricity meters ====== ====== Elgama electricity meters ======
  
-{{ ::1140_view.png?direct&200|}}+
 One model has been tested with the help of [[custom_protocols?s[]=custom#custom_protocols|custom protocols]]: One model has been tested with the help of [[custom_protocols?s[]=custom#custom_protocols|custom protocols]]:
   * GAMA300    * GAMA300 
  
-There are custom protocol versions for 7bit Mediator devices. Turn to your local representative for more information.+There is a custom protocol version for the 7bit Mediator devices as well 
 +Turn to your local representative for more information. 
  
 <code lua - example.lua> <code lua - example.lua>
Line 13: Line 16:
                                          
                                         -- Voltages                                         -- Voltages
-                    [3270] = { 0x5, 0x01, 0x02, 0x4F, 0x08 },-- фаза +                    [3270] = { 0x5, 0x01, 0x02, 0x4F, 0x08 },-- ph 
-                    [5270] = { 0x5, 0x01, 0x02, 0x50, 0x08 }, --фаза 2 +                    [5270] = { 0x5, 0x01, 0x02, 0x50, 0x08 },  
-                    [7270] = { 0x5, 0x01, 0x02, 0x51, 0x08 }, --фаза 3 +                    [7270] = { 0x5, 0x01, 0x02, 0x51, 0x08 },  
   
-                                        -- Current +                                        -- Currents 
-                    [3170] = { 0x05, 0x01, 0x02, 0x4b, 0x08 }, -- Ток фаза А  +                    [3170] = { 0x05, 0x01, 0x02, 0x4b, 0x08 }, -- ph 2 
-                    [5170] = { 0x05, 0x01, 0x02, 0x4c, 0x08 }, -- Ток фаза В +                    [5170] = { 0x05, 0x01, 0x02, 0x4c, 0x08 },  
-                    [7170] = { 0x05, 0x01, 0x02, 0x4d, 0x08 }, -- Ток фаза с+                    [7170] = { 0x05, 0x01, 0x02, 0x4d, 0x08 }, 
   
-   -- Active power -- obis 15.7.0 + -- Active power  
-                    [170] = { 0x05, 0x01, 0x02, 0x3A, 0x08 } , -- total активной мощности+                    [170] = { 0x05, 0x01, 0x02, 0x3A, 0x08 }, -- total 
                                          
                     [171] = { 0x05, 0x01, 0x02, 0x3F, 0x08 }, -- ph 1                      [171] = { 0x05, 0x01, 0x02, 0x3F, 0x08 }, -- ph 1 
Line 29: Line 32:
                     [173] = { 0x05, 0x01, 0x02, 0x47, 0x08 }, -- ph 3                     [173] = { 0x05, 0x01, 0x02, 0x47, 0x08 }, -- ph 3
   
- -- Активная положительная энергия + -- Acitve energy 
-     [180] = { 0x05, 0x01, 0x02, 0x01, 0x08  } , -- суммарной +     [180] = { 0x05, 0x01, 0x02, 0x01, 0x08  }, -- total 
                                          
-    -- Реактивной положительной энергии+ -- R. pos. energy 
                     [380] = { 0x05, 0x01, 0x02, 0x03, 0x08 },                      [380] = { 0x05, 0x01, 0x02, 0x03, 0x08 }, 
   
-    -- Реактивной ОТРИЦАТЕЛЬНАЯ энергия - НОВОЕ+         -- R. neg. 
                     [480] = { 0x05, 0x01, 0x02, 0x04, 0x08 },                      [480] = { 0x05, 0x01, 0x02, 0x04, 0x08 }, 
- -- ЧАСТОТА - НОВОЕ+ -- Freq. 
                     [580] = { 0x05, 0x01, 0x02, 0x52, 0x08 },                      [580] = { 0x05, 0x01, 0x02, 0x52, 0x08 }, 
- -- КОЭФ. МОЩНОСТИ  + -- Power factor  
- [581] = { 0x05, 0x01, 0x02, 0x3E, 0x08 }, +                 [581] = { 0x05, 0x01, 0x02, 0x3E, 0x08 }, 
   
- -- Реактивная мощность положительная + -- R. power pos.  
- [582] = { 0x05, 0x01, 0x02, 0x3C, 0x08 },  +     [582] = { 0x05, 0x01, 0x02, 0x3C, 0x08 },  
-   -- Реактивная мощность отрицательная  +                   -- R. power neg.  
- [583] = { 0x05, 0x01, 0x02, 0x3D, 0x08 },  +     [583] = { 0x05, 0x01, 0x02, 0x3D, 0x08 },  
-  +  
-  +                    [181] = { 0x05, 0x01, 0x02, 0x01, 0x20  } , -- tariff 
-                    [181] = { 0x05, 0x01, 0x02, 0x01, 0x20  } , -- Тариф Т+                    [182] = { 0x05, 0x01, 0x02, 0x01, 0x38 } ,  -- tariff 
-                    [182] = { 0x05, 0x01, 0x02, 0x01, 0x38 } , -- Тариф Т+                    [183] = { 0x05, 0x01, 0x02, 0x01, 0x50 } , -- 3 
-                    [183] = { 0x05, 0x01, 0x02, 0x01, 0x50 } , -- Тариф Т+                    [184] = { 0x05, 0x01, 0x02, 0x01, 0x68 } , -- 4
-                    [184] = { 0x05, 0x01, 0x02, 0x01, 0x68 } , -- Тариф T4+
                                            
-                     +                                        -- Time
-                    -- Время +
                     [100] = { 0x05, 0x06,                      [100] = { 0x05, 0x06, 
                                             0x02, 0x68, 0x08,                                              0x02, 0x68, 0x08, 
Line 62: Line 63:
                                             0x02, 0x68, 0x30,                                             0x02, 0x68, 0x30,
                                             0x02, 0x68, 0x38,                                             0x02, 0x68, 0x38,
-                            }, -- получение текущего времени  +                            },  
-                    --[[  +                    }
-                    -- Cos fi +
-                    [3370] = { 0x1, 0x0, 0x21, 0x7, 0x0, 0x0 }, --  фаза А +
-                    [5370] = { 0x1, 0x0, 0x36, 0x7, 0x0, 0x0 }, --  фаза В +
-                    [7370] = { 0x1, 0x0, 0x49, 0x7, 0x0, 0x0 }, --  фаза с +
-                     +
-                    -- Углы  +
-                    [3371] = { 0x1, 0x0, 0x21, 0x7, 0x0, 0x1 },-- Запрос на получение угла между фазами А и В (ОБИС код- 1, 0, 33, 7, 0, 1; +
-                    [7371] = { 0x1, 0x0, 0x49, 0x7, 0x0, 0x1 }, -- получение угла между фазами А и C  +
-                    --]]  +
-                }+
  
 SRNMsample =     {0x7E, 0xA0, 0x0A, -- frame type and length SRNMsample =     {0x7E, 0xA0, 0x0A, -- frame type and length
Line 87: Line 78:
             0x00, 0x00, 0x00, 0x00, -- now dest address             0x00, 0x00, 0x00, 0x00, -- now dest address
             0x21, 0x10,             0x21, 0x10,
-            0x0, 0x0, -- HEADER  CRC ВРЕМЕННО СТАВИМ ДЛЯ ПРОВЕРКИ Ф . !!! 0x67, 0x26,+            0x0, 0x0,         -- HEADER  CRC 
             0xE6, 0xE6, 0x00, -- llc              0xE6, 0xE6, 0x00, -- llc 
             0x60, 0x29, -- tag and length             0x60, 0x29, -- tag and length
Line 107: Line 98:
 local err_cnt = 0; local err_cnt = 0;
 local step_Ok = 0; local step_Ok = 0;
-local alreadyRead = false;   -- флаг выполнения полного чтения  +local alreadyRead = false; 
-local timeStmp = 0;          -- метка времени между полными чтениями  +local timeStmp = 0;        
-local POLLTIME = 60; -- время опроса в секундах +local POLLTIME = 60; 
- +
--------------------------------------------------------------------- +
--- КЕШ ответов+
  
-local repliesCache = {}-- сюда копируем ответы при полном чтении +local repliesCache = {}  -- copy here meter's replies 
  
 --------------------------------------------------------------------- ---------------------------------------------------------------------
 function createDevices () function createDevices ()
-  --                                                             OBIS code  +  addDevice({name = "R",  shift = 0, base = 10, xtraFields = {96, 1, 3, 0, 0}})
-  addDevice({name = "R",  shift = 0, base = 10, xtraFields = {96, 1, 3, 0, 0}});  -- запрос о типе  счетчика +
 end end
 +-- Turn to your local representative for more information.
 </code> </code>
gama300.txt · Last modified: 2022/01/15 05:22 by 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki