I am trying to control a motor with variable speed using a16c84.  I have pu
rchased a IRF9530 p-channel MOSFET to control the motor. I am having problems ge
tting the motor to switch on or off let alone have variable speed.  I know that
i will have to create PWM to variy the speed, but i would have  thought that i s
hould be able to switch the mosfet by logic 1 or 0.

It is all connected as follows:
 gate porta-0
 source 5v
 drain to motor
Am i being a complete tit ?
Aaron