Manjaro ARM for Rockchip TV Boxes

I tried to install AP6255 but it didn’t work.

However, I used my Vim3 image with the u-boot nano-pc-t4. dtb Rockpro64, kernel 5.10 it seems wifi works out of the box. But I don’t know which driver that is being used.

How can I check which driver is being used by my internal wifi on Manjaro?

If I used nmcli,
wifi (ath10k_sdio)

Is this the driver?

I cannot find it in /lib/firmware/brcm/

EDIT:
I found “ath10k” folder in /lib/firmware
After transferring the folder to the other sd card now my internal wifi is activated

Now how can I activate the bluetooth? how to check if bluetooth is recognized?
what is the command similar to nmcli for bluetooth?

Your wifi driver is atheros and to know about Bluetooth
dmesg |grep -i Bluetooth
Will give you some info.

On Manjaro I didn’t get any result

but on Armbian I got this result (after installing bluetooth module via armbian-config, but bluetooth is not working)

$ dmesg |grep -i Bluetooth
[ 31.679004] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[ 31.679017] Bluetooth: BNEP filters: protocol multicast
[ 31.679038] Bluetooth: BNEP socket layer initialized

I don’t know what is the driver of this bluetooth?

Report these:

rfkill list

lsmod | grep -i blue

Lsmod

This is the result from Manjaro:

$ rfkill list
0: hci0: Bluetooth
	Soft blocked: no
	Hard blocked: no
1: phy0: Wireless LAN
	Soft blocked: no
	Hard blocked: no
$ lsmod |grep -i blue
bluetooth             634880  13 btrtl,btqca,btintel,hci_uart,btbcm,bnep
ecdh_generic           16384  1 bluetooth
rfkill                 36864  7 bluetooth,cfg80211
$ Lsmod
bash: Lsmod: command not found
$ lsmod
Module                  Size  Used by
bnep                   32768  2
joydev                 32768  0
zram                   36864  1
nls_ascii              16384  1
ath10k_sdio            36864  0
hantro_vpu             86016  0
ath10k_core           372736  1 ath10k_sdio
rockchip_rga           24576  0
ath                    45056  1 ath10k_core
mac80211              561152  1 ath10k_core
v4l2_h264              16384  1 hantro_vpu
v4l2_mem2mem           40960  2 hantro_vpu,rockchip_rga
videobuf2_dma_contig    24576  1 hantro_vpu
videobuf2_vmalloc      20480  1 hantro_vpu
videobuf2_dma_sg       20480  1 rockchip_rga
videobuf2_memops       20480  3 videobuf2_vmalloc,videobuf2_dma_contig,videobuf2_dma_sg
cfg80211              401408  3 ath,mac80211,ath10k_core
videobuf2_v4l2         32768  3 hantro_vpu,rockchip_rga,v4l2_mem2mem
hci_uart              147456  0
videobuf2_common       61440  4 videobuf2_v4l2,hantro_vpu,rockchip_rga,v4l2_mem2mem
btqca                  20480  1 hci_uart
videodev              282624  5 videobuf2_v4l2,hantro_vpu,rockchip_rga,videobuf2_common,v4l2_mem2mem
btrtl                  24576  1 hci_uart
btbcm                  24576  1 hci_uart
btintel                28672  1 hci_uart
bluetooth             634880  13 btrtl,btqca,btintel,hci_uart,btbcm,bnep
mc                     61440  5 videodev,videobuf2_v4l2,hantro_vpu,videobuf2_common,v4l2_mem2mem
fusb302                28672  0
tcpm                   53248  1 fusb302
rockchip_saradc        20480  0
dw_hdmi_cec            16384  0
ecdh_generic           16384  1 bluetooth
typec                  57344  1 tcpm
ecc                    32768  1 ecdh_generic
snd_soc_simple_card    24576  0
snd_soc_audio_graph_card    24576  0
gpio_keys              20480  0
industrialio_triggered_buffer    16384  1 rockchip_saradc
snd_soc_simple_card_utils    28672  2 snd_soc_audio_graph_card,snd_soc_simple_card
rfkill                 36864  7 bluetooth,cfg80211
snd_soc_es8316         45056  1
pwm_fan                20480  0
kfifo_buf              16384  1 industrialio_triggered_buffer
rtc_rk808              20480  1
sch_fq_codel           20480  2
crypto_user            16384  0
fuse                  126976  3
ip_tables              32768  0
x_tables               45056  1 ip_tables

This is the result from Armbian:

$ rfkill list
0: hci0: Bluetooth
	Soft blocked: no
	Hard blocked: no
1: phy0: Wireless LAN
	Soft blocked: no
	Hard blocked: no
