asmallri
Joined: 12 Aug 2004 Posts: 1635 Location: Perth, Australia
|
|
Posted: Thu Feb 26, 2009 6:42 pm |
|
|
If you do not need to access both devices concurrently then you can use a single SPI bus to do this. It just means you need to initialize the SPI as part of the process for selecting each device.
The process for all PICs is deselect all devices, stop the SPI bus, change the SPI configuration, clear the SPI interrupt flag, enable the SPI bus, select the sensor, communicate with the sensor.... _________________ Regards, Andrew
http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!! |
|