Forum Discussion

markgt's avatar
markgt
Icon for New Contributor rankNew Contributor
3 hours ago

SOLVED: BSP Editor NullPointerException on Debian 13 Linux

SOLVED:

BSP Editor "New BSP" menu command is grayed out, so can't make any new BSP's, and opening any existing one from another computer throws:

  • SEVERE: Available BSP type values for the --type argument are: []
  • SEVERE: BSP type "hal2" unknown.
  • SEVERE: NullPointerException

 

Based on other forum posts with a similar error, it seems like this is because the BSP Editor couldn't locate some of its own files.  That seems likely here too since this is the first time it's used on this computer.  But there's no problematic install path etc since I used the default.  THERE ARE NO SPACES IN THE INSTALL PATH NOR THE PROJECT PATH.  Everything else is working already for the Max 10:  I can generate with Platform Designer, synthesize with Quartus, program SRAM with SignalTap,  debug Nios V with RiscFree.  Details are:

Quartus Prime Lite 25.1std.0 Build 1129 10/21/2025 SC Lite

Patches: None

OS:  Debian 13.  This is what Ubuntu is based on, so it's very similar.  And like I said everything else already works.  USB came online already, not too hard.  All it took was the Altera udev rules file 92 as usual, and the correct LD_LIBRARY_PATH so jtagd could find its own shared libs.  

Installed quartus into regular user account, not whole system, not as root.  This is offered as an option in the installer if I recall correctly.

Install path is the installer's default:  /home/myuser/altera_lite/25.1std

The project files are irrelevant here, since BSP Editor is already off-track as soon as it launches.  "New BSP" is grayed out.

SOLVED:  BSP Editor is unable to find its own files without Altera's environment vars, which are provided when running inside niosv-shell.  That's nonsensical to me, since any brain-dead program off the street can detect where its own binary loaded from, on any OS, and walk up the path from there to find the rest of its files, as a default if no env vars were provided.  That's the first line of every binary or Tcl script I've ever written.  Quartus main GUI seems to do it exactly that way.  Anyone else struggling with this inexplicable rough edge should make sure your desktop's launcher icon invokes niosv-shell first, like this:

altera_lite/25.1std/niosv/bin/niosv-shell --run altera_lite/25.1std/niosv/bin/niosv-bsp-editor

To Altera:  if you're struggling to maintain or improve your software because it relies on Tcl, contact me through my forum account.  I could clean up a whole mess of rough edges like this one, and some other much-needed improvements.

No RepliesBe the first to reply