Jump to content

NanoPi M4 V2 - M4 Image not working


NicoD

Recommended Posts

4 hours ago, pkfox said:

Hi Pask, how did you discover what wifi chip is used ? and how do you install firmware-brcm80211 ? sorry for all the questions I'm really keen to understand how these boards work

Hello @pkfox,

at friendlyelec's nanopi-m4 product page https://www.friendlyarm.com/index.php?route=product/product&product_id=234

there is a very good description of the board's specs. From that page, you'll find that the wifi (and bluetooth) chip is the "big" one, just behind the antenna connector. Searching the web you'll find that this chip embeds a broadcom wifi plus a bt module.

Sadly, this chip needs a firmware blob, which you can install following (for example) this very good explanation page: https://wiki.debian.org/brcm80211

 

 

 

 

Link to comment
Share on other sites

8 hours ago, guidol said:

also do 

cp /lib/firmware/brcm/brcmfmac4356-sdio.txt /lib/firmware/brcm/ brcmfmac4356-sdio.friendlyarm,nanopi-m4.txt

then check if  /lib/firmware/brcm/brcmfmac4356-sdio.bin would be loaded?

 

@guidolOK thank you. It looks to me that the firmware gets loaded. But then something goes wrong

 

[  792.494106] brcmfmac: F1 signature read @0x18000000=0x17224356
[  792.504431] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac4356-sdio for chip BCM4356/2
[  795.547138] brcmfmac: brcmf_sdio_readshared: invalid sdpcm_shared address 0xFE8B0174
[  795.547142] brcmfmac: brcmf_sdio_readshared: unable to obtain sdpcm_shared info: rv=-22 (addr=0xfe8b0174)

 

Link to comment
Share on other sites

Did anyone try a desktop? I had build a RockPi4b Bionic 5.3 desktop (with Panfrost) a while ago on the m4v2 and saw a few issues.
Couldn't load volume control, It crashed the desktop and all apps and reopened desktop. Some small weird things gave the same result. (decreasing font size of command taskbar app. Why/How???)
I thought it could be some panfrost issue.
I'm now working with another sbc, so not really time to test it, just wondered if anyone else had seen this. I was using the M4.dtb
 

Link to comment
Share on other sites

2 hours ago, NicoD said:

Did anyone try a desktop? I had build a RockPi4b Bionic 5.3 desktop (with Panfrost) a while ago on the m4v2 and saw a few issues.
Couldn't load volume control, It crashed the desktop and all apps and reopened desktop. Some small weird things gave the same result. (decreasing font size of command taskbar app. Why/How???)
I thought it could be some panfrost issue.
I'm now working with another sbc, so not really time to test it, just wondered if anyone else had seen this. I was using the M4.dtb
 

@NicoD

I'm using Armbian_5.99.191102_Rockpi-4b_Debian_buster_dev_5.3.0-rc4_minimal.7z as suggested in a previous post by @martinayotte

 

On top of it, I'm remotely running the mate desktop by means of tightvncserver.  I'm quite impressed by the responsiveness of the desktop, considered that I'm still using the sd card, and accessing the mate desktop over the (wired) network. Things at the moment seem to work quite well, apart from the browsers, both chromium and firefox. Browsing is very slow and after few minutes the whole desktop gets stuck, forcing me to kill the vncserver.

 

I hope I'll be able to do further tests this evening.

Link to comment
Share on other sites

1 hour ago, martinayotte said:

I've simply backed up old original firmware and replace it with the one provided in attachment ...

No mods needed to any config files ? What's the location of the files ?

 

Link to comment
Share on other sites

11 hours ago, martinayotte said:

No, except if you wish configs to use "old school method" in /etc/network/interface ...

Success I have WiFi thank you, I can't boot from the eMMc though despite running nand-sata-install - I get confirmation that the bootloader has been updated but it won't boot

 

Link to comment
Share on other sites

 

I finally managed to get the official buster desktop image for the nanopi-m4 fully working on the version 2 of this board too.

 

Basically, I extracted the working bootloader from the Armbian_5.99.191102_Rockpi-4b_Debian_buster_dev_5.3.0 image (which boots, but doesn't works well on the nanopi-m4 v2) and I burnt it to the https://dl.armbian.com/nanopim4/Debian_buster_default_desktop.7z image.

 

This morning I did some initial tests and it seems that everything is working well.

 

I have prepared a patched image you can try. At the moment, I've tested it only with an SD card, but I guess It'll work on the emmc too.

Download it from https://drive.google.com/open?id=1LaJIywiZnZUkLDZ9HkWrRtc0PyfiYGOL

 

You can also apply the patch by yourself:

 

1) download buster desktop image for nanoPi M4 (version 1) from Armbian's web site https://dl.armbian.com/nanopim4/Debian_buster_default_desktop.7z

2) extract and burn it to an SD card

3) apply the patch I have shared at the link above using the following command, changing sdX with the correct device:

sudo dd if=8M_after64ibs_uboot_working_rockpi4image_on_nanopim4v2.dd of=/dev/sdX seek=64

 

Let me know if it works for you too.

 

Link to comment
Share on other sites

7 hours ago, pask said:

I finally managed to get the official buster desktop image for the nanopi-m4 fully working on the version 2 of this board too.

 

