2011-04-27 02:51:02     bf518 SPI chip_select

Document created by Aaronwu Employee on Aug 26, 2013
Version 1Show Document
  • View in full screen mode

2011-04-27 02:51:02     bf518 SPI chip_select

Bingo Cui (CHINA)

Message: 100185   


hi,Aaron Wu








  .modalias = "spidev",

  .max_speed_hz = 3125000,     /* max spi clock (SCK) speed in HZ */

  .bus_num = 1,

  .chip_select = 1,

  .controller_data = &spidev_chip_info,



将chip_select = 1时,SPISEL1是片选信号脚;

将chip_select = 3时,SPISEL2是片选信号脚;






2011-04-27 03:12:18     Re: bf518 SPI chip_select

Aaron Wu (CHINA)

Message: 100186   


chip_select indicates which hardware chipselect PIN you are using for your SPI device. We have 7 hardware chipselect PINs for each of the SPI controller in BF518, there are two SPI controller on the BF518 in total. bus_num indicates which SPI controller you are using, range from 0 to 1, representing Controller 0 and Controller 1.  For which bus_num and chip_select value to use in your case you need to check your board schematic, please take our default ezbrd schematic and ezbrd.c for reference, if your schematic changes, then change your code accordingly.  




2011-04-27 03:17:51     Re: bf518 SPI chip_select

Aaron Wu (CHINA)

Message: 100190   


By the way, SPISS PIN can not be used as the SPI chipselect if BF518 is going to act like master (actually in your product it is). SPISS is an input, acts as the active low enablement signal for the BF518 to act as SPI slave.




2011-04-27 03:27:21     Re: bf518 SPI chip_select

Bingo Cui (CHINA)

Message: 100195   


thanks a lot for your help.