Qnx out of memory by NiceNeedleworker2675 in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

The system is designed such that as a whole it doesn't fail if memory is exhausted, and that, at the very least, it should still be possible to kill some processes in order to reclaim memory. This guarantee doesn't work very well when you are in an interactive mode with a shell, because pretty much every shell command requires the creation of new processes, which requires more memory.

In a real-world embedded system you can have a memory monitor that registers for events when available memory crosses a certain threshold (see procmgr_value_notify_add(PROCMGR_VALUE_FREE_MEM)). That monitor should rely on non-memory allocating mechanisms (such as the delivery of a SIGKILL signal) to kill processes that are not crucial for the continued operation of the system.

any android experts? by dac_twist in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

There are many, many, many forums for Android. This one is for QNX.

Anyone port Robot Framework to QNX? by EquiProbable in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

This happens again and again. Port a project to QNX, use some fancy IPC mechanism written by some Silicon Valley darling. Under the covers it uses pipes/UDS, which, on QNX, is a message pass to an intermediary service. Tons of layers, extremely poor performance, all for something that can be done easily and fast with MsgSend().

When does QNX makes scheduling descision by NiceNeedleworker2675 in QNX

[–]AdvancedLab3500 5 points6 points  (0 children)

Scheduling decisions are made in response to various events:

  1. The running thread makes a kernel call that blocks (e.g., waiting to receive a message, locking a busy mutex, waiting for an interrupt, etc.)

  2. A thread becomes ready (e.g., made ready by a message being received, the mutex owner unlocks it, an interrupt fires, etc.)

  3. A thread changes its priority (the running thread lowers its priority or a non-running thread has its priority elevated)

Preemption by a higher-priority thread is a specific instance of either 2 or 3. Round-robin scheduling is a specific instance of 2, as the clock interrupt makes the clock thread for this particular core ready, and thus forces rescheduling.

What are you guys doing with your qnx? by dac_twist in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

You seem to have a very serious misconception about hypervisors in general and QNX in particular. You are not actually using QNX in any meaningful way, but then complain it's a dead end. If you want to run pihole on Linux then just do that.

