Hands-on experience with StarFive VisionFive 2 RISC-V SBC using Debian 12

StarFive sent me one of their VisionFive 2 RISC-V SBC for evaluation and review. I got the model with dual Gigabit Ethernet and 8GB RAM, and I’ll report my experience with the Debian 12 “bookworm” image. But note that won’t exactly be a review since the board is unreviewable at this time. It’s really for early adopters and there are many issues to solve, and in this post, I’ll report what works and what doesn’t, and some of the challenges I encountered just to install the OS…

VisionFive 2 unboxing

The board comes in a package that reads “Embrace change, embrace the future”.

StarFive VisionFive 2 SBC package

The bottom side has some useful links and QR codes, and what you’ll want is the GitHub repository with the source code and instructions to build the image from source (Note: Ubuntu 16.04, 18.04, or 20.04 x86_64 recommended), as well as the RVspace forum section for the board where we’ll find instructions to get started and feedback from other users.

VisionFive 2 community GitHub

The board layout and components look exactly the same as when launched on Kickstarter, except my board is VisionFive 2 V1.3B.

StarFive JH7110 RISC-V SBC
We’ve got the StarFive JH7110 quad-core RISC-V processor in the center, BIWIN BWMZCX32H2A-64G 8GB RAM chip, a VL805 PCIe to USB 3.0 bridge like in the Raspberry Pi 4, two MotorComm YT8531C Gigabit Ethernet transceivers, and an AXP15060 PMIC. All main ports are on one side with a 3.5mm audio jack, four USB 3.0 ports, HDMI 2.0 output, and two Gigabit Ethernet ports.

StarFive VisionFive 2 eMMC flash module M.2 socket

The bottom side comes with a MicroSD card socket which we’ll use to boot the OS, connectors for an eMMC flash module, and an M.2 socket for an NVMe SSD.

Installing Debian 12 on VisionFive 2 SBC

Debian images are available on the StarFive website linking to either Baidu Drive or Google Drive. The latest image is currently Image-69 released at the end of December

The uncompressed image would not fit in my 8GB MicroSD card, so I flashed it to a 32GB MicroSD card which took close to 45 minutes to complete. I think it may be about to die, and I may have to buy yet another batch of cards. All this wasted time getting MicroSD cards that only last a few months is partially why I’ve always disliked boards that only boot with a MicroSD card

StarFive VisionFive 2 review

I then connected a USB keyboard, a USB mouse, an Ethernet cable, and a USB Type-C power adapter. I initially went with a 5V/2A, but that’s not a good idea, since it does not provide enough power and the board will continuously boot loop. A 5V/3A Raspberry Pi power adapter did not cut it either, so I went with a 100W GaN power adapter to make sure I had no power-related problem. Oh, and I added some spacer to elevate the board since this is recommended.

But then I noticed the board would not boot, and found the Image 69 announcement in the forums that explains:

Please update latest SPL 46 and U-Boot 44 binaries by following Guide: 4.3 charpter 77 before running this Debian image. this is very important.

Finding the proper documentation took a while, since it’s spread all over the place in Chinese and/or English, but the best place to go is the Document Publish Status page with documentation in English. It’s possible to log in through SSH, but considering the likelihood of having a boot issue, I’d really recommend connecting a serial debug board which is how I found out about the boot loop issue mentioned above.

VisionFive 2 Serial Console

Before installing Debian 12, we’ll need to update the SPL and U-boot bootloader on the VisionFive 2, and use the sdcard.img minimal Linux image as well. We’ll find those on GitHub, and I used the files part of VisionFive2 Software v2.8.0. The first step was to flash sdcard.img to a MicroSD card. This image fits into an 8GB card.


We can log in with the username “root” and the password “starfive”. Here’s the boot log for inquiring minds.

Let’s make sure we are connected to the network:


All good. We can now download the latest SPL and U-boot binaries from GitHub and transfer them to the board via SCP from your host machine:


Back in the VisionFive 2 terminal, we can check the partitions:


It looks good, so let’s update the SPL binary with flashcp utility:


and then U-boot:


Power off the VisionFive 2 board and replace the MicroSD card with the one with the Debian 12 image. I could boot the image “successfully”.

