{"action":"opened","issue":{"url":"https://api.github.com/repos/gotthardp/lorawan-server/issues/317","repository_url":"https://api.github.com/repos/gotthardp/lorawan-server","labels_url":"https://api.github.com/repos/gotthardp/lorawan-server/issues/317/labels{/name}","comments_url":"https://api.github.com/repos/gotthardp/lorawan-server/issues/317/comments","events_url":"https://api.github.com/repos/gotthardp/lorawan-server/issues/317/events","html_url":"https://github.com/gotthardp/lorawan-server/issues/317","id":300996357,"number":317,"title":"ADR rssi","user":{"login":"gnob417","id":34018109,"avatar_url":"https://avatars1.githubusercontent.com/u/34018109?v=4","gravatar_id":"","url":"https://api.github.com/users/gnob417","html_url":"https://github.com/gnob417","followers_url":"https://api.github.com/users/gnob417/followers","following_url":"https://api.github.com/users/gnob417/following{/other_user}","gists_url":"https://api.github.com/users/gnob417/gists{/gist_id}","starred_url":"https://api.github.com/users/gnob417/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gnob417/subscriptions","organizations_url":"https://api.github.com/users/gnob417/orgs","repos_url":"https://api.github.com/users/gnob417/repos","events_url":"https://api.github.com/users/gnob417/events{/privacy}","received_events_url":"https://api.github.com/users/gnob417/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-02-28T11:55:05Z","updated_at":"2018-02-28T11:55:05Z","closed_at":null,"author_association":"NONE","body":"Hi,\r\nthere is \r\n\r\n>  % receiver sensitivity for maximal DR in all regions is -120 dBm, we try to stay at -100 dBm\r\nin ADR codes.\r\n\r\nI want to do experiment in indoor environment with some obstacles. \r\nso i have to correct a little for nodes to stay at the value more reliable than -100dBm.\r\n\r\nmaybe in the below code, i have to change -96 and -102 value??\r\n\r\n\r\n```\r\nTxPower2 = if\r\n            AvgRSSI > -96, TxPower < MinPower ->\r\n                PwrStepUp = trunc((AvgRSSI+100)/4), \r\n                % there are 2 dB between levels, go slower\r\n                lager:debug(\"Power ~s: average rssi ~w, power ~w -> up by ~w\",\r\n                    [lorawan_utils:binary_to_hex(Node#node.devaddr), round(AvgRSSI), TxPower, PwrStepUp]),\r\n                min(MinPower, TxPower+PwrStepUp);\r\n            AvgRSSI < -102, TxPower > MaxPower ->\r\n                PwrStepDown = trunc((AvgRSSI+98)/2), % go faster\r\n                lager:debug(\"Power ~s: average rssi ~w, power ~w -> down by ~w\",\r\n                    [lorawan_utils:binary_to_hex(Node#node.devaddr), round(AvgRSSI), TxPower, PwrStepDown]),\r\n                max(MaxPower, TxPower+PwrStepDown); % steps are negative\r\n            true ->\r\n                TxPower\r\n        end,\r\n```\r\n"}}
{"actor":{"display_login":"gnob417"}}