{"action":"created","issue":{"url":"https://api.github.com/repos/BoschSensortec/BME280_driver/issues/49","repository_url":"https://api.github.com/repos/BoschSensortec/BME280_driver","labels_url":"https://api.github.com/repos/BoschSensortec/BME280_driver/issues/49/labels{/name}","comments_url":"https://api.github.com/repos/BoschSensortec/BME280_driver/issues/49/comments","events_url":"https://api.github.com/repos/BoschSensortec/BME280_driver/issues/49/events","html_url":"https://github.com/BoschSensortec/BME280_driver/issues/49","id":320870277,"node_id":"MDU6SXNzdWUzMjA4NzAyNzc=","number":49,"title":"BME280.c Compile Problem","user":{"login":"srf461","id":39059242,"node_id":"MDQ6VXNlcjM5MDU5MjQy","avatar_url":"https://avatars2.githubusercontent.com/u/39059242?v=4","gravatar_id":"","url":"https://api.github.com/users/srf461","html_url":"https://github.com/srf461","followers_url":"https://api.github.com/users/srf461/followers","following_url":"https://api.github.com/users/srf461/following{/other_user}","gists_url":"https://api.github.com/users/srf461/gists{/gist_id}","starred_url":"https://api.github.com/users/srf461/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srf461/subscriptions","organizations_url":"https://api.github.com/users/srf461/orgs","repos_url":"https://api.github.com/users/srf461/repos","events_url":"https://api.github.com/users/srf461/events{/privacy}","received_events_url":"https://api.github.com/users/srf461/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":41,"created_at":"2018-05-07T16:31:11Z","updated_at":"2018-07-12T11:29:31Z","closed_at":null,"author_association":"NONE","body":"Good morning all.  This is my first post here.  I am a C rookie and am trying to incorporate a BME280 sensor into a project of mine that is using a Microchip PIC18F27K42 MCU.  My IDE is MPLAB X IDE.  My compiler is XC8.  I wrote and successfully built my main() function.  Then I copied bme280.c, bme280.h, and bme280_defs.h from the following github page:    \r\n\r\nhttps://github.com/BoschSensortec/BME280_driver\r\n\r\nI incorporated them into my project.  I did NOT call the bme280.c from my main() function, I simply incorporated the files and tried to get it to compile.\r\n\r\nIt did not.  It gave me a bunch of warnings and two errors.  The first error was as follows:\r\n\r\nCompiler Error:   \r\n     BME280.c:594: error: (188) constant expression required\r\n\r\nbme280.c line 594:\r\n\tuint8_t reg_data[BME280_P_T_H_DATA_LEN] = {0};\r\n\r\nI tried taking a systematic approach to it by looking at each element of the line individually:\r\nI found that \"uint8_t\" that is in the line is not defined in bme280.c or in the other two files.  \r\n\r\nI went out on the internet and found an \"inttypes.h\" file that defines it as \"typedef unsigned char uint8_t;.\"\r\n\r\nI incorporated that file into my project and did a #include \"inttypes\" in bme280.c.  \r\n\r\nThen I built it again.  I got the same error with a different line number of course because of the addition of the #include statement.\r\n\r\nI then looked at what I assume is a constant: \"BME280_P_T_H_DATA_LEN\".  I found it defined in bme280_defs.h in the following statement: \r\n\r\n#define BME280_P_T_H_DATA_LEN\t\t\t\tUINT8_C(8)\r\n\r\nAnd then I looked at the array itself (\"reg_data\").  It seems to be locally defined as unit8_t in the line.\r\n\r\nSo I don't see where the error is  And what's more, it looks as if others have used this code successfully.  So what am I doing wrong?  \r\n\r\nThanks in advance,\r\nRay Russell"},"comment":{"url":"https://api.github.com/repos/BoschSensortec/BME280_driver/issues/comments/404481055","html_url":"https://github.com/BoschSensortec/BME280_driver/issues/49#issuecomment-404481055","issue_url":"https://api.github.com/repos/BoschSensortec/BME280_driver/issues/49","id":404481055,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNDQ4MTA1NQ==","user":{"login":"srf461","id":39059242,"node_id":"MDQ6VXNlcjM5MDU5MjQy","avatar_url":"https://avatars2.githubusercontent.com/u/39059242?v=4","gravatar_id":"","url":"https://api.github.com/users/srf461","html_url":"https://github.com/srf461","followers_url":"https://api.github.com/users/srf461/followers","following_url":"https://api.github.com/users/srf461/following{/other_user}","gists_url":"https://api.github.com/users/srf461/gists{/gist_id}","starred_url":"https://api.github.com/users/srf461/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srf461/subscriptions","organizations_url":"https://api.github.com/users/srf461/orgs","repos_url":"https://api.github.com/users/srf461/repos","events_url":"https://api.github.com/users/srf461/events{/privacy}","received_events_url":"https://api.github.com/users/srf461/received_events","type":"User","site_admin":false},"created_at":"2018-07-12T11:29:31Z","updated_at":"2018-07-12T11:29:31Z","author_association":"NONE","body":"Actually, let me un-modify my code so that it will use my own parameters.  I will send them to you in a couple of minutes."}}
{"actor":{"display_login":"srf461"}}