adding gpio_read method