1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2025-04-21 12:27:27 +03:00

atusb/fw/: new request ATUSB_GPIO_CLEANUP to re-enable INT0

- board.h (gpio_cleanup), board_app.c (gpio_cleanup): restore INT0
  when done manipulating GPIOs
- board.c (gpio): updated comment explaining how to restore INT0
- include/atusb/ep0.h (enum atspi_requests), ep0.c
  (ATUSB_GPIO_CLEANUP): new request to return to normal operation
  after ATUSB_GPIO
This commit is contained in:
Werner Almesberger
2011-06-20 23:11:09 -03:00
parent f8f2f890d9
commit f7b9a18917
4 changed files with 13 additions and 1 deletions

View File

@@ -125,6 +125,9 @@ static int my_setup(const struct setup_request *setup)
return 0;
usb_send(&eps[0], buf, 3, NULL, NULL);
return 1;
case ATUSB_TO_DEV(ATUSB_GPIO_CLEANUP):
gpio_cleanup();
return 1;
case ATUSB_TO_DEV(ATUSB_SLP_TR):
debug("ATUSB_SLP_TR\n");