Hi,
hast du unter Bascom den Pin auch als Ausgang definiert ?
config Pind.2 =Output
portd.2=0

Gruß
Christopher