开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

Re: sBitx CPU load


 

On Fri, Dec 22, 2023 at 11:29 PM, Steve Beckman wrote:
Funny you mentioned this - I finally upgraded to software V3 (like it!!) and noticed the very same thing. The sBitx was set to decode FT8 on 20m, and I ssh'ed in from another computer and watched the processes with htop. One of the sbitx processes would ramp up in CPU usage over a period of about 80 seconds until it got to as much as 110%, then fairly abruptly drop down again.
I spent a little time working on this tonight but didn't reach any conclusions.

A set of simple code changes that may help are in this?.

It gives each thread we create a name, which is helpful for htop, ps, gdb, etc.

Then in htop you can do:
  • F2 -> Display Options -> "Display threads in different color" -> [X]
  • F2 -> Display Options -> "Show custom thread names" -> [X
  • F2 -> Display Options -> "Hide userland process threads" -> [_]
  • F2 -> Display Options -> "Hide kernel threads" -> [_]

This lets you see each thread.

I end up with something that looks like:


Note I prefer monochrome for htop.

Maybe this can help you understand the spikes in CPU usage you are seeing.

sbitx_sound_th is the thread that runs rx_process() which does what Farhan says, copies samples out of the RX buffers.

It uses a lot of CPU.

There are two threads called sbitx in the output that are created by the WiringPi library, but they are not using any CPU.

I didn't bother trying to find a way to give them a name.

--
Regards,
Dave, N1AI

Join [email protected] to automatically receive all group messages.