Hello,
I am having trouble getting the Linux GPIO driver to work and was hoping that someone could point out what I am doing wrong. I am trying to control pin GP025, which I believe is not muxed with any other pin. I have the following simple module code…
status= gpio_request(25, "gpio");
printk(KERN_INFO "GPIO 25 request status = %d\n", status);
status = gpio_is_valid(25);
printk(KERN_INFO "GPIO 25 is valid = %d\n", status);
status = gpio_direction_output(25, 1);
printk(KERN_INFO "GPIO 25 set status = %d\n", status);
gpio_set_value(25, 1);
All the status comes back ok, but the pin does not go high. I have also tried to control pin 6, with basically the same code (except for 6) and have configured the pin in the mux code for IO. I have also enabled the sys/class/gpio interface and tried using it, but still no luck.
Do I need to enable the GPIO model somewhere in the kernel? If so where would be the place to put this? It is not obvious to me where other modules are being enabled/ taken out of sleep.
Any ideas would be appreciated. Thanks for the help…
FYI: Using ti-ezsdk-dm816x-evm_5_01_00_77