I used the gpio to do the spi's work .If i used the pin to control the led, pin hight sleep(1) and low sleep(1). That's ok

But change sleep(1) by usleep(1). The wave is very bad . 

     I do this on linux user space .Use the mmap()  remap address .

Configure the pinmux first. And read the clock is right 0x8003,read the psc1->mdctl[3]=3

gpio_init(){ set dir is output} pin hight is set OUT_DATA|=0X00000001 low is set OUT_DATA&=~0X00000001;

Waiting for reply....