无法驱动屏幕,用示波器测了MOSI CLK DC 那些引脚在写屏幕的时候都有波形。
硬件是淘宝买的创思通讯的板子。
同一个硬件3.x内核可以驱动屏幕,4.x无法驱动屏幕
dmesg中有打印信息:
[ 1.260290] fbtft_of_value: buswidth = 8
[ 1.264254] fbtft_of_value: debug = 1
[ 1.267912] fbtft_of_value: fps = 30
[ 1.271804] fb_ili9340 spi0.0: fbtft_request_one_gpio: 'reset-gpios' = GPIO145
[ 1.279176] fb_ili9340 spi0.0: fbtft_request_one_gpio: 'dc-gpios' = GPIO144
[ 1.330803] mmc0: host does not support reading read-only switch, assuming write-enable
[ 1.340769] mmc0: new high speed SDHC card at address 5048
[ 1.346925] mmcblk0: mmc0:5048 SD32G 28.9 GiB
[ 1.353149] mmcblk0: p1 p2
[ 1.574227] Console: switching to colour frame buffer device 30x40
[ 1.581132] graphics fb0: fb_ili9340 frame buffer, 240x320, 150 KiB video memory, 4 KiB buffer memory, fps=33, spi0.0 at 50 MHz
请大佬们指点迷津
离线
9bit or 8bit?
逻辑分析仪比较一下,分分钟搞定。
&spi0 {
status = "okay";
ili9341@0 {
compatible = "ilitek,ili9341";
reg = <0>;
spi-max-frequency = <50000000>;
//rotate = <270>;
bgr;
fps = <20>;
buswidth = <8>;
reset-gpios = <&pio 4 17 GPIO_ACTIVE_LOW>;
dc-gpios = <&pio 4 16 GPIO_ACTIVE_LOW>;
#address-cells = <1>;
#size-cells = <1>;
debug = <1>;
};
};
设备树描述如下
离线
解决了 打死都想不到加个上拉电阻就行了。。。
离线
就只是在clk上拉个100K电阻就ok了
离线