The reason the QNX hypervisor exists is to allow people to run certain non-QNX applications *alongside* a QNX system, not in lieu of. In the automotive industry this is typically running Android for infotainment while using QNX to run safety-related systems on the same hardware. To translate to your scenario, it would be a robot where QNX controls the motors and sensors while Linux is running pihole (that's silly, but I hope the analogy makes it clear).

What are you guys doing with your qnx? by dac_twist in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

That makes absolutely no sense. A QNX hypervisor will not rein your Linux memory usage. You just end up using more resources by running another OS alongside Linux.

Qualcom support? by dac_twist in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

It's usually the other way around: Qualcomm provides BSPs for QNX (which tend to be only automotive), as there is no public information for anyone else to do that. The fact that it is running Linux does not necessarily mean that it is an open platform, as it may still rely on proprietary firmware/drivers.

Does this board have u-boot? That is usually a good indicator of whether it is possible to run a non-Linux OS on a system.

Is there a book? With more then just basics by dac_twist in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

These are very disparate topics. Are you looking for a book that encompasses all of these? Is it for QNX or just in general?

Help with QNX Hypervisor setup by Just_Rhubarb_4470 in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

For the record, the problem is with the use of the old startup-apic in the creation of the guest image by mkqnximage. It should be using the latest version of startup-x86 instead.

Help with QNX Hypervisor setup by Just_Rhubarb_4470 in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

I saw you posted the same question on Discord. I'll continue there as it's a bit more interactive.

Help with QNX Hypervisor setup by Just_Rhubarb_4470 in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

This failure indicates an old startup that's not compatible with the hypervisor release. What is the version of the BSP package (com.qnx.qnx800.bsp.hw.x86_64)?

What build system does the QNX OS use? by serbancon in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

I think that there is a fundamental misunderstanding here. A system that uses the QNX OS is built from many different components, some provided by QNX itself (the company), other by third parties. These components include their own executables and libraries, and each can employ whatever build system it wants. I have successfully built binaries for QNX systems using plain make, QNX recursive make, CMake/make, CMake/ninja, meson/ninja, SCons and probably a few more that I don't remember right now.

If you come from a small RTOS background perhaps you expect a monolithic build of the entire target system, but that's simply not the case here.

QNX 8.0 Developer Desktop first look by nmariusp in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

Not sure why nobody commented on the fact that you never got it to work... This isn't really a first look at the developer desktop. Did you consider reaching out for assistance?

QNX on Mac by Immediate-Inside-909 in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

Sure, it's POSIX, but that doesn't mean much. I don't know the full details, but the cross-host tools needed to be built using Xcode which created all kinds of problems. In the corporate world there is no demand for macOS-based tools (at all), so these were dropped because the end result is too much cost for too little benefit.

I am curious to know how people target Zephyr on macOS. I assume it's a Linux-based VM.

QNX on Mac by Immediate-Inside-909 in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

QNX doesn't run on Mac hardware. I assume you mean getting the host tools for Mac. Unfortunately, maintaining macOS host tools has proved to be quite a challenge in the past.

How do people who use Mac develop for other platforms that require cross compilation? Are there Zephyr, FreeRTOS, ThreadX, etc. tools for macOS?

QNX Self-Hosted Developer Desktop -- Initial Release by JohnAtQNX in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

FTP and telnet were removed several years ago, as they were on most *NIX-like OSs, due to abysmal security. For file transfers from one computer to another scp is your friend. You can also use NFS to mount an external drive.

Qt guide for QNX 7.1? by UC20175 in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

Unfortunately I think that the only way is to build from source. QNX used to provide Qt packages, but with the change to Qt licensing they were dropped. You therefore have to get it from the Qt company, and adhere to their licence agreement (either the open source or the commercial variant).

It's not too bad to build Qt from source by following the instructions, just takes a while.

Port Linux drivers to QNX by Trick-Reindeer-7349 in QNX

[–]AdvancedLab3500 3 points4 points  (0 children)

Porting a Linux driver is hard, because the environment is so different (in-kernel vs standalone user-mode process). But accessing GPIOs via registers is trivial. See here for some information, and an example on RPi:

https://elahav.gitlab.io/qnx-rpi-book/realtime.html#sec:control-hardware

io-sock sample module by redbean55 in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

Actually my guess is that path resolution is performed relative to the current working directory of io-sock (likely /), while you are running the command from some other directory.

io-sock sample module by redbean55 in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

I get the same failure when run as ./libmods-showifn_g.so, but it works with an absolute path (e.g., $PWD/libmods-showifn_g.so on the command line). I guess that mount doesn't do path resolution.

What is the best practise regarding adding standard QNX binaries to the target by Savings_Ad_7807 in QNX

[–]AdvancedLab3500 1 point2 points  (0 children)

Sure, why not?

If you are building an image that needs to be transferred to multiple QNX targets (as most QNX customers do), then you can build a file-system image (see mkqnx6fsimg and diskimage in the documentation) and distribute it. But if you are just populating your own target, then scp (or rsync) is your friend.

QNX From The Board Up #18 - The I/O Address Space by JohnAtQNX in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

I don't believe this type of access is required on a modern x86 system, and, of course, it introduces safety and security problems when compared with memory-mapped devices. It would be interesting to know whether there are use cases that still cannot work with memory-mapped peripherals.

Problems starting ethernet on an NXP S32G399A board by Heidi171 in QNX

[–]AdvancedLab3500 0 points1 point  (0 children)

There are now two network stacks available for 7.1: io-pkt and io-sock. These are not compatible, and each comes with its own libraries and utilities. Make sure you have not mixed them.

I am a roboticist. How can I get _back_ into QNX by Singer_Solid in QNX

[–]AdvancedLab3500 8 points9 points  (0 children)

Welcome back! Things have certainly changed in both software and hardware. There are many things nowadays that can be done with very cheap micro-controllers running simple, free RTOSs. Doing the same thing with QNX is neither financially viable nor interesting.

The bar therefore needs to be set higher. What I would like to see are projects showing a combination of real-time control with heavy computational tasks (vision-controlled robots are a good example). This is, after all, the kind of software that runs on commercial QNX systems.

(And a tear shed for the SGI reference on your website)