{"action":"created","issue":{"url":"https://api.github.com/repos/esp8266/Arduino/issues/354","labels_url":"https://api.github.com/repos/esp8266/Arduino/issues/354/labels{/name}","comments_url":"https://api.github.com/repos/esp8266/Arduino/issues/354/comments","events_url":"https://api.github.com/repos/esp8266/Arduino/issues/354/events","html_url":"https://github.com/esp8266/Arduino/issues/354","id":81816631,"number":354,"title":"math log() function crashes with reboot.","user":{"login":"cornelalexa","id":1678411,"avatar_url":"https://avatars.githubusercontent.com/u/1678411?v=3","gravatar_id":"","url":"https://api.github.com/users/cornelalexa","html_url":"https://github.com/cornelalexa","followers_url":"https://api.github.com/users/cornelalexa/followers","following_url":"https://api.github.com/users/cornelalexa/following{/other_user}","gists_url":"https://api.github.com/users/cornelalexa/gists{/gist_id}","starred_url":"https://api.github.com/users/cornelalexa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cornelalexa/subscriptions","organizations_url":"https://api.github.com/users/cornelalexa/orgs","repos_url":"https://api.github.com/users/cornelalexa/repos","events_url":"https://api.github.com/users/cornelalexa/events{/privacy}","received_events_url":"https://api.github.com/users/cornelalexa/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-05-28T08:03:40Z","updated_at":"2015-05-29T18:52:32Z","closed_at":null,"body":"Hi,\r\n\r\nI have a dew point calculation function which use log() and when used the ESP crashes and reboots.\r\nHere is the code for it.\r\n\r\nfloat dewPointFast(float celsius=0, float humidity=0)\r\n{\t\r\n\tif(celsius==0 && humidity ==0) return (float) 0.00;\r\n        const float a = 17.271;\r\n\tconst float b = 237.7;\r\n\tfloat temp = (float)((a * celsius) / (b + celsius));\r\n        temp+= log(humidity/100); //this crashes and reboots\r\n\tfloat Td = (float)((b * temp) / (a - temp));\r\n\treturn Td;\r\n}\r\n\r\nIt seems that log10() does the same so it might worth having a look at that too.\r\n\r\nThanks!"},"comment":{"url":"https://api.github.com/repos/esp8266/Arduino/issues/comments/106902387","html_url":"https://github.com/esp8266/Arduino/issues/354#issuecomment-106902387","issue_url":"https://api.github.com/repos/esp8266/Arduino/issues/354","id":106902387,"user":{"login":"cornelalexa","id":1678411,"avatar_url":"https://avatars.githubusercontent.com/u/1678411?v=3","gravatar_id":"","url":"https://api.github.com/users/cornelalexa","html_url":"https://github.com/cornelalexa","followers_url":"https://api.github.com/users/cornelalexa/followers","following_url":"https://api.github.com/users/cornelalexa/following{/other_user}","gists_url":"https://api.github.com/users/cornelalexa/gists{/gist_id}","starred_url":"https://api.github.com/users/cornelalexa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cornelalexa/subscriptions","organizations_url":"https://api.github.com/users/cornelalexa/orgs","repos_url":"https://api.github.com/users/cornelalexa/repos","events_url":"https://api.github.com/users/cornelalexa/events{/privacy}","received_events_url":"https://api.github.com/users/cornelalexa/received_events","type":"User","site_admin":false},"created_at":"2015-05-29T18:52:32Z","updated_at":"2015-05-29T18:52:32Z","body":"Thank you.\r\n\r\nThe above functions works as a fix for me. Hope they will be able to fix in the toolchain also. It seems that many functions related to math have issues... "}}