[L2Ork-dev] 2 SPI slaves in RbPi2

Ivica Ico Bukvic ico at vt.edu
Thu Jul 9 09:49:21 UTC 2015


Thank you for the follow-up, Luis. If I understand you correctly, does 
the disis_spi therefore work for at least 16 channels (via opening 2 
devices, 8 channels each) or it does not work at all?

disis_spi has its own implementation of accessing spidevs, and (AFAIR) 
it should not have any limitations as far as how many devices can be 
opened at once (obviously, you will need one instance per device). 
Perhaps the limitation you speak of is hardware-specific?

Best,

Ico

On 7/9/2015 3:42 AM, Luis Gerardo Angel S. wrote:
> Hi
>
> I probe the program, you were right you can specify the device and it 
> just work(attached example).
> The controller have 3 chip selectors for the SPI (three slaves), 
> although you can only connect two devices according to this: 
> http://elinux.org/RPi_SPI. You can confirm it with "ls /dev" command, 
> there are only two SPI devices.
> I read in some forum (can't remember which ones) this is due to how 
> the library was written leaving out the third chip selector.
>
>  At the present time the only way to connect more SPI devices is: 
> write your own SPI library (maybe with wiringPi) and use the GPIO's 
> general purpose(pardon the redundancy) pins like selectors. It would 
> be nice we can use the third selector with another "/dev/spidev0.2" in 
> that way the external does not have to be modified and 24 analog 
> inputs would be very good.
>
> Luis G
>
> On mié, jul 8, 2015 at 3:49 , Ivica Ico Bukvic <ico at vt.edu> wrote:
>> Hi Luis, I am not 100% sure but if I recall correctly, you can 
>> specify which device you wish to open, so as long as each device is 
>> assigned a different /dev node, this should work just fine. I would 
>> appreciate it if you would please report your results and let us 
>> know. Alternately, there are larger D/A converters that provide you 
>> with more inputs, but will also require a customized version of 
>> disis_spi. Hope this helps! Best, Ico On 7/7/2015 11:41 PM, Luis G 
>> Angel wrote:
>>
>>     Hi list I want to use two MCP3008 in order to connect 16 analog
>>     inputs to the Pi2, so my question is if the [disis_spi] is
>>     capable to manage 2 slaves. If it is, how it should be the patch
>>     to manage that. Thanks for any idea Luis G
>>     _______________________________________________ L2Ork-dev mailing
>>     list L2Ork-dev at disis.music.vt.edu
>>     http://disis.music.vt.edu/listinfo/l2ork-dev 
>>
>> -- 
>> Ivica Ico Bukvic, D.M.A. Associate Professor Computer Music ICAT 
>> Senior Fellow Director -- DISIS, L2Ork Virginia Tech School of 
>> Performing Arts – 0141 Blacksburg, VA 24061 (540) 231-6139 ico at vt.edu 
>> www.performingarts.vt.edu <http://www.performingarts.vt.edu> 
>> disis.icat.vt.edu l2ork.icat.vt.edu 
>> _______________________________________________ L2Ork-dev mailing 
>> list L2Ork-dev at disis.music.vt.edu 
>> http://disis.music.vt.edu/listinfo/l2ork-dev

-- 
Ivica Ico Bukvic, D.M.A.
Associate Professor
Computer Music
ICAT Senior Fellow
Director -- DISIS, L2Ork
Virginia Tech
School of Performing Arts – 0141
Blacksburg, VA 24061
(540) 231-6139
ico at vt.edu
www.performingarts.vt.edu
disis.icat.vt.edu
l2ork.icat.vt.edu

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://disis.music.vt.edu/pipermail/l2ork-dev/attachments/20150709/5726d1f3/attachment.html>


More information about the L2Ork-dev mailing list