px4io: ensure upload device is closed after use

this should release it for PWM use