But the first boot did take over 3 minutes, so you may have to be patient:


Subsequent boots are faster at around 90 seconds.

Another issue is that the TV screen is black although my TV detects the HDMI cable is connected, and there’s some activity about HDMI in the serial console:


I moved to another location and tried with another display and it did not work at all. But that’s because my MicroSD card apparently failed:


I had to take a MicroSD card from my security camera to carry on and purchased five Class A1 MicroSD cards online for future reviews…

I could boot normally, but I had the same problem black HDMI screen issue. I think I know why:


There’s a segmentation fault… Other people had a similar issue with either a black screen with a mouse pointer or a black screen without a mouse pointer. We’re told that’s because 4K displays are not supported yet, and this can be worked around by forcing 1920×1080 in lightdm configuration (/etc/lightdm/lightdm.conf) adding the following line under [Seat:*]:


My displays are already 1920×1080 or 1280×800, and I did not work for me. So I posted an entry in the forum and you can follow the progress from there.

Anyway, in this part of the VisionFive 2 review, I’ll only test headless Linux, and I will probably write a second part once a new Debian image is released and I can access the graphical user interface.

VisionFive 2 system info

We can check out the system information with a few commands:


It seems everything is detected properly with the JH7110 quad-core CPU, 8GB RAM, 32GB SD card, and drivers for display, audio, and Ethernet.

VisionFive 2 features testing

We can’t test HDMI or other video or graphics-related features with this image since it’s not working with any of my monitors, but we can still check headless features.

GPIO

GPIOs are showing up in sysfs :


Let’s try to toggle GPIO 44 (pin 40 on the GPIO header):


I could measure 3.27V with a multimeter with leads placed on pins 40 and 39. Let’s change the value to zero


My multimeter reports 0.00V. GPIO is a pass. You’ll find how to use I2C, SPI, PWM, and UART interfaces in the documentation.

Ethernet

Let’s carry on by testing the two Gigabit Ethernet ports with iperf3 installed with apt.

LAN1 (edge of board):

  • Upload:

  • Download:

  • Full-duplex (bidrectional):


Results are perfect in either direction, but lower than the max with full-duplex. Those are however similar results as on some Arm platforms such as Khadas VIM4 SBC.

LAN2 (Next to HDMI port):

  • Download:

  • Upload:


Full-duplex:


It’s pretty much the same as the other Ethernet port, and that’s a pass as well…

M.2 NVMe storage

I installed a 256GB Apacer M.2 2280 PCIe Gen3 x4 SSD (AS2280P4) in the M.2 socket on the bottom of the board, and it’s detected properly:


iozone3 is not available through apt, so I had to download it and build it from source:


There’s no RISC-V option in the Makefile, so I first tried to use “make linux”, but the build failed while linking. “make linux-arm” did complete, so we’ll use that…


The SSD is supposed to support up to 1,800 MB/s read speeds and 1,100 MB/s write speeds. So at 169MB/s and 158MB/s that does not cut it at all. I previously tested it at 1100 MB/s with ORICO Thunderbolt/USB enclosure connected to an Intel mini PC. Repeating the test on the VisionFive 2 yields the same low speeds.

Here’s the output for lscpi for reference:


It does not show the link speed, but if we check a more verbose output it shows:


That one would be a failure for now, since the performance is way too low.

USB

Let shut down the board, remove the M.2 NVMe SSD, and put it into the ORICO enclosure mentioned above. Now let’s connect the USB SSD enclosure and boot the board again and

This is what the output of lsusb looks like with the USB enclosure, keyboard, and mouse:


Let’s now run iozone:


The numbers are strangely close to the ones when connected to the M.2 socket. 173MB/s writes and 152MB/s reads… That should be closer to 300 to 400MB/s on a USB 3.0 port at 5 Gbps. It’s also possible iozone3 requires some optimizations for RISC-V but I view this as unlikely.

Audio jack

While we can’t test HDMI audio right now, we can still try the 3.5mm audio jack by connecting a pair of speakers powered by one of the USB ports from the board. USB is only for power, and the audio comes from the 3.5mm jack.

VisionFive 2 speakers

I used the preinstalled ffplay to play some license-free MP3:


