{"id":81,"date":"2018-01-03T22:52:23","date_gmt":"2018-01-03T20:52:23","guid":{"rendered":"https:\/\/amsd.go.ro\/wordpress\/?p=81"},"modified":"2021-09-07T11:24:47","modified_gmt":"2021-09-07T08:24:47","slug":"how-to-handle-unable-to-open-dev-mem-operation-not-permitted","status":"publish","type":"post","link":"https:\/\/amsd.go.ro\/wordpress\/?p=81","title":{"rendered":"How to handle &#8220;Unable to open \/dev\/mem: Operation not permitted&#8221;"},"content":{"rendered":"<p>In case you have kernel 4.9.4+ and you might need to use GPIO fucntions, sudenly you&#8217;ll receive an error message like the one described below:<\/p>\n<pre>wiringPiSetup: Unable to open \/dev\/mem: Operation not permitted<\/pre>\n<p>This is a kernel issue solved in later updates of this kernel version.<\/p>\n<p>In order to solve the problem you have two possibilities:<\/p>\n<ol>\n<li>Make a firmware update and versons later than <strong>4.9.73+<\/strong> solve this issue<\/li>\n<li>Keep you kernel and firmware but add <strong>iomem=relaxed<\/strong> to <strong>\/boot\/cmdline.txt<\/strong><\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>In case you have kernel 4.9.4+ and you might need to use GPIO fucntions, sudenly you&#8217;ll receive an error message like the one described below: wiringPiSetup: Unable to open \/dev\/mem: Operation not permitted This is a kernel issue solved in [&hellip;]<\/p>\n<div class=\"link-more\"><a href=\"https:\/\/amsd.go.ro\/wordpress\/?p=81#more-81\" class=\"more-link\">Continue reading &#10142; <span class=\"screen-reader-text\">How to handle &#8220;Unable to open \/dev\/mem: Operation not permitted&#8221;<\/span><\/a><\/div>","protected":false},"author":6,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[10,7,12],"class_list":["post-81","post","type-post","status-publish","format-standard","hentry","category-technology","tag-ps_32","tag-ps_55","tag-ps_17"],"_links":{"self":[{"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/81","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=81"}],"version-history":[{"count":1,"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/81\/revisions"}],"predecessor-version":[{"id":163,"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/81\/revisions\/163"}],"wp:attachment":[{"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=81"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=81"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/amsd.go.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=81"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}