@jugg CM5的核心板最多可以出6个CSI接口,CM5的底板目前引出了4个CSI接口,这四个接口在同一个连接器上面。
Posts made by george
-
RE: How to install OpenCL/Kronos/OpenGL on CM5-EVB
@tmb68 The following figure shows the test results of OpenCl, and the testing method will be provided later.
coolpi@Ubuntu:~/share/clpeak/build$ ./clpeak Platform: ARM Platform arm_release_ver of this libmali is 'g6p0-01eac0', rk_so_ver is '7'. Device: Mali-LODX r0p0 Driver version : 2.1 (Linux ARM64) Compute units : 4 Clock frequency : 1000 MHz Global memory bandwidth (GBPS) float : 21.35 float2 : 23.18 float4 : 24.05 float8 : 12.08 float16 : 11.06 Single-precision compute (GFLOPS) float : 447.12 float2 : 476.20 float4 : 472.35 float8 : 440.72 float16 : 416.19 Half-precision compute (GFLOPS) half : 447.25 half2 : 888.31 half4 : 921.77 half8 : 897.50 half16 : 856.49 No double precision support! Skipped Integer compute (GIOPS) int : 126.55 int2 : 127.18 int4 : 126.64 int8 : 125.27 int16 : 125.79 Integer compute Fast 24bit (GIOPS) int : 126.64 int2 : 127.23 int4 : 126.79 int8 : 125.30 int16 : 125.76 Transfer bandwidth (GBPS) enqueueWriteBuffer : 7.31 enqueueReadBuffer : 8.25 enqueueWriteBuffer non-blocking : 7.30 enqueueReadBuffer non-blocking : 8.26 enqueueMapBuffer(for read) : 61.83 memcpy from mapped ptr : 9.57 enqueueUnmap(after write) : 61.21 memcpy to mapped ptr : 9.40 Kernel launch latency : 19.97 us
-
RE: Micro DisplayPort question
@murraytodd Insert your DP cable and print the mesg upload.
-
RE: Coolpi 4B not booting!
@Pharizna Please upgrade the loader to the latest version, format EMMC or TF card, and remake the boot image.
-
RE: cool pi 4b RebornOS support
@Pharizna Can other systems, such as ubuntu, be connected properly
-
RE: How to install OpenCL/Kronos/OpenGL on CM5-EVB
@tmb68 said in How to install OpenCL/Kronos/OpenGL on CM5-EVB:
Can anyone provide the steps required to install OpenCL/Kronos/OpenGL on the CM5-EVB?
Looking for support for the Mali-G610, not seeing UserSpace files on ARM or Rockchip sites.
Thanks,
TMBThe released Ubuntu system image is already integrated with G610 driver by default
-
RE: cool pi 4b RebornOS support
@Pharizna Please take a photo of the front of your machine.
-
A Method for Dynamically Hiding the Status Bar on Android 11
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java index c1d54b7..6228ef0 100755 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java @@ -202,6 +202,8 @@ import java.util.Map; public class PhoneStatusBar extends BaseStatusBar implements DemoMode, DragDownHelper.DragDownCallback, ActivityStarter, OnUnlockMethodChangedListener { static final String TAG = "PhoneStatusBar"; + static final String HIDE_NAVIGATION_BAR = "android.intent.action.HIDE_NAVIGATION_BAR"; + static final String SHOW_NAVIGATION_BAR = "android.intent.action.SHOW_NAVIGATION_BAR"; public static final boolean DEBUG = BaseStatusBar.DEBUG; public static final boolean SPEW = false; public static final boolean DUMPTRUCK = true; // extra dumpsys info @@ -1090,6 +1092,8 @@ final Object mScreenshotLock = new Object(); filter.addAction("fake_artwork"); } filter.addAction(ACTION_DEMO); + filter.addAction(HIDE_NAVIGATION_BAR); + filter.addAction(SHOW_NAVIGATION_BAR); context.registerReceiverAsUser(mBroadcastReceiver, UserHandle.ALL, filter, null, null); // listen for USER_SETUP_COMPLETE setting (per-user) @@ -1381,6 +1385,12 @@ final Object mScreenshotLock = new Object(); return false; } }; + + private void removeNavigationBar() { + if (mNavigationBarView == null) return; + mWindowManager.removeView(mNavigationBarView); + mNavigationBarView = null; + } //$_rbox_$_modify_$_huangjc,add add/remove bar button private View.OnTouchListener mHidebarPreloadOnTouchListener = new View.OnTouchListener() { @@ -1475,6 +1485,32 @@ final Object mScreenshotLock = new Object(); mWindowManager.addView(mNavigationBarView, getNavigationBarLayoutParams()); } + private void addNavigationBarInnerLocked(){ + if(mNavigationBarView == null){ + mNavigationBarView = (NavigationBarView) View.inflate(mContext, R.layout.navigation_bar, null); + mNavigationBarView.setDisabledFlags(mDisabled); + mNavigationBarView.setBar(this); + mNavigationBarView.setOnTouchListener(new View.OnTouchListener() { + @Override + public boolean onTouch(View v, MotionEvent event) { + checkUserAutohide(v, event); + return false; + }}); + if (mNavigationBarView == null) return; + + prepareNavigationBarView(); + try { + mWindowManager.addView(mNavigationBarView, getNavigationBarLayoutParams()); + } catch (Exception e) { + } + } + } + public void displayNavigation(){ + addNavigationBarInnerLocked(); + } + public void hideNavigation(){ + removeNavigationBar(); + } private void repositionNavigationBar() { if (mNavigationBarView == null || !mNavigationBarView.isAttachedToWindow()) return; @@ -3436,7 +3472,11 @@ final Object mScreenshotLock = new Object(); if (DEBUG_MEDIA_FAKE_ARTWORK) { updateMediaMetaData(true); } - } + }else if(HIDE_NAVIGATION_BAR.equals(action)){ + hideNavigation(); + }else if(SHOW_NAVIGATION_BAR.equals(action)){ + displayNavigation(); + } } };
-
RE: Introduction to COOL PI CM5 interface
@wuming
IMX219
【淘宝】https://m.tb.cn/h.UtvVLeM?tk=xKy7dm9s4XE CZ3457 「英伟达Jetson Nano摄像头模组 800万像素 IMX219芯片广角160度」
点击链接直接打开 或者 淘宝搜索直接打开
OV5647
【淘宝】https://m.tb.cn/h.Utv42LD?tk=6mA3dm9HRea CZ3457 「OV5647摄像头 OV5647模块适用于Raspberry Pi 500万像素 广角65度」
点击链接直接打开 或者 淘宝搜索直接打开
除了摄像头模组以外,CM5的机器还需要增加一根转接排线,预计下周各个店铺会上线转接排线。 -
RE: CoolPi 4B硬件如何扩展 CAN接口
@Tourists-0 下面这个帖子有介绍GPIO的功能复用,40PIN 可以扩展两路CAN出来。
https://www.cool-pi.com/topic/68/coolpi-4b硬件扩展一-40pin接口介绍?_=1682384241578 -
RE: Introduction to COOL PI CM5 interface
@wuming 你手上是V10的机器吗?V10的暂时不支持蓝牙!可以联系一下代理更换一下V11的底板。
-
RE: Introduction to COOL PI CM5 interface
@wuming 恭喜!!有空的话可以整理一下你的调试步骤,方便后面进来的小伙伴学习。
-
Full Record of CM5 Running ChatGLM-MNN Big Language Model
This example is based on the COOLPI CM5 32G memory version, and the system is ubuntu20.04.
- Download ChatGLM-MNN project
git clone https://github.com/wangzhaode/ChatGLM-MNN.git
- Compile MNN library
git clone https://github.com/alibaba/MNN.git cd MNN mkdir build && cd build cmake .. # CPU only make -j8 cp -r ../include ../../ChatGLM-MNN/ cp libMNN.so ../../ChatGLM-MNN/libs cp express/libMNN_Express.so ../../ChatGLM-MNN/libs
- Download Models
cd ChatGLM-MNN/resource/models ./download_models.sh int8 cp int8/* ./
- Build
mkdir build cd build cmake .. make -j8
- Run
coolpi@Ubuntu:~/share/ChatGLM-MNN/build$ ./cli_demo The device support i8sdot:1, support fp16:1, support i8mm: 0 Can't Find type=2 backend, use 3 instead load ../resource/tokenizer/slim_vocab.txt ... Done! load ../resource/models/glm_block_0.mnn model ... Done! load ../resource/models/glm_block_1.mnn model ... Done! load ../resource/models/glm_block_2.mnn model ... Done! load ../resource/models/glm_block_3.mnn model ... Done! load ../resource/models/glm_block_4.mnn model ... Done! load ../resource/models/glm_block_5.mnn model ... Done! load ../resource/models/glm_block_6.mnn model ... Done! load ../resource/models/glm_block_7.mnn model ... Done! load ../resource/models/glm_block_8.mnn model ... Done! load ../resource/models/glm_block_9.mnn model ... Done! load ../resource/models/glm_block_10.mnn model ... Done! load ../resource/models/glm_block_11.mnn model ... Done! load ../resource/models/glm_block_12.mnn model ... Done! load ../resource/models/glm_block_13.mnn model ... Done! load ../resource/models/glm_block_14.mnn model ... Done! load ../resource/models/glm_block_15.mnn model ... Done! load ../resource/models/glm_block_16.mnn model ... Done! load ../resource/models/glm_block_17.mnn model ... Done! load ../resource/models/glm_block_18.mnn model ... Done! load ../resource/models/glm_block_19.mnn model ... Done! load ../resource/models/glm_block_20.mnn model ... Done! load ../resource/models/glm_block_21.mnn model ... Done! load ../resource/models/glm_block_22.mnn model ... Done! load ../resource/models/glm_block_23.mnn model ... Done! load ../resource/models/glm_block_24.mnn model ... Done! load ../resource/models/glm_block_25.mnn model ... Done! load ../resource/models/glm_block_26.mnn model ... Done! load ../resource/models/glm_block_27.mnn model ... Done! load ../resource/models/lm.mnn model ... Done! Q: 写一首描绘冬天的诗 A: 漫天雪花飞舞, 寒风呼啸,大地一片沉寂。 冬天的气息弥漫, 银装素裹的世界令人陶醉。 树枝上挂满晶莹剔透的冰霜, 寒风把它们吹得摇曳生姿。 湖面上结满了厚厚的冰, 划着小船的人们欢笑着前行。 冬天是一个美丽而神秘的季节, 让人感受到宁静和祥和。 虽然它带来了一些不便, 比如冷的天气和冰雪的覆盖, 但它也是一年中最美好的时光。<eop> Q:
-
RE: How to drive non-standard resolution HDMI displays
@george Add 5.5inch HDMI AMOLED edid
https://www.waveshare.net/shop/5.5inch-HDMI-AMOLED.htm
diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c index 4fdfb41b91e1..b1171d8cbf2d 100644 --- a/drivers/gpu/drm/drm_edid.c +++ b/drivers/gpu/drm/drm_edid.c @@ -575,6 +575,14 @@ static const struct drm_display_mode drm_dmt_modes[] = { { DRM_MODE("4096x2160", DRM_MODE_TYPE_DRIVER, 556188, 4096, 4104, 4136, 4176, 0, 2160, 2208, 2216, 2222, 0, DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC) }, + /* 0x59 - 3840x1100@59.998Hz RB */ + { DRM_MODE("3840x1100", DRM_MODE_TYPE_DRIVER, 282890, 3840, 3888, + 3920, 4100, 0, 1100, 1103, 1108, 1150, 0, + DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC) }, + /* 0x60 - 1080x1920@60Hz RB */ + { DRM_MODE("1080x1920", DRM_MODE_TYPE_DRIVER, 137520, 1080, 1112, + 1144, 1200, 0, 1920, 1928, 1932, 1936, 0, + DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC) }, };
-
How to drive non-standard resolution HDMI displays
Users may have various resolutions of displays on their hands, some of which are not included in the xf86EdidModes support list. In this case, the software needs to do some processing to support this type of display. The specific steps are as follows:
- Obtaining device's edid information
cat /sys/class/drm/card0-HDMI*/edid > /home/coolpi/share/edid.bin
- Parsing EDID to obtain timings for various resolutions
coolpi@Ubuntu:~/share$ sudo apt-get install read-edid edid-decode coolpi@Ubuntu:~/share$ parse-edid < edid.bin Checksum Correct Section "Monitor" Identifier "HDMI" ModelName "HDMI" VendorName "ICB" # Monitor Manufactured week 50 of 2017 # EDID version 1.3 # Digital Display DisplaySize 1200 340 Gamma 2.20 Option "DPMS" "true" Horizsync 30-180 VertRefresh 48-120 # Maximum pixel clock is 600MHz #Not giving standard mode: 1152x864, 75Hz #Not giving standard mode: 1280x800, 60Hz #Not giving standard mode: 1280x720, 60Hz #Not giving standard mode: 1280x1024, 60Hz #Not giving standard mode: 1440x900, 60Hz #Not giving standard mode: 1600x900, 60Hz #Not giving standard mode: 1680x1050, 60Hz #Extension block found. Parsing... #WARNING: I may have missed a mode (CEA mode 97) #DOUBLE WARNING: It's your first mode, too, so this may actually be important. #WARNING: I may have missed a mode (CEA mode 96) #DOUBLE WARNING: It's your first mode, too, so this may actually be important. #WARNING: I may have missed a mode (CEA mode 90) #DOUBLE WARNING: It's your first mode, too, so this may actually be important. #WARNING: I may have missed a mode (CEA mode 95) Modeline "Mode 11" 297.00 1920 1968 2000 2200 2160 2163 2168 2250 +hsync +vsync Modeline "Mode 0" 282.89 3840 3888 3920 4100 1100 1103 1108 1150 +hsync -vsync Modeline "Mode 1" 540.00 3840 3888 3952 4000 1080 1083 1093 1125 +hsync -vsync Modeline "Mode 2" 148.500 1920 2008 2052 2200 1080 1084 1089 1125 +hsync +vsync Modeline "Mode 3" 74.250 1920 2008 2052 2200 1080 1082 1087 1125 +hsync +vsync interlace Modeline "Mode 4" 74.250 1280 1390 1420 1650 720 725 730 750 +hsync +vsync Modeline "Mode 5" 27.027 720 736 798 858 480 489 495 525 -hsync -vsync Modeline "Mode 6" 27.027 720 736 798 858 480 489 495 525 -hsync -vsync Modeline "Mode 7" 148.500 1920 2448 2492 2640 1080 1084 1089 1125 +hsync +vsync Modeline "Mode 8" 74.250 1280 1720 1760 1980 720 725 730 750 +hsync +vsync Modeline "Mode 9" 27.000 720 732 796 864 576 581 586 625 -hsync -vsync Modeline "Mode 10" 25.200 640 656 752 800 480 490 492 525 -hsync -vsync Modeline "Mode 12" 241.50 2560 2608 2640 2720 1440 1443 1448 1481 +hsync +vsync Option "PreferredMode" "Mode 11" EndSection
- Increase special resolution timming to DRM_ dmt_ Modes List
diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c index 4fdfb41b91e1..132dd01f28c9 100644 --- a/drivers/gpu/drm/drm_edid.c +++ b/drivers/gpu/drm/drm_edid.c @@ -575,6 +575,10 @@ static const struct drm_display_mode drm_dmt_modes[] = { { DRM_MODE("4096x2160", DRM_MODE_TYPE_DRIVER, 556188, 4096, 4104, 4136, 4176, 0, 2160, 2208, 2216, 2222, 0, DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC) }, + /* 0x59 - 3840x1100@59.998Hz RB */ + { DRM_MODE("3840x1100", DRM_MODE_TYPE_DRIVER, 282890, 3840, 3888, + 3920, 4100, 0, 1100, 1103, 1108, 1150, 0, + DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC) }, };
- Modify HDMI clock division method
diff --git a/arch/arm64/boot/dts/rockchip/rk3588-cpcm5-evb-v11.dts b/arch/arm64/boot/dts/rockchip/rk3588-cpcm5-evb-v11.dts index 9eee8a7133f0..41155fcfb4fe 100755 --- a/arch/arm64/boot/dts/rockchip/rk3588-cpcm5-evb-v11.dts +++ b/arch/arm64/boot/dts/rockchip/rk3588-cpcm5-evb-v11.dts @@ -1308,6 +1308,16 @@ &uart2 { &display_subsystem { memory-region = <&drm_logo>; memory-region-names = "drm-logo"; + clocks = <&hdptxphy_hdmi_clk0>, <&hdptxphy_hdmi_clk1>; + clock-names = "hdmi0_phy_pll", "hdmi1_phy_pll"; +}; + +&hdptxphy_hdmi_clk0 { +status = "okay"; +}; + +&hdptxphy_hdmi_clk1 { +status = "okay"; }; &rng {
- Recompile and replace the kernel, reboot
-
RE: Introduction to COOL PI CM5 interface
@wuming onedrive上0421最新的ubuntu22.04固件已经默认集成了intel的wifi/bt驱动和固件,可以下载测试。
-
RE: rk mpp平台YUV格式支持问题
@jugg
不同的格式对齐要求不同,RGA硬件本身是对图像每行的数据是按照字(world)对齐的方式进行取数的,即4个字节32个bit。例如RGBA格式本身单个像素存储大小为32(4 × 8)bit,所以没有对齐要求;RGB565格式存储大小为16(5 + 6 +5)bit,所以需要2对齐;RGB888格式存储大小为24(8 × 3)bit,所以该格式需要4对齐才能满足RGA硬件的32bit取数要求;YUV格式存储相对较为特殊,本身排列要求需要2对齐,Y通道单像素存储大小为8bit,UV通道根据420/422决定每四个像素的存储大小,所以YUV格式Y通道需要4对齐才能满足RGA的硬件取数要求,则YUV格式需要4对齐;其他的未提及的格式对齐要求原理相通。注意,该题中对齐均指width stride的对齐要求,YUV格式本身实际宽高、偏移量由于格式本身特性也是要求2对齐的。