It works fine, but the audio was saturated at full volume. There was no such issue after lowering the speakers’ volume.

Let’s add some comments about the MicroSD card. The cards have used have poor random I/O performance, but I could use those with Raspberry Pi and other SBCs without much difficulty. But with the Debian 12 image used in VisionFive 2, just typing commands in the terminal can be really, even a simple “ls” in the root directory can take 10 seconds to complete.


I also have to wait around 5 to 10 minutes before I can go through the login prompt “starfive login: root” and start typing commands. Having a higher-performance MicroSD card or using an eMMC module would certainly help, but I’m pretty sure the Debian image also needs to be optimized in that regard.

SBC Bench benchmarks

I’m usually running sbc-bench.sh script to evaluate the performance of single board computers and mini PCs. RISC-V is a pretty new platform, so I did not much hope it would work smoothly, but I tried anyway.


The information view works well. There’s a lot of activity and I/Os here because a package is being installed in another terminal window.

But even during idle SBC bench will not start because of a high CPU load:


There are also two other warnings. The first one is that the script has not been tested on the yet-to-be-released Debian 12 “Bookworm”. The second is because dmesg output is truncated and not starting from 00:00. I’m not going to reboot, as it takes around 8 minutes for a complete boot cycle to the point after I log in and access the command prompt. Let’s disable CPU load average checking, and restart the script to see how far it can go:


The 7-zip package is not part of the Debian RISCV64 repository and it would have to be built from source to run on the VisionFive 2 board. So at this point in time, it’s not possible to run SBC Bench without skipping a few tests. Let’s revisit it in a few months.

Conclusion

StarFive VisionFive 2 should be viewed as a RISC-V development board at this stage, and it’s not suitable for integration into projects/products until further progress is made on the software side. Since since Linux RISC-V is still pretty new, especially from a video/graphics point of view, it should be expected. There are already features that work fine such as Gigabit Ethernet, GPIOs, the audio jack, and USB, but others like HDMI and storage performance still need a lot of work. System stability needs to be improved too since my SSH connection dropped a few times and I was unable to reconnect, nor did the serial console work, requiring a hard reboot. But I can see a decent amount of activity in the forums and the company is working on mainlining the Linux kernel.

I’d like to thank StarFive for sending the board. Developers who want to help with software and/or testing can purchase the VisionFive 2 SBC reviewed here for $70.40 plus shipping (and potentially taxes). The board is also offered on Amazon for $112 with WiFi.

Share this:
FacebookTwitterHacker NewsSlashdotRedditLinkedInPinterestFlipboardMeWeLineEmailShare

Support CNX Software! Donate via cryptocurrencies or become a Patron on Patreon

ROCK Pi 4C Plus

