我手头有一块4.3存液晶屏,480x272分辨率,v3s应该是支持的。
就目前我在uboot的menuconfig中配置了
CONFIG_VIDEO_LCD_MODE="x:480,y:272,depth:18,pclk_khz:100000,le:40,ri:5,up:8,lo:8,hs:1,vs:1,sync:3,vmode:0"
然后,在boot.cmd中使能了tty0了,
setenv bootargs console=ttyS0,115200 panic=5 console=tty0 rootwait root=/dev/mmcblk0p2 earlyprintk rw
光是这样,好像还是不够,uboot和kernel的设备树中是否还需要额外的操作?怎么搞,大神们能传授一下经验吗?不甚感激啊
离线
现在有什么问题?
480x272是支持的, 修改CONFIG_VIDEO_LCD_MODE就可以了,
这个参数会传给内核设备树dtb.
现在的问题就是,液晶没反应。。。
这个是我编译出来的uboot==》https://whycan.cn/files/members/421/uboot.zip
在我这里液晶屏幕没有反应,手上也没有别的液晶了,想确认一下是否是我的液晶屏幕有问题
离线
1. 首先确认的液晶是否是好的,有没有别的板子可以测试?
2. 检查排线是否插好,液晶的背光有没有亮?金属边框侧边仔细看,如果背光点亮会有漏光的。
背光是亮的。
晕哥,你能给我一份你编译过的二进制程序吗,我烧一下看一下能不能显示界面
离线
离线
以下是uboot和kernel启动后的输出信息,能看出什么端倪吗?
U-Boot 2017.01-rc2 suda-morris (Jan 21 2018 - 20:17:47 +0800) Allwinner Technology
CPU: Allwinner V3s (SUN8I 1681)
Model: Lichee Pi Zero
DRAM: 64 MiB
MMC: SUNXI SD/MMC: 0
SF: Detected w25q128bv with page size 256 Bytes, erase size 4 KiB, total 16 MiB
*** Warning - bad CRC, using default environment
Setting up a 480x272 lcd console (overscan 0x0)
dotclock: 10000kHz = 10000kHz: (1 * 3MHz * 20) / 6
In: serial@01c28000
Out: serial@01c28000
Err: serial@01c28000
Net: phy interface0
eth0: ethernet@1c30000
starting USB...
No controllers found
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1...
Found U-Boot script /boot.scr
reading /boot.scr
305 bytes read in 14 ms (20.5 KiB/s)
## Executing script at 41900000
reading zImage
3948464 bytes read in 220 ms (17.1 MiB/s)
reading sun8i-v3s-suda.dtb
11393 bytes read in 26 ms (427.7 KiB/s)
## Flattened Device Tree blob at 41800000
Booting using the fdt blob at 0x41800000
Loading Device Tree to 42dfa000, end 42dffc80 ... OK
Starting kernel ...
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 4.13.0-licheepi-zero (morris@morris) (gcc version 6.4.1 20171012 (Linaro GCC 6.4-2017.11)) #1 SMP Sat Jan 13 18
[ 0.000000] CPU: ARMv7 Processor [410fc075] revision 5 (ARMv7), cr=10c5387d
[ 0.000000] CPU: div instructions available: patching division code
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[ 0.000000] OF: fdt: Machine model: Lichee Pi Zero
[ 0.000000] Memory policy: Data cache writealloc
[ 0.000000] percpu: Embedded 16 pages/cpu @c3edf000 s33868 r8192 d23476 u65536
[ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 16129
[ 0.000000] Kernel command line: console=ttyS0,115200 panic=5 console=tty0 rootwait root=/dev/mmcblk0p2 earlyprintk rw vt.global_cursor_0
[ 0.000000] PID hash table entries: 256 (order: -2, 1024 bytes)
[ 0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
[ 0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
[ 0.000000] Memory: 54576K/65024K available (6144K kernel code, 217K rwdata, 1436K rodata, 1024K init, 262K bss, 10448K reserved, 0K cma)
[ 0.000000] Virtual kernel memory layout:
[ 0.000000] vector : 0xffff0000 - 0xffff1000 ( 4 kB)
[ 0.000000] fixmap : 0xffc00000 - 0xfff00000 (3072 kB)
[ 0.000000] vmalloc : 0xc4000000 - 0xff800000 ( 952 MB)
[ 0.000000] lowmem : 0xc0000000 - 0xc3f80000 ( 63 MB)
[ 0.000000] pkmap : 0xbfe00000 - 0xc0000000 ( 2 MB)
[ 0.000000] modules : 0xbf000000 - 0xbfe00000 ( 14 MB)
[ 0.000000] .text : 0xc0008000 - 0xc0700000 (7136 kB)
[ 0.000000] .init : 0xc0900000 - 0xc0a00000 (1024 kB)
[ 0.000000] .data : 0xc0a00000 - 0xc0a36680 ( 218 kB)
[ 0.000000] .bss : 0xc0a3d868 - 0xc0a7f06c ( 263 kB)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] RCU event tracing is enabled.
[ 0.000000] RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
[ 0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[ 0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[ 0.000000] arch_timer: cp15 timer(s) running at 24.00MHz (virt).
[ 0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns
[ 0.000008] sched_clock: 56 bits at 24MHz, resolution 41ns, wraps every 4398046511097ns
[ 0.000021] Switching to timer-based delay loop, resolution 41ns
[ 0.000183] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[ 0.000412] Console: colour dummy device 80x30
[ 0.000836] console [tty0] enabled
[ 0.000875] Calibrating delay loop (skipped), value calculated using timer frequency.. 48.00 BogoMIPS (lpj=240000)
[ 0.000913] pid_max: default: 32768 minimum: 301
[ 0.001054] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.001087] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.001705] CPU: Testing write buffer coherency: ok
[ 0.002094] /cpus/cpu@0 missing clock-frequency property
[ 0.002140] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[ 0.002609] Setting up static identity map for 0x40100000 - 0x40100060
[ 0.002813] Hierarchical SRCU implementation.
[ 0.003342] smp: Bringing up secondary CPUs ...
[ 0.003375] smp: Brought up 1 node, 1 CPU
[ 0.003395] SMP: Total of 1 processors activated (48.00 BogoMIPS).
[ 0.003416] CPU: All CPU(s) started in SVC mode.
[ 0.004191] devtmpfs: initialized
[ 0.007204] VFP support v0.3: implementor 41 architecture 2 part 30 variant 7 rev 5
[ 0.007498] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[ 0.007560] futex hash table entries: 256 (order: 2, 16384 bytes)
[ 0.007742] pinctrl core: initialized pinctrl subsystem
[ 0.008637] random: get_random_u32 called from bucket_table_alloc+0xf4/0x244 with crng_init=0
[ 0.008811] NET: Registered protocol family 16
[ 0.009287] DMA: preallocated 256 KiB pool for atomic coherent allocations
[ 0.010534] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
[ 0.010585] hw-breakpoint: maximum watchpoint size is 8 bytes.
[ 0.023682] SCSI subsystem initialized
[ 0.024017] usbcore: registered new interface driver usbfs
[ 0.024099] usbcore: registered new interface driver hub
[ 0.024210] usbcore: registered new device driver usb
[ 0.024486] pps_core: LinuxPPS API ver. 1 registered
[ 0.024512] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[ 0.024560] PTP clock support registered
[ 0.024800] Advanced Linux Sound Architecture Driver Initialized.
[ 0.026641] clocksource: Switched to clocksource arch_sys_counter
[ 0.037591] NET: Registered protocol family 2
[ 0.038211] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.038272] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.038310] TCP: Hash tables configured (established 1024 bind 1024)
[ 0.038453] UDP hash table entries: 256 (order: 1, 8192 bytes)
[ 0.038517] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[ 0.038746] NET: Registered protocol family 1
[ 0.039345] RPC: Registered named UNIX socket transport module.
[ 0.039391] RPC: Registered udp transport module.
[ 0.039409] RPC: Registered tcp transport module.
[ 0.039428] RPC: Registered tcp NFSv4.1 backchannel transport module.
[ 0.041567] workingset: timestamp_bits=30 max_order=14 bucket_order=0
[ 0.050571] NFS: Registering the id_resolver key type
[ 0.050652] Key type id_resolver registered
[ 0.050672] Key type id_legacy registered
[ 0.051705] random: fast init done
[ 0.054690] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 249)
[ 0.054745] io scheduler noop registered
[ 0.054764] io scheduler deadline registered
[ 0.055035] io scheduler cfq registered (default)
[ 0.055062] io scheduler mq-deadline registered
[ 0.055079] io scheduler kyber registered
[ 0.059523] sun8i-v3s-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver
[ 0.128836] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[ 0.132260] console [ttyS0] disabled
[ 0.152567] 1c28000.serial: ttyS0 at MMIO 0x1c28000 (irq = 35, base_baud = 1500000) is a U6_16550A
[ 0.734998] console [ttyS0] enabled
[ 0.741900] libphy: Fixed MDIO Bus: probed
[ 0.746461] dwmac-sun8i 1c30000.ethernet: PTP uses main clock
[ 0.752375] dwmac-sun8i 1c30000.ethernet: No regulator found
[ 0.758137] dwmac-sun8i 1c30000.ethernet: Will use internal PHY
[ 0.764146] dwmac-sun8i 1c30000.ethernet: Current syscon value is not the default 148000 (expect 38000)
[ 0.773750] dwmac-sun8i 1c30000.ethernet: Chain mode enabled
[ 0.779450] dwmac-sun8i 1c30000.ethernet: No HW DMA feature register supported
[ 0.786698] dwmac-sun8i 1c30000.ethernet: Normal descriptors
[ 0.792363] dwmac-sun8i 1c30000.ethernet: RX Checksum Offload Engine supported
[ 0.799607] dwmac-sun8i 1c30000.ethernet: COE Type 2
[ 0.804578] dwmac-sun8i 1c30000.ethernet: TX Checksum insertion supported
[ 0.811571] libphy: stmmac: probed
[ 0.816939] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 0.823502] ehci-platform: EHCI generic platform driver
[ 0.829084] ehci-platform 1c1a000.usb: EHCI Host Controller
[ 0.834722] ehci-platform 1c1a000.usb: new USB bus registered, assigned bus number 1
[ 0.842732] ehci-platform 1c1a000.usb: irq 25, io mem 0x01c1a000
[ 0.876664] ehci-platform 1c1a000.usb: USB 2.0 started, EHCI 1.00
[ 0.883845] hub 1-0:1.0: USB hub found
[ 0.887839] hub 1-0:1.0: 1 port detected
[ 0.892346] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[ 0.898665] ohci-platform: OHCI generic platform driver
[ 0.904223] ohci-platform 1c1a400.usb: Generic Platform OHCI controller
[ 0.910969] ohci-platform 1c1a400.usb: new USB bus registered, assigned bus number 2
[ 0.918982] ohci-platform 1c1a400.usb: irq 26, io mem 0x01c1a400
[ 0.991737] hub 2-0:1.0: USB hub found
[ 0.995593] hub 2-0:1.0: 1 port detected
[ 1.003220] udc-core: couldn't find an available UDC - added [g_cdc] to list of pending drivers
[ 1.012810] input: 1c22800.lradc as /devices/platform/soc/1c22800.lradc/input/input0
[ 1.021814] sun6i-rtc 1c20400.rtc: rtc core: registered rtc-sun6i as rtc0
[ 1.028745] sun6i-rtc 1c20400.rtc: RTC enabled
[ 1.033306] i2c /dev entries driver
[ 1.038537] sunxi-wdt 1c20ca0.watchdog: Watchdog enabled (timeout=16 sec, nowayout=0)
[ 1.106891] sunxi-mmc 1c0f000.mmc: base:0xc4101000 irq:23
[ 1.114025] usbcore: registered new interface driver usbhid
[ 1.119721] usbhid: USB HID core driver
[ 1.125171] sun4i-codec 1c22c00.codec: ASoC: /soc/codec-analog@01c23000 not registered
[ 1.133252] sun4i-codec 1c22c00.codec: Failed to register our card
[ 1.140822] NET: Registered protocol family 17
[ 1.145420] Key type dns_resolver registered
[ 1.149960] Registering SWP/SWPB emulation handler
[ 1.162501] simple-framebuffer 43f80000.framebuffer: framebuffer at 0x43f80000, 0x7f800 bytes, mapped to 0xc4300000
[ 1.173168] simple-framebuffer 43f80000.framebuffer: format=x8r8g8b8, mode=480x272x32, linelength=1920
[ 1.185424] Console: switching to colour frame buffer device 60x34
[ 1.193969] simple-framebuffer 43f80000.framebuffer: fb0: simplefb registered!
[ 1.202597] usb_phy_generic usb_phy_generic.0.auto: usb_phy_generic.0.auto supply vcc not found, using dummy regulator
[ 1.219547] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
[ 1.229130] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 3
[ 1.243295] hub 3-0:1.0: USB hub found
[ 1.251312] hub 3-0:1.0: 1 port detected
[ 1.258304] using random self ethernet address
[ 1.264644] using random host ethernet address
[ 1.271978] usb0: HOST MAC 2e:ed:c5:f6:f3:35
[ 1.278203] usb0: MAC 1a:f6:d2:6e:02:02
[ 1.283869] g_cdc gadget: CDC Composite Gadget, version: King Kamehameha Day 2008
[ 1.294942] g_cdc gadget: g_cdc ready
[ 1.302978] sun4i-codec 1c22c00.codec: Codec <-> 1c22c00.codec mapping ok
[ 1.315105] sun6i-rtc 1c20400.rtc: setting system clock to 1970-01-02 06:21:01 UTC (109261)
[ 1.327447] vcc5v0: disabling
[ 1.332206] ALSA device list:
[ 1.336951] #0: V3s Audio Codec
[ 1.342358] Waiting for root device /dev/mmcblk0p2...
[ 1.359815] mmc0: host does not support reading read-only switch, assuming write-enable
[ 1.375330] mmc0: new high speed SD card at address e624
[ 1.383128] mmcblk0: mmc0:e624 SU02G 1.84 GiB
[ 1.391375] mmcblk0: p1 p2
[ 1.414643] EXT4-fs (mmcblk0p2): couldn't mount as ext3 due to feature incompatibilities
[ 1.427469] EXT4-fs (mmcblk0p2): couldn't mount as ext2 due to feature incompatibilities
[ 1.452899] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in b_idle (80, <SessEnd), retry #0, port1 00000100
[ 1.474071] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[ 1.485773] VFS: Mounted root (ext4 filesystem) on device 179:2.
[ 1.503516] devtmpfs: mounted
[ 1.509490] Freeing unused kernel memory: 1024K
[ 1.636200] EXT4-fs (mmcblk0p2): re-mounted. Opts: data=ordered
[ 3.039560] Generic PHY stmmac-0:01: attached PHY driver [Generic PHY] (mii_bus:phy_addr=stmmac-0:01, irq=-1)
[ 3.056885] dwmac-sun8i 1c30000.ethernet eth0: No MAC Management Counters available
[ 3.068126] dwmac-sun8i 1c30000.ethernet eth0: PTP not supported by HW
[ 5.127234] dwmac-sun8i 1c30000.ethernet eth0: Link is Up - 100Mbps/Full - flow control rx/tx
离线
msr06rr 说:晕哥 说:1. 首先确认的液晶是否是好的,有没有别的板子可以测试?
2. 检查排线是否插好,液晶的背光有没有亮?金属边框侧边仔细看,如果背光点亮会有漏光的。背光是亮的。
晕哥,你能给我一份你编译过的二进制程序吗,我烧一下看一下能不能显示界面好,我尽量今天晚上弄一份上传到此帖,最迟明天晚上。
多谢晕哥!
离线
我的天,感觉是我画的板子的问题,用示波器查看了一下,PCLK的波形特别不稳定,一个10M的信号在示波器上扭扭捏捏,完全失真了。。。
面壁思过去了。。。
离线
问题终于解决了,焊接的时候PCLK和旁边的GND短在了一起,我的天,折腾了我这么多天
放张效果图,紧跟晕哥的脚步,移植了lvgl
离线
好厉害,这是4.3寸电容触摸吗?
是的,不过电容的驱动还没开搞
离线
这是哪里买的,什么价格?
淘宝上选的,这家公司号称永不停产,所以买了一个试试看,这是链接:
https://item.taobao.com/item.htm?spm=a1z09.2.0.0.4d5279a9Ck8oaD&id=44817078572&_u=m98jou42793
离线
离线
msr06rr 说:晕哥 说:这是哪里买的,什么价格?
淘宝上选的,这家公司号称永不停产,所以买了一个试试看,这是链接:
https://item.taobao.com/item.htm?spm=a1z09.2.0.0.4d5279a9Ck8oaD&id=44817078572&_u=m98jou42793质量看起来不错,价格也挺不错
价格有点感人
昨天在 阿里巴巴买了两片 4.3 寸液晶 https://detail.1688.com/offer/582276964716.html
看起来质量还行, 20元,当然效果没有楼上的好。
然后自己再配电容或者电阻屏,
只能用最便宜的物料了, 谁叫我们做低端机呢?
离线