Commit abbe18c353c297a40c428ba92f3e1a85e8e694fc

Authored by Minkyu Kang
Committed by trix
1 parent ab693e9c4c

s5pc1xx: update the README file

Because adds support the GPIO Interface, README file is updated.

Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>

Showing 1 changed file with 17 additions and 1 deletions Side-by-side Diff

... ... @@ -41,7 +41,23 @@
41 41 printf("cpu is s5pc110\n");
42 42  
43 43 gpio
44   - not supported yet.
  44 +
  45 + struct s5pc100_gpio *gpio = (struct s5pc100_gpio*)S5PC100_GPIO_BASE;
  46 +
  47 + /* GPA[0] pin set to irq */
  48 + gpio_cfg_pin(&gpio->gpio_a, 0, GPIO_IRQ);
  49 +
  50 + /* GPA[0] pin set to input */
  51 + gpio_direction_input(&gpio->gpio_a, 0);
  52 +
  53 + /* GPA[0] pin set to output/high */
  54 + gpio_direction_output(&gpio->gpio_a, 0, 1);
  55 +
  56 + /* GPA[0] value set to low */
  57 + gpio_set_value(&gpio->gpio_a, 0, 0);
  58 +
  59 + /* get GPA[0] value */
  60 + value = gpio_get_value(&gpio->gpio_a, 0);
45 61  
46 62 Links
47 63 =====