Power & Source of Big Ideas

Enable 2nd SPI Device and Interrupt

Moderators: chensy, FATechsupport

I am using lubuntu with S5P4418 development board. I am successfully using SPI 0.0 as a Master and working.

Problem 1 - I want to use SPI 0.2 as a Slave but device is disabled from Kernal. How to enable it ?

Problem 2 - I want to use Interrupt but Kernal files are used as zImage and unable to change it. How to add Interrupt ?

npi-config utility is not working.


Regards.
Hi,

if you want to enable SPI0.2 please add following config in arch/arm/boot/dts/s5p4418-nanopi2-common.dtsi.
Example:

&spi_2 {
status = "okay";
cs-gpios = <&gpio_c 10 0>;

spidev0: spidev@0 {
status = "okay";
compatible = "linux,spidev";
pl022,hierarchy = <0>;
pl022,com-mode = <0>;
pl022,interface = <0>;
pl022,rx-level-trig = <1>;
pl022,tx-level-trig = <1>;
reg = <0>;
spi-max-frequency = <10000000>;
};
};

Next recompile kernel and use new bzImage and dtb file.
greg2k wrote:
Hi,

if you want to enable SPI0.2 please add following config in arch/arm/boot/dts/s5p4418-nanopi2-common.dtsi.
Example:

&spi_2 {
status = "okay";
cs-gpios = <&gpio_c 10 0>;

spidev0: spidev@0 {
status = "okay";
compatible = "linux,spidev";
pl022,hierarchy = <0>;
pl022,com-mode = <0>;
pl022,interface = <0>;
pl022,rx-level-trig = <1>;
pl022,tx-level-trig = <1>;
reg = <0>;
spi-max-frequency = <10000000>;
};
};

Next recompile kernel and use new bzImage and dtb file.




Hii,

I want to access a DAC chip over Spi could you please suggest me how can I achieve that .

Who is online

In total there are 3 users online :: 0 registered, 0 hidden and 3 guests (based on users active over the past 5 minutes)
Most users ever online was 5185 on Wed Jan 22, 2020 1:44 pm

Users browsing this forum: No registered users and 3 guests