If you're using Overo with the 40-pin header a safe bet for your two input lines is:
Pin 27 - gpio146
Pin 29 - gpio147
Per the first section of the wiki:
1)Export them to userspace
2)Set direction to "in"
3)Verify state with "echo"
These two pins are floating, so pull them low to get "0". Pin 1 can be used as a ground.
Apply 1.8V to get "1".
From: Nick Starzicki <firstname.lastname@example.org>
To: General mailing list for gumstix users. <email@example.com>; Greg Kogut
Sent: Tuesday, December 6, 2011 12:11 PM
Subject: Re: [Gumstix-users] GPIO
And how do i know the port numbers which are available as input?
בתאריך 2011 12 6 21:30, מאת