44 Replies to “Hands-on experience with StarFive VisionFive 2 RISC-V SBC using Debian 12”

    1. Image-55 should work without updating the SPL and U-boot, but I haven’t tried it and I don’t feel like trying it based on the status of the newer Image-69. Right now, I plan to give it a try again in the summer months.

    2. I tried the 55 image.

      Nothing works:

      Tried to compile my own C++ software that compiles fine on (Raspberry/Jetson) it can’t find the deps.
      Tried to download the risc-V JDK to test my other MMO client, the download locks the core so the kernel warns a core is stuck.

      This is a dud. And I could say “so far” but I have enough experience with these things that unless Imagination releases EVERYTHING so we can make our own OS legally on this thing it probably won’t reach stable/usable state and since the CPU is NOT more performant than Raspberry 4 per watt (this is from intuition just trying to run commands and touching the SoC) the only thing this COULD have working for it is the GPU but unless it’s twice as powerful as the GPU in the Raspberry 4 it won’t compensate for the CPU weakness.

      1. With regards to power consumption, I get 5W at idle with Ethernet, USB mouse, and USB keyboard. Nothing else. So it’s not the most efficient, but we already had a cue with the board unable to boot with a 5V/2A power supply.

  1. How does the output from cat /sys/module/pcie_aspm/parameters/policy look like right now?

    And wrt sbc-bench: there’s a new -r (review) switch with v0.9.18 that tries to collect performance relevant settings and then tunes them to max performance to rule out the usual ‘issues’ when dealing with a new board like all those settings being set to whatever since so far nobody took care of them.

    1. Note the M.2 SSD is not connected since I moved it into the USB enclosure. The file is not found:

      root@starfive:~# cat /sys/module/pcie_aspm/parameters/policy
      cat: /sys/module/pcie_aspm/parameters/policy: No such file or directory

      1. Ah, just realized that you’ve put ‘lspci -vv’ output also online. For each PCIe device it reads ‘ASPM Disabled’ so at least power management is not the culprit of slow NVMe speeds. And it also explains partially the high idle consumption (see RPi 4B in the beginning and after VL805 firmware update).

        And since everything USB3 here is PCie attached as long as the PCIe bottleneck hasn’t been found/fixed, USB3 performance will always be low(er).

  2. > The 7-zip package is not part of the Debian RISCV64 repository

    That’s a bit surprising since I have several JH7110 sbc-bench results collected and all of them contain 7-ZIP MIPS while none of the submitters reported any trouble installing stuff. The numbers at 1.5 GHz look all the same like the ‘StarFive VisionFive V2’ entry in results collection.

  3. > The [USB3] numbers are strangely close to the ones when connected to the M.2 socket.

    AFAIK JH7110 features two PCIe lanes of which one is pinmuxed with ‘native USB3’. But this board seems to use a PCIe attached VIA VL805 USB3 host controller (same thing as on RPi 4B) and according to dmesg your USB peripherals are behind this controller.

    As such in case crappy settings are defined (‘pcie_aspm = [super]powersave’ for example) USB storage inherits them to just add another layer of overhead and performance loss to it.

    1. Potentially yes, worst case you would need a kernel on a suppoted storage like i.e. SD card or SPI flash to lower the efforts

  4. nice research! the screen dumps are a lot of work, but they contribute fine detail missing in most articles. Thanks for the effort.

  5. I love this blog, but this review is extremely wrong and unfortunately misleading on several fronts. I got my VisionFive2 about 3 weeks ago and my experience is almost the exact opposite. It sounds like your SD card was almost complete junk and maybe the root of many of your problems.

    I was using a quality Samsung SD card and the install & snappiness of the system was exactly what I expected and quite impressive for a new architecture. I have no idea why your M.2. results were so off from mine either. Mine were probably 2-3x yours and again exactly what I’d expect from a 1xPCIE lane. They mirrored the performance I get from an RPI4 via USB. But you guys need to remember, this is simply a 1xPCIE lane. In fact, my Orange Pi 5 gets the same performance too. The nice part is that its on the same board and much easier to package up than a clunky USB dongle I have to do off RPI4s.

    If I could post a counter-blog to this one, I’m happy to write one up, and have it countered to this particular review.

    1. I just reported the findings based on the hardware I have. Others can have a different experience since they’d use a different monitor and storage devices.

      “It works for me” is just not good enough. I once had a problem with ODROID-XU3 Lite that would not work with my TV. ODROID helped me find a workaround, and even purchased the exact same TV model to fix the issue in their office. More exactly, they purchased my TV, since they could not source it in South Korea…

    2. I already weeks ago reported a very similar result (IIRC I peaked at ~ 180 MB/s streaming out of a very fast Samsung NVMe). The PCIe interface is underperforming as several have found.

      Jean-Luc’s experience agrees with mine, except for the SDcard issues and the 45 min. And indeed my monitor isn’t working either. However, if you need the card for developing RISC-V software, then it’s already working fine. It’s just not quite ready yet to be a Raspberry Pi replacement.

    3. Used NVME drive is really fast and optimized for PCIE3 x4.
      Using a PCIE2 drive would be a better test.
      Support link rate of 2.5, 5.0 GT/s per lane. (havent tested mine yet)

  6. A lot of tests, but nothing about GPU OpenGL/OpenGL ES/Vulkan drivers support. Can you test something like glmark2/glmark2-es/vkmark ?

    1. Read the article, video out is not working, plans are to retest a later version of the image in a couple of months…

  7. That’s strange (or I’m missing something), because I watched videos from a YouTube channel and video out is working and the user even tried some games (TyrQuake on the last video).

    1. No video output. But its hit-and-miss, some people have no issues, others can fix it after modifying LightDM config file, but nothing worked with my display and TV so far.

  8. Actually, I got a good video output experience when using VisionFive 2. And
    according to the post, I can’t see the specific reason temporarily

  9. 8GB, v1.3B. Using Image 69, my 4K TV displays a black image over HDMI with a white mouse pointer in the center of the screen. The video driver might not be configured to support 4K.
    WiFi not working with Image 69, but different users are trying to compile the kernel module. NVME works.
    Overall, the board is responsive.

    1. Since you have a 4K display, you should try to edit lightdm.conf as explained in the post, if you haven’t already done so.

  10. > iozone3 is not available through apt

    That’s since the repo isn’t enabled. On Debian you need to ‘apt-add-repository non-free’ while on Ubuntu it’s ‘apt-add-repository multiverse’. And if ‘apt-add-repository’ isn’t available you would need to install ‘software-properties-common’ first or fiddle around manually below /etc/apt/ in a sources list.

  11. For compiling iozone built-essential (without s) is needed,
    runs with several errors/warnings so it may be not good for comparison :/

  12. Your microSD slowness is a you problem. Not sure what cards you are using, but small cards are going to be slow. Use larger cards for SBCs even if you don’t need the capacity.

    There is a problem with microSD in that the only supported speed right now is high speed, limiting effective max rate to ~20MB/s. Hopefully this will be updated soon to support higher speeds.

    PCIe performance is really weak on this SoC. I hope this can be improved.

    The description of this being a development board is apt and seems to be what VisionFive was going for. This isn’t a general purpose machine yet. Too many issues: closed, hacky and buggy GPU drivers, slow bus performance on multiple buses, hacky firmware update routine, not enough mainlined yet. But it’s affordable, and for me it’s been fun to play with.

    1. The package of my microSD cards reads “Samsung PRO Endurance 32GB microSDHC UDS-I card” and they are rated “Class 10”, but I think I bought a bunch of fake Samsung cards.
      They do work OK with my security cameras though.

      1. How old are they? If they are somewhat recent (last 3-5 years), they should be more than fast enough and reliable. The latest version I think came out in 2021 or 2022 and is really great. I have used many of these same cards from 32-256GB over the years and they’ve all worked well, though 32GB was certainly slower than the rest.

        They very well may be fakes.What are the oemid, name, hwrev etc? (/sys/block/mmcblk1/device)

        1. I bought them in August 2022.

          It decodes as:

          Samsung ID should be 0x1B, so it definitely looks fake. I used the instructions and info from a previous article: https://www.cnx-software.com/2017/06/13/micro-sd-cards-for-development-boards-classes-tools-benchmarks-reliability-and-tips-tricks/

          1. > cat /sys/block/mmcblk0/device/cid

            Since you’re doing this on Linux there’s no need to look at the CID since the details are already decoded (at least with recent kernels). See this example (preparing a device review mode the last weeks).

            So this should work right away: grep . /sys/block/mmcblk0/device/*

          2. Still curious about output from this since the kernel code should detect the CRC mismatches as well and hopefully the sysfs values are an indication of this (at least a bit easier than dealing with CRC7/CRC16 and implement an own check):

            grep . /sys/block/mmcblk0/device/* | grep -v serial

          3. Output from the command:

            It looks like a different card than the one from yesterday, as that one is back into the security camera. I would have expected a similar output though are both came together and are of the same “brand/model”.

          4. Thanks! If time permits and you give latest sbc-bench from Github a try, an ‘sbc-bench -r’ (new review mode) should label your first card as ‘Probable counterfeit’ and the new one as ‘Definite counterfeit’

          5. BTW: maybe there is an easy way to spot fakes. Can you please post the contents of these two values from the fake Samsung card:

          6. Here’s the output for one of the cards:

      2. Yes Jean-Luc, Samsung are some of the most faked cards but the authentic product is very nice.

        I even have a fake Samsung Pro SSD

  13. So, for the SD card issues…. I too have many pi and many failed SD cards. I have found that the key to not having cards randomly die is to buy high write endurance cards. They are far more expensive, but much better in the long run.

Leave a Reply

Your email address will not be published. Required fields are marked *

Khadas VIM4 SBC
Khadas VIM4 SBC