Re: [beagleboard] Re: Confused with BB-SPI1-01-00A0.dts example
On Tuesday, July 7, 2015 at 8:34:12 AM UTC-3, J Evans wrote: Can you share a complete copy of your DTS file? Thx. Here you go. It's the same as the one here http://elinux.org/BeagleBone_Black_Enable_SPIDEV#SPI1_D1_Output_and_D0_Input, except for the 4 pinmux register values. -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups BeagleBoard group. To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. /dts-v1/; /plugin/; /* SPI1 */ /* D1 Output and D0 Input */ / { compatible = ti,beaglebone, ti,beaglebone-black; /* identification */ part-number = spi1mux; fragment@0 { target = am33xx_pinmux; __overlay__ { spi1_pins_s0: spi1_pins_s0 { pinctrl-single,pins = 0x190 0x2b /* mcasp0_aclkx.spi1_sclk, RXACTIVE | Pull-down disabled | MODE3 */ 0x194 0x33 /* mcasp0_fsx.spi1_d0, INPUT_PULLUP | MODE3 */ 0x198 0x1b /* mcasp0_axr0.spi1_d1, Pull-up disabled | MODE3 */ 0x19c 0x1b /* mcasp0_ahclkr.spi1_cs0, Pull-up disabled | MODE3 */ ; }; }; }; fragment@1 { target = spi1; __overlay__ { #address-cells = 1; #size-cells = 0; status = okay; pinctrl-names = default; pinctrl-0 = spi1_pins_s0; spidev@1 { spi-max-frequency = 2400; reg = 0; compatible = linux,spidev; }; }; }; };
RE: [beagleboard] Re: Confused with BB-SPI1-01-00A0.dts example
Hello Emile It turns out that reading from D0 doesn't work unless RXACTIVE=1 for the SCLK signal. This comment from hipstercircuits confirms this. That answers my question #1. In now have this in my dts file, and both reading and writing seem to work ok: pinctrl-single,pins = 0x190 0x2b /* mcasp0_aclkx.spi1_sclk, RXACTIVE | Pull-down disabled | MODE3 */ 0x194 0x33 /* mcasp0_fsx.spi1_d0, INPUT_PULLUP | MODE3 */ 0x198 0x1b /* mcasp0_axr0.spi1_d1, Pull-up disabled | MODE3 */ 0x19c 0x1b /* mcasp0_ahclkr.spi1_cs0, Pull-up disabled | MODE3 */ Can you share a complete copy of your DTS file? Thx. -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups BeagleBoard group. To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[beagleboard] Re: Confused with BB-SPI1-01-00A0.dts example
I tried changing it as follows: - mcasp0_aclkx.spi1_sclk: RXACTIVE=0 (Receiver disabled) - Disabled pullups on mcasp0_aclkx.spi1_sclk, mcasp0_axr0.spi1_d1, and mcasp0_ahclkr.spi1_cs0 So the relevant section in the BB-SPI1-01-00A0.dts file now looks like: pinctrl-single,pins = 0x190 0x0b /* mcasp0_aclkx.spi1_sclk, Pull-down disabled | MODE3 */ 0x194 0x33 /* mcasp0_fsx.spi1_d0, INPUT_PULLUP | MODE3 */ 0x198 0x1b /* mcasp0_axr0.spi1_d1, Pull-up disabled | MODE3 */ 0x19c 0x1b /* mcasp0_ahclkr.spi1_cs0, Pull-up disabled | MODE3 */ And everything seems to work fine (note that I'm currently not able to test reading from SPI). -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups BeagleBoard group. To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.