hi ashkar,
i understand u r trying to do spi bit banging. i suggest u to read SPI protocol first. and please recheck the Din which u have used is for data
receive or transmit. usually it will be used to receive data. pls post ur circuit diagram for better clarity..
finally when u do bit banging, u have to transmit data bit by bit. dont assign z=config. i think u are keeping the clock low and trying to transmit complete byte, which will not happen. when u pulse a clock only one bit can be transmitted.
thanks and regards,
karthikkr
- - - Updated - - -
keil has lot of examples related to SPI bit banging.. please refer them too