Very nice. I tried your image and everything seems to work. Wifi works, eMMC works, sound, ... 
I think this is the better way to go forward. A lot less hasstle than converting the RockPi4 image to fit the M4V2. 
Great job.

Link to comment
Share on other sites

16 minutes ago, martinayotte said:

We need to add M4v2 flavour

The image also works on the M4. So maybe it's not needed to make a seperate one. But having a seperate one does spare us of having unexpted results if something goes bad later on.
I'll do some tests with different images/boards.
One thing didn't work, copying the filesystem to eMMC from sd-card. I had fomatted the eMMC, it was found after boot. It did copy everything, but didn't boot.(using armbian-config)
I then burned the image directly to eMMC and this worked flawlessly. Could be a one of fault, or could be that script would need an adjustment too for this.

Link to comment
Share on other sites

1 hour ago, NicoD said:

Could be a one of fault, or could be that script would need an adjustment too for this.

I don't remember exactly, but I think I faced something too. Maybe "nand-sata-install" choked seeing tons of android partitions, then I did "dd if=/dev/zero of=/dev/mmcblk2 count=2000" and restart "nand-sata-install" and it worked.

Link to comment
Share on other sites

13 hours ago, NicoD said:

The image also works on the M4. So maybe it's not needed to make a seperate one. But having a seperate one does spare us of having unexpted results if something goes bad later on.
I'll do some tests with different images/boards.
One thing didn't work, copying the filesystem to eMMC from sd-card. I had fomatted the eMMC, it was found after boot. It did copy everything, but didn't boot.(using armbian-config)
I then burned the image directly to eMMC and this worked flawlessly. Could be a one of fault, or could be that script would need an adjustment too for this.

Hi Nico,  my board (v2) boots this image fine from the SD card but not from eMMC - also I can't connect via UART ( just see rubbish on screen ) so have no idea why

 

Link to comment
Share on other sites

1 hour ago, pkfox said:

Hi Nico,  my board (v2) boots this image fine from the SD card but not from eMMC - also I can't connect via UART ( just see rubbish on screen ) so have no idea why

 

I had to apply the patch from pask on top of the emmc after using "nand-sata-install" to get it to boot, even after already applying it to the SD, I can only assume the bootloader it copies to the emmc is the unpatched variant.

 

After doing so it happily boots from emmc using nvme as root.

 

Using the minimal buster (4.4) build for the M4 with pask's patch everything seems to work as it should (wifi etc.)

Edited by nickngsr
adding kernel version
Link to comment
Share on other sites

43 minutes ago, nickngsr said:

I can only assume the bootloader it copies to the emmc is the unpatched variant.

 

Installer always use u-boot from package. If you haven't update that .... works as expected. 

Link to comment
Share on other sites

5 hours ago, pkfox said:

Hi Nico,  my board (v2) boots this image fine from the SD card but not from eMMC - also I can't connect via UART ( just see rubbish on screen ) so have no idea why

 

 

The rubbish data you see, could depend by not optimal baud rate configuration, by the chip that your usb-ttl dongle mounts, and by kernel driver support of this chip. The nanopi m4 (v2) needs an odd baud rate setting: 1.500.000bps. In my case, a dongle using a FTDI FT232RL chip, I found that under linux by means of 115200 and 9600bps settings, I was able to see kernel output but not the uboot one. 1500000 didn't even work. Before giving up, I did a try under windows, where It actually worked as expected.

Link to comment
Share on other sites

2 hours ago, martinayotte said:

I'm using latest "picocom" which is able to manage 1500000 baud under Linux without issues...

Perhaps the only serial terminal program I had not tried yet, It's the working one: I can confirm my dongle with the FTDI chip, works in linux too, at a rate of 1500000 baud using picocom. No special config needed.

thank you

Link to comment
Share on other sites

17 hours ago, pask said:

 

The rubbish data you see, could depend by not optimal baud rate configuration, by the chip that your usb-ttl dongle mounts, and by kernel driver support of this chip. The nanopi m4 (v2) needs an odd baud rate setting: 1.500.000bps. In my case, a dongle using a FTDI FT232RL chip, I found that under linux by means of 115200 and 9600bps settings, I was able to see kernel output but not the uboot one. 1500000 didn't even work. Before giving up, I did a try under windows, where It actually worked as expected.

I'm using Putty on a Win 10 box which works perfectly on my original M4's

 

Link to comment
Share on other sites

On 11/8/2019 at 11:23 AM, nickngsr said:

I had to apply the patch from pask on top of the emmc after using "nand-sata-install" to get it to boot, even after already applying it to the SD, I can only assume the bootloader it copies to the emmc is the unpatched variant.

 

After doing so it happily boots from emmc using nvme as root.

 

Using the minimal buster (4.4) build for the M4 with pask's patch everything seems to work as it should (wifi etc.)

 

How did you apply the patch ?

 

Link to comment
Share on other sites

43 minutes ago, pkfox said:

How did you apply the patch ?

 

I dd'd it directly to the emmc via usb after the 'nand-sata-install' completed.

 

I haven't checked but if you can ignore the shutdown/reboot at the end of the script you should be able to download @pask's patch and flash it to the emmc on the board itself

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines