Raspberry pi 7“;LCD显示器不适用于Android设备

Raspberry pi 7“;LCD显示器不适用于Android设备,raspberry-pi,raspberry-pi3,android-things,Raspberry Pi,Raspberry Pi3,Android Things,又是我问了一个关于安卓系统的问题 这次我想通过HDMI和USB将一个7英寸的显示器连接到我的Raspberry Pi 3(运行Android Things 0.5.1) 此处显示要显示的链接: 我还按照手册上的说明将这些行添加到sd卡根目录中的config.txt max_usb_current=1 hdmi_group=2 hdmi_mode=1 hdmi_mode=87 hdmi_cvt 1024 600 60 6 0 0 0 hdmi_drive=1 然后我插上显示器。它肯定是开着的!但

又是我问了一个关于安卓系统的问题

这次我想通过HDMI和USB将一个7英寸的显示器连接到我的Raspberry Pi 3(运行Android Things 0.5.1)
此处显示要显示的链接:

我还按照手册上的说明将这些行添加到sd卡根目录中的
config.txt

max_usb_current=1
hdmi_group=2
hdmi_mode=1
hdmi_mode=87
hdmi_cvt 1024 600 60 6 0 0 0
hdmi_drive=1
然后我插上显示器。它肯定是开着的!但显示器只显示一个黑屏

My config.txt 我附上了我完整的
config.txt
,也许我遗漏了什么。再说一遍:我只添加了上面显示的行

kernel=u-boot-dtok.bin
framebuffer_depth=16

# Prevent the firmware from loading HAT overlays now that we handle pin muxing.
# ourselves. See:
# https://www.raspberrypi.org/documentation/configuration/device-tree.md#part3.4
dtoverlay=

dtparam=i2c_arm=on
dtparam=spi=on
dtparam=audio=on

# pwm and I2S are mutually-exclusive since they share hardware clocks.
dtoverlay=pwm-2chan-with-clk,pin=18,func=2,pin2=13,func2=4
dtoverlay=generic-i2s

start_x=1

# Tell U-boot to always use the "serial0" interface for the console, which is
# set to whichever uart (uart0 or uart1) is set to the header pins. This doesn't
# interfere with the uart selected for Bluetooth.
dtoverlay=chosen-serial0

# Enable skip-init on the UART interfaces, so U-Boot doesn't attempt to
# re-initialize them.
dtoverlay=rpi-uart-skip-init

# Add pin devices to the system for use by the runtime pin configuration driver.
dtoverlay=runtimepinconfig
dtoverlay=uart1
dtoverlay=bcm2710-rpi-3-b-spi0-pin-reorder

# Tell the I2S driver to use the cprman clock.
dtoverlay=bcm2710-rpi-3-b-i2s-use-cprman

# Uncomment to disable serial port on headers, use GPIO14 and GPIO15
# as gpios and to allow the core_freq to change at runtime.
enable_uart=1
core_freq=400

# Enable hardware graphics acceleration.
dtoverlay=vc4-kms-v3d,cma-256
mask_gpu_interrupt0=0x400
avoid_warnings=2

# Support official RPi display.
dtoverlay=i2c-rtc,ds3231
dtoverlay=rpi-ft5406
hdmi_force_hotplug=1
hdmi_drive=2

# Support custom Waveshare 7inch display
max_usb_current=1
hdmi_group=2
hdmi_mode=87
hdmi_cvt 1024 600 60 6 0 0 0
hdmi_drive=1
我还检查了其他一些类似的问题
但我没有看到更多的信息:(

小更新 我还联系了制造商支持。一旦我有更多信息,我会在这里添加它

另一个更新 我刚收到一封来自制造商支持部门的电子邮件:

是的,它可以。但是,在测试期间。只有长HDMI电缆 因为LCD可以显示新版本的android东西,我们没有 找出原因

我刚刚查看了logcat。据我所知,系统试图连接触摸屏,但没有驱动程序

这些台词看起来也很有趣,但我真的不明白问题所在:(

以下是完整的日志:

--------- beginning of system
09-19 17:17:56.447 311-430/system_process D/UsbHostManager: Added device UsbDevice[mName=/dev/bus/usb/001/004,mVendorId=3823,mProductId=5,mClass=0,mSubclass=0,mProtocol=0,mManufacturerName=WaveShare,mProductName=WaveShare Touchscreen,mVersion=2.0,mSerialNumber=2016-11-06,mConfigurations=[
                    UsbConfiguration[mId=1,mName=null,mAttributes=192,mMaxPower=250,mInterfaces=[
                    UsbInterface[mId=0,mAlternateSetting=0,mName=null,mClass=3,mSubclass=0,mProtocol=0,mEndpoints=[
                    UsbEndpoint[mAddress=129,mAttributes=3,mMaxPacketSize=64,mInterval=1]]]]
09-19 17:17:56.473 311-326/system_process I/ActivityManager: Start proc 1277:com.android.mtp/u0a7 for broadcast com.android.mtp/.UsbIntentReceiver
09-19 17:17:56.501 311-372/system_process E/EventHub: could not get driver version for /dev/input/mouse0, Not a typewriter
09-19 17:17:56.509 1277-1277/? W/zygote: Using default instruction set features for ARM CPU variant (generic) using conservative defaults
09-19 17:17:56.551 1277-1284/? I/zygote: Debugger is no longer active
09-19 17:17:56.644 311-372/system_process D/EventHub: No input device configuration file found for device 'WaveShare WaveShare Touchscreen'.
09-19 17:17:56.644 311-372/system_process I/EventHub: New device: id=1, fd=186, path='/dev/input/event0', name='WaveShare WaveShare Touchscreen', classes=0x80000014, configuration='', keyLayout='', keyCharacterMap='', builtinKeyboard=false, wakeMechanism=EPOLLWAKEUP, usingClockIoctl=true
09-19 17:17:56.645 311-372/system_process I/InputReader: Device reconfigured: id=1, name='WaveShare WaveShare Touchscreen', size 16x16, orientation 0, mode 1, display id 0
09-19 17:17:56.645 311-372/system_process I/InputReader: Device added: id=1, name='WaveShare WaveShare Touchscreen', sources=0x00001002
09-19 17:17:56.679 935-935/? I/Binder:311_6: type=1400 audit(0.0:76): avc: denied { ptrace } for scontext=u:r:system_server:s0 tcontext=u:r:priv_app:s0:c512,c768 tclass=process permissive=1
09-19 17:17:57.909 240-240/? I/drm-event-liste: type=1400 audit(0.0:77): avc: denied { read } for path="socket:[8839]" dev="sockfs" ino=8839 scontext=u:r:hal_graphics_composer_default:s0 tcontext=u:r:hal_graphics_composer_default:s0 tclass=netlink_kobject_uevent_socket permissive=1
09-19 17:17:59.010 311-381/system_process W/AlarmManager: Unrecognized alarm listener com.android.server.wifi.WifiConfigStore$1@f0356d5
09-19 17:17:59.028 311-381/system_process D/WifiConfigStore: Writing to stores completed in 18 ms.
09-19 17:18:00.630 170-261/? E/hwc-gl-worker: Failed to make image from target buffer: EGL_BAD_PARAMETER
09-19 17:18:00.630 170-261/? E/hwc-gl-worker: Composite failed because of failed framebuffer
09-19 17:18:00.630 170-261/? E/hwc-drm-display-compositor: Failed to pre-composite layers
09-19 17:18:00.630 170-261/? E/hwc-drm-display-compositor: Failed to pre-composite for squash all composition -22
09-19 17:18:00.631 170-261/? E/hwc-platform-drm-generic: Failed to close gem handle 0 -1
09-19 17:18:08.861 311-1055/system_process D/WificondControl: Scan result ready event
09-19 17:18:30.976 311-325/system_process E/memtrack: Couldn't load memtrack module
09-19 17:18:30.976 311-325/system_process W/android.os.Debug: failed to get memory consumption info: -1
09-19 17:18:31.081 311-325/system_process E/memtrack: Couldn't load memtrack module
09-19 17:18:31.082 311-325/system_process W/android.os.Debug: failed to get memory consumption info: -1
09-19 17:18:31.407 130-130/? W//system/bin/hwservicemanager: getTransportFromManifest: Cannot find entry android.hardware.drm@1.0::IDrmFactory in either framework or device manifest, using default transport.
09-19 17:18:31.409 178-245/? E/DrmHal: Failed to find any drm factories
09-19 17:18:31.413 950-1303/com.google.android.gms.unstable W/DG.WV: Widevine DRM not supported on this device
                             android.media.UnsupportedSchemeException: Failed to instantiate drm object.
                                 at android.media.MediaDrm.native_setup(Native Method)
                                 at android.media.MediaDrm.<init>(MediaDrm.java:216)
                                 at joi.run(:com.google.android.gms:9)
                                 at ius.run(:com.google.android.gms:24)
                                 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
                                 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
                                 at izo.run(:com.google.android.gms:0)
                                 at java.lang.Thread.run(Thread.java:764)
09-19 17:18:31.707 311-1041/system_process D/WificondControl: Scan result ready event
09-19 17:18:32.104 950-1129/com.google.android.gms.unstable W/SystemServiceRegistry: No service published for: persistent_data_block
09-19 17:18:32.119 1129-1129/? I/Binder:950_3: type=1400 audit(0.0:78): avc: denied { read } for name="/" dev="tmpfs" ino=7244 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:device:s0 tclass=dir permissive=1
09-19 17:18:32.129 1129-1129/? I/Binder:950_3: type=1400 audit(0.0:80): avc: denied { read } for name="interrupts" dev="proc" ino=4026532794 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:proc_interrupts:s0 tclass=file permissive=1
09-19 17:18:32.144 950-1129/com.google.android.gms.unstable W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_U1rfdkMe/Mr,09vcaQ,w
09-19 17:18:32.150 950-1129/com.google.android.gms.unstable W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_U1rfdkMe/Mr,09vcaQ,w
09-19 17:18:34.049 783-1305/com.google.android.gms.persistent I/VacuumService: Vacuum at: now=1505841514048 tag=VacuumService
09-19 17:18:34.223 783-783/com.google.android.gms.persistent I/Auth: [ReflectiveChannelBinder] Successfully bound channel!
09-19 17:18:34.260 130-130/? W//system/bin/hwservicemanager: getTransportFromManifest: Cannot find entry android.hardware.drm@1.0::IDrmFactory in either framework or device manifest, using default transport.
09-19 17:18:34.262 178-178/? E/DrmHal: Failed to find any drm factories
09-19 17:18:34.264 950-1308/com.google.android.gms.unstable W/DG.WV: Widevine DRM not supported on this device
                             android.media.UnsupportedSchemeException: Failed to instantiate drm object.
                                 at android.media.MediaDrm.native_setup(Native Method)
                                 at android.media.MediaDrm.<init>(MediaDrm.java:216)
                                 at joi.run(:com.google.android.gms:9)
                                 at ius.run(:com.google.android.gms:24)
                                 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
                                 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
                                 at izo.run(:com.google.android.gms:0)
                                 at java.lang.Thread.run(Thread.java:764)
09-19 17:18:34.835 950-968/com.google.android.gms.unstable W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_U1rfdkMe/Mr,09vcaQ,w
09-19 17:18:34.839 950-968/com.google.android.gms.unstable W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_U1rfdkMe/Mr,09vcaQ,w
09-19 17:18:34.968 950-968/com.google.android.gms.unstable W/SystemServiceRegistry: No service published for: persistent_data_block
09-19 17:18:36.507 950-968/com.google.android.gms.unstable W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_U1rfdkMe/Mr,09vcaQ,w
09-19 17:18:36.514 950-968/com.google.android.gms.unstable W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_U1rfdkMe/Mr,09vcaQ,w
09-19 17:18:36.628 783-1042/com.google.android.gms.persistent W/Conscrypt: Could not set socket write timeout:
09-19 17:18:36.630 783-1042/com.google.android.gms.persistent W/Conscrypt:    java.lang.reflect.Method.invoke(Native Method)
09-19 17:18:36.630 783-1042/com.google.android.gms.persistent W/Conscrypt:    rkw.a(:com.google.android.gms:55)
09-19 17:18:36.752 783-1042/com.google.android.gms.persistent W/Conscrypt: Could not set socket write timeout:
09-19 17:18:36.753 783-1042/com.google.android.gms.persistent W/Conscrypt:    java.lang.reflect.Method.invoke(Native Method)
09-19 17:18:36.753 783-1042/com.google.android.gms.persistent W/Conscrypt:    rkw.a(:com.google.android.gms:55)
09-19 17:18:37.310 311-321/system_process I/zygote: Background concurrent copying GC freed 56654(2MB) AllocSpace objects, 4(80KB) LOS objects, 42% free, 4MB/8MB, paused 514us total 149.999ms
09-19 17:18:48.913 167-167/? D/WifiHAL: Start get packet fate command
09-19 17:18:48.913 167-167/? D/WifiHAL: createRequest Get Tx packet fate request
09-19 17:18:48.913 167-167/? E/WifiHAL: Failed to register get pkt fate response; result = -95
09-19 17:18:48.914 311-381/system_process E/WifiVendorHal: getTxPktFates(l.1941) failed {.code = ERROR_NOT_AVAILABLE, .description = }
09-19 17:18:48.915 167-167/? D/WifiHAL: Start get packet fate command
09-19 17:18:48.915 167-167/? D/WifiHAL: createRequest Get Rx packet fate request
09-19 17:18:48.915 167-167/? E/WifiHAL: Failed to register get pkt fate response; result = -95
09-19 17:18:48.916 311-381/system_process E/WifiVendorHal: getRxPktFates(l.1981) failed {.code = ERROR_NOT_AVAILABLE, .description = }
09-19 17:19:00.624 170-261/? E/hwc-gl-worker: Failed to make image from target buffer: EGL_BAD_PARAMETER
09-19 17:19:00.624 170-261/? E/hwc-gl-worker: Composite failed because of failed framebuffer
09-19 17:19:00.624 170-261/? E/hwc-drm-display-compositor: Failed to pre-composite layers
09-19 17:19:00.624 170-261/? E/hwc-drm-display-compositor: Failed to pre-composite for squash all composition -22
09-19 17:19:00.625 170-261/? E/hwc-platform-drm-generic: Failed to close gem handle 0 -1
09-19 17:19:10.975 311-325/system_process E/memtrack: Couldn't load memtrack module
09-19 17:19:10.975 311-325/system_process W/android.os.Debug: failed to get memory consumption info: -1
09-19 17:19:11.702 311-935/system_process D/WificondControl: Scan result ready event
09-19 17:19:16.084 311-325/system_process E/memtrack: Couldn't load memtrack module
09-19 17:19:16.084 311-325/system_process W/android.os.Debug: failed to get memory consumption info: -1
09-19 17:19:16.183 311-325/system_process E/memtrack: Couldn't load memtrack module
09-19 17:19:16.183 311-325/system_process W/android.os.Debug: failed to get memory consumption info: -1

好的,我想我有和你一样的工具包,RPI3,带有7''显示Waveshare和短而平的HDMI电缆。我刚试着用0.5.1启动这个工具包,它工作正常(首先它显示了人工制品、线条,似乎有破损,但几秒钟后我可以看到Android Things start屏幕).我按照上的说明进行安装。如果您阅读了0.5.1的,则有以下内容:

自动检测Raspberry Pi 3上的显示设置,而无需编辑根config.txt文件。

但是我为您复制了我的(自动生成的)
config.txt

kernel=u-boot-dtok.bin
framebuffer_depth=16

# Prevent the firmware from loading HAT overlays now that we handle pin muxing.
# ourselves. See:
# https://www.raspberrypi.org/documentation/configuration/device-tree.md#part3.4
dtoverlay=

dtparam=i2c_arm=on
dtparam=spi=on
dtparam=audio=on

# pwm and I2S are mutually-exclusive since they share hardware clocks.
dtoverlay=pwm-2chan-with-clk,pin=18,func=2,pin2=13,func2=4
dtoverlay=generic-i2s

start_x=1

# Tell U-boot to always use the "serial0" interface for the console, which is
# set to whichever uart (uart0 or uart1) is set to the header pins. This doesn't
# interfere with the uart selected for Bluetooth.
dtoverlay=chosen-serial0

# Enable skip-init on the UART interfaces, so U-Boot doesn't attempt to
# re-initialize them.
dtoverlay=rpi-uart-skip-init

# Add pin devices to the system for use by the runtime pin configuration driver.
dtoverlay=runtimepinconfig
dtoverlay=uart1
dtoverlay=bcm2710-rpi-3-b-spi0-pin-reorder

# Tell the I2S driver to use the cprman clock.
dtoverlay=bcm2710-rpi-3-b-i2s-use-cprman

# Uncomment to disable serial port on headers, use GPIO14 and GPIO15
# as gpios and to allow the core_freq to change at runtime.
enable_uart=1
core_freq=400

# Enable hardware graphics acceleration.
dtoverlay=vc4-kms-v3d,cma-256
mask_gpu_interrupt0=0x400
avoid_warnings=2

# Support official RPi display.
dtoverlay=i2c-rtc,ds3231
dtoverlay=rpi-ft5406
hdmi_force_hotplug=1
hdmi_drive=2

我希望它能有所帮助。

有时我会设法让显示器运行(使用新格式化的图像和上面发布的config.txt)……但显示器有时会停止工作……然后我会收到此日志消息

1-01 00:00:18.553 311-334/? I/DisplayManagerService: Display device added: DisplayDeviceInfo{"Built-in Screen": uniqueId="local:0", 16 x 16, modeId 1, defaultModeId 1, supportedModes [{id=1, width=16, height=16, fps=1.0}], colorMode 0, supportedColorModes [0], HdrCapabilities android.view.Display$HdrCapabilities@1d6308, density 240, 96.0 x 96.0 dpi, appVsyncOff 1000000, presDeadline 1000000000, touch INTERNAL, rotation 0, type BUILT_IN, state UNKNOWN, FLAG_DEFAULT_DISPLAY, FLAG_ROTATES_WITH_CONTENT, FLAG_SECURE, FLAG_SUPPORTS_PROTECTED_BUFFERS}
然后再也没有其他显示器(如我的显示器或电视)不再工作了

如果检测到显示,我将收到此消息:

01-01 00:00:18.591 310-332/? I/DisplayManagerService: Display device added: DisplayDeviceInfo{"Built-in Screen": uniqueId="local:0", 1024 x 600, modeId 1, defaultModeId 1, supportedModes [{id=1, width=1024, height=600, fps=43.0}], colorMode 0, supportedColorModes [0], HdrCapabilities android.view.Display$HdrCapabilities@1d6308, density 240, 173.397 x 152.4 dpi, appVsyncOff 1000000, presDeadline 23255814, touch INTERNAL, rotation 0, type BUILT_IN, state UNKNOWN, FLAG_DEFAULT_DISPLAY, FLAG_ROTATES_WITH_CONTENT, FLAG_SECURE, FLAG_SUPPORTS_PROTECTED_BUFFERS}
我认为这是安卓系统中的一个bug,希望在下一个版本中可以修复


如果我有任何更新,我会更新这篇文章。

这个问题应该在DP6()中解决,已经解决了。但是我还没有测试它。

@Onik-hmm…我想我已经等了足够的时间了^^^^它连接了大约一个小时。我应该使用哪个值?使用最新版本的AndroidThings?如果最新版本是0.5.1是:)代码在哪里?例如,您是否调用
setContentView
?如果您找到了问题的解决方案/解决方法,或者得出了错误的结论,请通过回答自己的问题来分享您的发现。我也尝试了这个…(还有一个新的图像)但它对我来说不起作用:/它只是在我将显示器手册中的行添加到配置后才起作用。有时也适用于0.5.1,或者仅适用于0.4.1?我的意思是,除了情况之外,你能肯定吗,0.5.1根本不起作用,不仅仅是显示器。如果我将显示器连接到另一个设备上,它总是会向我显示一个正确的屏幕e、 …我用新信息更新了我的问题(在底部)-我也尝试了0.4.1。您是否尝试通过HDMI将RPi3与0.5.1连接到电视机或其他显示器?我第一次在将Waveshare连接到RPi3时遇到问题,并检查了(当时)AT0.3与HDMI完全兼容。我的意思是,也许你已经破坏了0.5.1版本…我做了多次,我还创建了一个新图像,刷新了我的sd卡,甚至尝试了另一个…我还检查了其他显示器(比如我的电视或显示器)
1-01 00:00:18.553 311-334/? I/DisplayManagerService: Display device added: DisplayDeviceInfo{"Built-in Screen": uniqueId="local:0", 16 x 16, modeId 1, defaultModeId 1, supportedModes [{id=1, width=16, height=16, fps=1.0}], colorMode 0, supportedColorModes [0], HdrCapabilities android.view.Display$HdrCapabilities@1d6308, density 240, 96.0 x 96.0 dpi, appVsyncOff 1000000, presDeadline 1000000000, touch INTERNAL, rotation 0, type BUILT_IN, state UNKNOWN, FLAG_DEFAULT_DISPLAY, FLAG_ROTATES_WITH_CONTENT, FLAG_SECURE, FLAG_SUPPORTS_PROTECTED_BUFFERS}
01-01 00:00:18.591 310-332/? I/DisplayManagerService: Display device added: DisplayDeviceInfo{"Built-in Screen": uniqueId="local:0", 1024 x 600, modeId 1, defaultModeId 1, supportedModes [{id=1, width=1024, height=600, fps=43.0}], colorMode 0, supportedColorModes [0], HdrCapabilities android.view.Display$HdrCapabilities@1d6308, density 240, 173.397 x 152.4 dpi, appVsyncOff 1000000, presDeadline 23255814, touch INTERNAL, rotation 0, type BUILT_IN, state UNKNOWN, FLAG_DEFAULT_DISPLAY, FLAG_ROTATES_WITH_CONTENT, FLAG_SECURE, FLAG_SUPPORTS_PROTECTED_BUFFERS}