deleted comment
pull in some more code from mbed
ok, fixed read pin crash...
the mbed code shouldn't be necessary