$ lsmod | grep -i blue
bluetooth             630784  13 btrtl,btqca,btintel,hci_uart,btbcm,bnep
rfkill                 36864  7 bluetooth,cfg80211
$ Lsmod
bash: Lsmod: command not found
$ lsmod
Module                  Size  Used by
aufs                  245760  0
bnep                   32768  2
governor_performance    16384  0
ath10k_sdio            32768  0
snd_soc_simple_card    24576  1
snd_soc_audio_graph_card    20480  2
snd_soc_es8316         45056  1
snd_soc_rockchip_i2s    24576  4
ath10k_core           376832  1 ath10k_sdio
snd_soc_simple_card_utils    28672  2 snd_soc_audio_graph_card,snd_soc_simple_card
snd_soc_hdmi_codec     20480  1
hantro_vpu             86016  0
rockchip_vdec          28672  0
snd_seq_midi           20480  0
mac80211              884736  1 ath10k_core
snd_seq_midi_event     16384  1 snd_seq_midi
snd_soc_core          237568  6 snd_soc_hdmi_codec,snd_soc_audio_graph_card,snd_soc_simple_card_utils,snd_soc_rockchip_i2s,snd_soc_simple_card,snd_soc_es8316
rockchip_rga           24576  0
snd_rawmidi            40960  1 snd_seq_midi
v4l2_h264              16384  2 rockchip_vdec,hantro_vpu
snd_pcm_dmaengine      20480  1 snd_soc_core
videobuf2_dma_contig    24576  2 rockchip_vdec,hantro_vpu
hci_uart              143360  0
ath                    40960  1 ath10k_core
snd_pcm               118784  4 snd_soc_hdmi_codec,snd_soc_core,snd_soc_es8316,snd_pcm_dmaengine
snd_seq                81920  2 snd_seq_midi,snd_seq_midi_event
v4l2_mem2mem           40960  3 rockchip_vdec,hantro_vpu,rockchip_rga
videobuf2_dma_sg       20480  1 rockchip_rga
videobuf2_vmalloc      20480  1 hantro_vpu
videobuf2_memops       20480  3 videobuf2_vmalloc,videobuf2_dma_contig,videobuf2_dma_sg
btqca                  20480  1 hci_uart
cfg80211              864256  3 ath,mac80211,ath10k_core
videobuf2_v4l2         32768  4 rockchip_vdec,hantro_vpu,rockchip_rga,v4l2_mem2mem
btrtl                  24576  1 hci_uart
snd_seq_device         20480  3 snd_seq,snd_seq_midi,snd_rawmidi
videobuf2_common       61440  5 rockchip_vdec,videobuf2_v4l2,hantro_vpu,rockchip_rga,v4l2_mem2mem
rc_cec                 16384  0
btbcm                  24576  1 hci_uart
libarc4                16384  1 mac80211
snd_timer              40960  2 snd_seq,snd_pcm
videodev              299008  6 rockchip_vdec,videobuf2_v4l2,hantro_vpu,rockchip_rga,videobuf2_common,v4l2_mem2mem
panfrost               65536  6
btintel                28672  1 hci_uart
fusb302                28672  0
dw_hdmi_i2s_audio      16384  0
dw_hdmi_cec            16384  0
snd                    90112  13 snd_seq,snd_seq_device,snd_soc_hdmi_codec,snd_timer,snd_soc_core,snd_pcm,snd_rawmidi
tcpm                   53248  1 fusb302
mc                     61440  6 rockchip_vdec,videodev,videobuf2_v4l2,hantro_vpu,videobuf2_common,v4l2_mem2mem
bluetooth             630784  13 btrtl,btqca,btintel,hci_uart,btbcm,bnep
pwm_fan                20480  0
gpu_sched              40960  1 panfrost
typec                  57344  1 tcpm
joydev                 32768  0
soundcore              16384  1 snd
rfkill                 36864  7 bluetooth,cfg80211
cpufreq_dt             20480  0
zram                   36864  2
sch_fq_codel           20480  2
ip_tables              32768  0
x_tables               45056  1 ip_tables
autofs4                45056  2
realtek                24576  1
rockchipdrm           135168  12
analogix_dp            49152  1 rockchipdrm
dw_hdmi                53248  2 dw_hdmi_i2s_audio,rockchipdrm
dw_mipi_dsi            20480  1 rockchipdrm
drm_kms_helper        245760  4 dw_mipi_dsi,rockchipdrm,dw_hdmi,analogix_dp
cec                    73728  3 drm_kms_helper,dw_hdmi_cec,dw_hdmi
rc_core                57344  3 rc_cec,cec
dwmac_rk               28672  0
stmmac_platform        24576  1 dwmac_rk
drm                   573440  19 gpu_sched,drm_kms_helper,dw_mipi_dsi,rockchipdrm,dw_hdmi,panfrost,analogix_dp
stmmac                196608  2 stmmac_platform,dwmac_rk
pcs_xpcs               20480  1 stmmac
drm_panel_orientation_quirks    20480  1 drm

Ok

