{"id":212,"date":"2015-10-05T23:22:05","date_gmt":"2015-10-05T23:22:05","guid":{"rendered":"https:\/\/einhugur.com\/blog\/?page_id=212"},"modified":"2016-05-01T19:33:10","modified_gmt":"2016-05-01T19:33:10","slug":"connecting-button-with-gpio-and-using-interupts","status":"publish","type":"page","link":"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/connecting-button-with-gpio-and-using-interupts\/","title":{"rendered":"Connecting Button with GPIO and using interupts"},"content":{"rendered":"<h2>In this example we are going to connect the Raspberry PI with a button, and then make \u00a0Xojo programs where the first one will read from the button without\u00a0interrupts and\u00a0the second will be doing the same using interrupts.<\/h2>\n<p><strong>Disclaimer:<\/strong><br \/>\nWe do not take any responsibility for possible errors in the guide or errors that you might do wiring it up. Incorrect wiring can result in damaged sensor or damaged Raspberry PI.<\/p>\n<p><strong>Pieces we use are:<\/strong><\/p>\n<ul>\n<li>Raspberry PI 2<\/li>\n<li>Cobbler and Cobbler cable<\/li>\n<li>Bread board<\/li>\n<li>1 K-ohm resistor<\/li>\n<li><span style=\"color: #999999;\"><span style=\"color: #000000;\">\u00a0A button<\/span><\/span><\/li>\n<li><a href=\"https:\/\/github.com\/xojo\/GPIO\">Wiring PI Xojo module from\u00a0Paul Lefebvre<\/a> <span style=\"color: #999999;\">(Note we will be making modifications for the interrupts example)<\/span><\/li>\n<\/ul>\n<p><strong>If you are not familiar with working with a breadboard or on how to place a cobbler on the breadboard then click here bellow<\/strong><\/p>\n<ul>\n<li><a href=\"https:\/\/einhugur.com\/blog\/index.php\/understanding-your-breadboard-and-placement-of-raspberry-cobbler\/\">Understanding your breadboard and placement of Raspberry cobbler<\/a><\/li>\n<\/ul>\n<p><strong>If you don&#8217;t know resistor color codings to find correct resistors then you can click the link bellow<\/strong><\/p>\n<ul>\n<li><a href=\"https:\/\/einhugur.com\/blog\/index.php\/basic-electronics\/resistor-color-codings\/\">Resistor color codings<\/a><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<p><strong>First thing is understanding the wiring of the button:<\/strong><\/p>\n<p>My button looked like this:<\/p>\n<p><a href=\"https:\/\/i0.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/10\/Button-e1444084364993.jpg?ssl=1\"><img data-attachment-id=\"215\" data-permalink=\"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/connecting-button-with-gpio-and-using-interupts\/button\/\" data-orig-file=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/Button-e1444084364993.jpg?fit=310%2C404&amp;ssl=1\" data-orig-size=\"310,404\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;2.2&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;iPhone 6&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1444083888&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;4.15&quot;,&quot;iso&quot;:&quot;32&quot;,&quot;shutter_speed&quot;:&quot;0.0011627906976744&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;6&quot;}\" data-image-title=\"Button\" data-image-description=\"\" data-medium-file=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/Button-e1444084364993.jpg?fit=230%2C300&amp;ssl=1\" data-large-file=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/Button-e1444084364993.jpg?fit=310%2C404&amp;ssl=1\" loading=\"lazy\" class=\"alignnone size-full wp-image-215\" src=\"https:\/\/i0.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/10\/Button-e1444084364993.jpg?resize=310%2C404&#038;ssl=1\" alt=\"Button\" width=\"310\" height=\"404\" srcset=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/Button-e1444084364993.jpg?w=310&amp;ssl=1 310w, https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/Button-e1444084364993.jpg?resize=230%2C300&amp;ssl=1 230w\" sizes=\"(max-width: 310px) 100vw, 310px\" data-recalc-dims=\"1\" \/><\/a><\/p>\n<p>The button had 4 pins, 2 and 2 are same. At first I was not sure how its internal wiring was, as in which two poles were the same and which were the opposite. So I used digital multimeter to get to know its internal wiring.<\/p>\n<p><span style=\"color: #999999;\">Do not worry if you don&#8217;t know which pins are what on your button, if you get it wrong then worst thing that can happen is the reading of your application will just be always pressed down.<\/span><\/p>\n<p>You will want to protect the GPIO pin from mistakes, like if you were to program it as output instead of input then without protection you likely would damage the Raspberry PI. So we use 1K resistor to protect the pin.<\/p>\n<p><em>1\u00a0KOhm resistor in 4 stripe system = \u00a0Brown &#8211; Black &#8211; Red\u00a0<span style=\"color: #808080;\">(Read towards the golden stripe)<\/span><\/em><\/p>\n<p>If you have 5 or 6 stipe system on your resistors then you can <a href=\"http:\/\/www.1728.org\/resisclr.htm\">5 and 6 stripe resistors<\/a> to get help on reading their values if you do not know how.<\/p>\n<p>Now once the resistor is in place then if doing programming error it should not damage the pin.<\/p>\n<p>On the breadboard it looked like this:<\/p>\n<p><a href=\"https:\/\/i2.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/10\/ButtonWiring-e1444085736803.jpg?ssl=1\"><img data-attachment-id=\"219\" data-permalink=\"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/connecting-button-with-gpio-and-using-interupts\/buttonwiring\/\" data-orig-file=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/ButtonWiring-e1444085736803.jpg?fit=480%2C640&amp;ssl=1\" data-orig-size=\"480,640\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;2.2&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;iPhone 6&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1444085436&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;4.15&quot;,&quot;iso&quot;:&quot;32&quot;,&quot;shutter_speed&quot;:&quot;0.0032679738562092&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;6&quot;}\" data-image-title=\"ButtonWiring\" data-image-description=\"\" data-medium-file=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/ButtonWiring-e1444085736803.jpg?fit=225%2C300&amp;ssl=1\" data-large-file=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/ButtonWiring-e1444085736803.jpg?fit=474%2C632&amp;ssl=1\" loading=\"lazy\" class=\"alignnone size-full wp-image-219\" src=\"https:\/\/i2.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/10\/ButtonWiring-e1444085736803.jpg?resize=474%2C632&#038;ssl=1\" alt=\"ButtonWiring\" width=\"474\" height=\"632\" srcset=\"https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/ButtonWiring-e1444085736803.jpg?w=480&amp;ssl=1 480w, https:\/\/i1.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/10\/ButtonWiring-e1444085736803.jpg?resize=225%2C300&amp;ssl=1 225w\" sizes=\"(max-width: 474px) 100vw, 474px\" data-recalc-dims=\"1\" \/><\/a><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/09\/GPIO-Header.png?ssl=1\"><img data-attachment-id=\"82\" data-permalink=\"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/hc-sr501-sensor\/gpio-header\/\" data-orig-file=\"https:\/\/i2.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/09\/GPIO-Header.png?fit=440%2C870&amp;ssl=1\" data-orig-size=\"440,870\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"GPIO Header\" data-image-description=\"\" data-medium-file=\"https:\/\/i2.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/09\/GPIO-Header.png?fit=152%2C300&amp;ssl=1\" data-large-file=\"https:\/\/i2.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/09\/GPIO-Header.png?fit=440%2C870&amp;ssl=1\" loading=\"lazy\" class=\"size-medium wp-image-82 alignnone\" src=\"https:\/\/i1.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/09\/GPIO-Header-152x300.png?resize=152%2C300&#038;ssl=1\" alt=\"GPIO Header\" width=\"152\" height=\"300\" srcset=\"https:\/\/i2.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/09\/GPIO-Header.png?resize=152%2C300&amp;ssl=1 152w, https:\/\/i2.wp.com\/einhugur.net\/blog\/wp-content\/uploads\/2015\/09\/GPIO-Header.png?w=440&amp;ssl=1 440w\" sizes=\"(max-width: 152px) 100vw, 152px\" data-recalc-dims=\"1\" \/><\/a><\/p>\n<p>So basically red is connected to 3,3 V on the Cobbler, and the other end to the button. From the output of the button we connect the 1K resistor, and from the other end of the button we connect Green which goes from the resistor to the GPIO 6 (which is pin 31) which we choose to use for this example.<\/p>\n<h1><strong>The Xojo code without interupts:<\/strong><\/h1>\n<p>An input gpio will float between 0 and 1 if it&#8217;s not connected to a voltage. So we will need to take care of that by giving it determined state. We do that by using the GPIO.PullUpDnControl function.<\/p>\n<p>The open event of a window:<\/p>\n<pre lang=\"xojo\">Sub Open()\r\nConst kPin = 6\r\n\r\nGPIO.SetupGPIO\r\nGPIO.PinMode(kPin,GPIO.INPUT)\r\nGPIO.PullUpDnControl(kPin,GPIO.PUD_DOWN)\r\n\r\nTimer1.Mode = Timer.ModeMultiple\r\nTimer1.Enabled = true\r\n\r\nEnd Sub<\/pre>\n<p>The timer action event:<\/p>\n<pre lang=\"xojo\">Sub Action()\r\nConst kPin = 6\r\n\r\nfor n as Integer = 1 to 10\r\nif GPIO.DigitalRead(kPin) &lt;&gt; 0 then\r\nListbox1.AddRow \"Button was clicked\"\r\nend if\r\nApp.DoEvents(1)\r\nnext\r\nEnd Sub<\/pre>\n<p>This works&#8230;&#8230; and completes the example without interrupts&#8230;&#8230;<\/p>\n<p>But this is not really great since no matter how tight your timer or loop runs then you will be able to miss clicks.<\/p>\n<h1>So here is how we do it with interrupts:<\/h1>\n<p>When using interrupts then we must be really careful to not call anything from within the interrupt since Xojo does not support that. So the idea is we have a safe function that only logs the interrupt then we poll the log. That way event is never lost and timer or whatever method you use to poll does not need to be very intensive.<\/p>\n<p>First thing is we need to patch Paul&#8217;s GPIO module, adding the following to the module (the function we are adding likely already exists but is not fully implemented so verify that or just blindly override it)\u00a0\u00a0and remember to add the four constants also:<\/p>\n<pre lang=\"xojo\">Protected Const EDGE_FALLING = 1\r\nProtected Const EDGE_BOTH = 3\r\nProtected Const EDGE_RISING = 2\r\nProtected Const EDGE_SETUP = 0\r\n\r\nProtected Function WIringPiISR(pin as integer,edgeType as integer, p as ptr) As Integer\r\n \/\/This function registers a function to received interrupts on the specified pin.\r\n \/\/ The edgeType parameter is either INT_EDGE_FALLING, INT_EDGE_RISING,\r\n \/\/ INT_EDGE_BOTH or INT_EDGE_SETUP. If it is INT_EDGE_SETUP then no\r\n \/\/ initialisation of the pin will happen \u2013 it\u2019s assumed that you have already\r\n \/\/ setup the pin elsewhere (e.g. with the gpio program), but if you specify one\r\n \/\/ of the other types, then the pin will be exported and initialised as specified.\r\n \/\/ This is accomplished via a suitable call to the gpio utility program,\r\n \/\/ so it need to be available.\r\n \/\/\r\n \/\/ The pin number is supplied in the current mode \u2013 native wiringPi, BCM_GPIO,\r\n \/\/ physical or Sys modes.\r\n \/\/\r\n \/\/ This function will work in any mode, and does not need root privileges to work.\r\n \/\/\r\n \/\/ The function will be called when the interrupt triggers.\r\n \/\/ When it is triggered, it\u2019s cleared in the dispatcher before calling your\r\n \/\/ function, so if a subsequent interrupt fires before you finish your handler,\r\n \/\/ then it won\u2019t be missed. (However it can only track one more interrupt,\r\n \/\/ if more than one interrupt fires while one is being handled then they will be ignored)\r\n \/\/\r\n \/\/ This function is run at a high priority (if the program is run\r\n \/\/ using sudo, or as root) and executes concurrently with the main program.\r\n \/\/ It has full access to all the global variables, open file handles and so on.\r\n \/\/\r\n \/\/ See the isr.c example program for more details on how to use this feature.\r\n \r\n \r\n #If TargetARM And TargetLinux Then\r\n Soft Declare Function wpISR Lib \"libwiringPi.so\" Alias \"wiringPiISR\" (pin As Integer, mode As Integer, p as ptr) as Integer\r\n return wpISR(pin, edgeType,p)\r\n #Endif\r\n \r\nEnd Function\r\n\r\n<\/pre>\n<p>Next we create a module which we will call InteruptModule and this module will contain the following things:<\/p>\n<pre lang=\"xojo\">Private DownEventCount As Integer\r\n\r\nProtected Sub ButtonDownInterupt()\r\n \/\/ We need some pragmas here to make this safe since this is called from interupt.\r\n #Pragma StackOverflowChecking False\r\n #Pragma DisableBackgroundTasks\r\n \r\n \/\/ NOTE since we are in interupt then we may not call any methods here it is not safe\r\n \/\/ however we can count the number of occurances and poll this module with a timer or by other means, and by doing that we can be sure that no clicks were missed.\r\n DownEventCount = DownEventCount + 1\r\nEnd Sub\r\n\r\nProtected Function GetDetectedClicks() As Integer\r\n Dim tmp as Integer = DownEventCount\r\n \r\n DownEventCount = 0\r\n return tmp\r\nEnd Function\r\n\r\n<\/pre>\n<p>Then the Window open event will look like this:<\/p>\n<pre lang=\"xojo\">Sub Open()\r\n\r\n Const kPin = 6\r\n \r\n GPIO.SetupGPIO\r\n GPIO.PinMode(kPin,GPIO.INPUT)\r\n GPIO.PullUpDnControl(kPin,GPIO.PUD_DOWN)\r\n \r\n if GPIO.WIringPiISR(kPin,GPIO.EDGE_RISING,Addressof InteruptModule.ButtonDownInterupt) = -1 then\r\n MsgBox \"Could not register interupt for pin number \" + Str(kPin)\r\n end if\r\n \r\n Timer1.Mode = Timer.ModeMultiple\r\n Timer1.Enabled = true\r\n \r\nEnd Sub<\/pre>\n<p>And the timer action event will look like this:<\/p>\n<pre lang=\"xojo\">Sub Action()\r\n  Dim clicks as Integer\r\n \r\n clicks = InteruptModule.GetDetectedClicks()\r\n \r\n if clicks &gt; 0 then\r\n Listbox1.AddRow \"Button was clicked\"\r\n end if\r\nEnd Sub<\/pre>\n<p>No button clicks should ever get missed now.<\/p>\n<p>Thats it for now !<\/p>\n<p><code><br \/>\n<a href=\"http:\/\/s.click.aliexpress.com\/e\/7a2f6URjq\" target=\"_parent\"><img src=\"https:\/\/i2.wp.com\/g02.a.alicdn.com\/kf\/HTB1hI2sIVXXXXa4XVXXq6xXFXXXy\/For-Arduino-Starter-Kit-Electronic-Fans-Kits-font-b-Breadboard-b-font-Cable-Resistor-Capacitor-LED.jpg_220x220.jpg?w=474\" data-recalc-dims=\"1\" \/><span style=\"display: block;\">AliExpress.com Product - Electronic Fans Kit Breadboard Cable Resistor Capacitor LED Potentiometer for Arduino FZ0869<\/span><\/a><br \/>\n<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this example we are going to connect the Raspberry PI with a button, and then make \u00a0Xojo programs where the first one will read from the button without\u00a0interrupts and\u00a0the second will be doing the same using interrupts. Disclaimer: We do not take any responsibility for possible errors in the guide or errors that you &hellip; <a href=\"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/connecting-button-with-gpio-and-using-interupts\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Connecting Button with GPIO and using interupts<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":94,"menu_order":100,"comment_status":"open","ping_status":"closed","template":"","meta":{"spay_email":""},"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/Pd75nk-3q","jetpack-related-posts":[{"id":288,"url":"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/connecting-max7219_led_matrix-with-spi-bus\/","url_meta":{"origin":212,"position":0},"title":"Connecting MAX7219_LED_MATRIX with SPI bus","date":"October 21, 2015","format":false,"excerpt":"In this example we going to connect a\u00a0MAX7219_LED_MATRIX and control it with the SPI bus on the Raspberry PI. 8. Nov 2015 Important !! When I was working on next step in this to daisy chain more than one on same bus then I measured some extreme power usage at\u2026","rel":"","context":"Similar post","img":{"alt_text":"MAX7219_LED_MATRIX","src":"https:\/\/i2.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/10\/MAX7219_LED_MATRIX-e1445384705632.jpg?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":191,"url":"https:\/\/einhugur.net\/blog\/index.php\/basic-electronics\/understanding-your-breadboard-and-placement-of-raspberry-cobbler\/","url_meta":{"origin":212,"position":1},"title":"Understanding your breadboard and placement of Raspberry cobbler","date":"September 22, 2015","format":false,"excerpt":"Its important to understand how your breadboard is internally wired before you start using it to wire things up. If we take breadboard like this: Then its internal wiring will look like this: Notice that the numbered rows are all connected from a, b, c, d to e, but not\u2026","rel":"","context":"Similar post","img":{"alt_text":"Small breadboard","src":"https:\/\/i0.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/09\/BrewadboardSmall.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":108,"url":"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/f85-vibration-sensor\/","url_meta":{"origin":212,"position":2},"title":"F85 Vibration sensor","date":"September 19, 2015","format":false,"excerpt":"In this example we are going to connect to\u00a0vibration sensor. This example is super easy after doing the infrared motion detection with the HC-SR501 in a previous example, since basically same code will work. I found this sensor to be excellent, it gives readings when I expect it to and\u2026","rel":"","context":"Similar post","img":{"alt_text":"","src":"https:\/\/i1.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/09\/Sensor-connection-e1442664059628-225x300.jpg?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":840,"url":"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/rdm6300-125khz-rfid-reader\/","url_meta":{"origin":212,"position":3},"title":"RDM6300 125Khz RFID reader","date":"April 13, 2017","format":false,"excerpt":"In this example we are going to connect to RDM6300 RFID reader. The RDM6300\u00a0is for 125 kHz RF tags. This board uses UART (serial communication) but the protocol is fairly simple to deal with. The RDM6300 seen from back and front And the antenna that comes with it. Disclaimer: We\u2026","rel":"","context":"Similar post","img":{"alt_text":"","src":"https:\/\/i1.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2017\/04\/RFID125MainBoard.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":137,"url":"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/ir-infrared-obstacle-reflection-photoelectric-sensor\/","url_meta":{"origin":212,"position":4},"title":"IR Infrared Obstacle Reflection Photoelectric Sensor","date":"September 20, 2015","format":false,"excerpt":"In this example we are going to connect to infrared obstacle reflection photoelectric sensor motion detection sensor. I am not going to deny it, I find this sensor to be awful rubbish. Without reading the data you can hook it up and see it when the 2nd green lights goes\u2026","rel":"","context":"Similar post","img":{"alt_text":"","src":"https:\/\/i0.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/09\/IRSensor-e1442754741492-225x300.jpg?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":113,"url":"https:\/\/einhugur.net\/blog\/index.php\/xojo-gpio\/flame-sensor\/","url_meta":{"origin":212,"position":5},"title":"Flame sensor","date":"September 19, 2015","format":false,"excerpt":"In this example we are going to connect to flame\u00a0sensor. Programming for this sensor works on exactly the same principle as the\u00a0HC-SR501 infrared sensor and the F85 vibration sensor except the signal from this sensor comes inverted. As in it will send 1 when everything is all right and zero\u2026","rel":"","context":"Similar post","img":{"alt_text":"","src":"https:\/\/i0.wp.com\/einhugur.com\/blog\/wp-content\/uploads\/2015\/09\/FlameSensor-e1442681877884-225x300.jpg?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]}],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/pages\/212"}],"collection":[{"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=212"}],"version-history":[{"count":11,"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/pages\/212\/revisions"}],"predecessor-version":[{"id":479,"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/pages\/212\/revisions\/479"}],"up":[{"embeddable":true,"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/pages\/94"}],"wp:attachment":[{"href":"https:\/\/einhugur.net\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=212"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}