Rfkill reports is not blocked so no problems there but radio is not up. From second report seems you have rtl, Intel, qca and bcm drivers too many for just a device. Only last two could work.
Kill rtl and Intel if you know howto but better ask for support in general forum as this is not arm specific and I don’t know how to proceed.

Ok many thanks for your suggestion, I’ll ask in general forum

While waiting for cavalry you can try

Sudo modprobe -r btrtl btintel btbcm

dmesg | egrep -i ‘blue|firm’

$ sudo modprobe -r btrtl btintel btbcm
modprobe: FATAL: Module btrtl is in use.
$ dmesg | egrep -i ‘blue|firm’
bash: firm’: command not found

Have a look here

@SickOS You are amazing…!!!

Many Thanks for your link, finally I figure it out how to fix the Bluetooth. The answer is I have to change the dtb to dts, and then replace the bluetooth compatible driver to QCA9377. Now Bluetooth is working perfectly on my H96 Max - RK3399 Box.

Here’s the step by step:

  1. Convert the working dtb into dts (In my case the best working dtb is rk3399-rockpro64.dtb):

dtc -I dtb -O dts /your/dtb/location/rk3399-rockpro64.dtb -o /your/dts/location/rk3399-rockpro64.dts

  1. Edit the dts file (you can use nano or text editor, I would recommend using text editor), if you uses terminal use this nano command:

nano /your/dts/location/rk3399-rockpro64.dts

  1. Find the word “bluetooth”, and then edit the line below from this:
	bluetooth {
		compatible = "brcm,bcm43438-bt";

Into this:

	bluetooth {
		compatible = "qcom,qca9377-bt";
  1. Now save your rk3399-rockpro64.dts

  2. Rename “rk3399-rockpro64.dts” into “rk3399-H96Max.dts”

  3. Let’s convert the dts back to dtb

dtc -I dts -O dtb /your/dts/location/rk3399-H96Max.dts -o /your/dtb/location/rk3399-H96Max.dtb

  1. Now copy and paste your new dtb into your SDCard dtb folder

  2. Now change the configuration text to your new “rk3399-H96Max.dtb”

  3. Insert your SD Card to your RK3399-H96 Max Box

  4. Your box should now be able to run bluetooth without a problem

Enjoy!

:slight_smile:

Big Thanks to maz-1 from Github:

If you need my dtb and dts, you can download it from my post on Armbian, I cannot attach any document here:

1 Like

Now, my last question the only think that is not solved yet is how to make the Audio Jack working. @SickOS : Do you have any idea to fix the audio jack issue?

Happy to see the link worked.

No idea about sound, in fact I don’t have it in Manjaro. Check with alsamixer if audio-jack is muted.

Yes, it is muted. But I cannot change the Mute to unmute by pressing M and Up arrow

In Alsamixer, my Right Headphone Mixer RLIN is off, I cannot turn it on by pressing M
also the DAC Soft Ramp is off as well.

Just to let you know that I have two output in Volume Control:

  1. HDMI Output
  2. Audio Jack Output

The HDMI is working, but the Audio Jack isn’t.

I have Allwinner H5 box, it has those two outputs in Volume Control and both are working very well on Manjaro. Therefore, I am pretty sure that there must be a setting that is missing to activate those Audio Jack.

It seems that the ES8316 is muted by default.

There is this solution on github, but I don’t know how to apply it?

here’s my aplay report:

$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: rockchiprk3399 [rockchip,rk3399], device 0: ff890000.i2s-ES8316 HiFi ES8316 HiFi-0 [ff890000.i2s-ES8316 HiFi ES8316 HiFi-0]
Subdevices: 0/1
Subdevice #0: subdevice #0
card 1: hdmisound [hdmi-sound], device 0: ff8a0000.i2s-i2s-hifi i2s-hifi-0 [ff8a0000.i2s-i2s-hifi i2s-hifi-0]
Subdevices: 0/1
Subdevice #0: subdevice #0

Help would be appreciated

It seems you have to use mixer to switch on with these commands

mixer $rockchiprk3399 ‘Right Headphone Mixer Right DAC’ on
mixer $rockchiprk3399 ‘Left Headphone Mixer Left DAC’ on

1 Like

User can change it using amixer instead of the commands.

I tried everything but it is still muted

Still doesn’t work

Maybe I will wait a little bit longer until the “full-firmware” mature then I will try to edit the “updated dtb” again to make the audio working.

Have tried this with the latest firmware update, but the audio jack still does not work.

However, I have a workaround to get the sound working. I attach a USB SoundCard into by H96Max-RK3399 Box. Now magically I have line-in and line-out working. Finally I have my microphone and sound working by using USB SoundCard.

*NOTE: I still want to fix the 3.5 mm Audio Jack Problem. I just noticed that most of arm linux does not support 3.5 mm Audio Jack for SOC ( I might be wrong).