Skip to content

PR#40 (M): Added buffer management for raw USB reads - #40

Merged
malikalhack merged 8 commits into
developmentfrom
11-add-buffer-management-for-raw-usb-reads
Sep 4, 2026
Merged

PR#40 (M): Added buffer management for raw USB reads#40
malikalhack merged 8 commits into
developmentfrom
11-add-buffer-management-for-raw-usb-reads

Conversation

@malikalhack

@malikalhack malikalhack commented Sep 4, 2026

Copy link
Copy Markdown
Owner

Linked Task

Closes #11

Commits

  • Updated Doxygen capture paths
  • Fixed queue Doxygen symbols
  • Updated architecture documentation
  • Documented tests directory
  • Updated gitignore file
  • Verified raw USB packet buffering
  • Added raw USB packet buffering
  • Added DRY and KISS rules

Author Checklist

  • added generated documentation;
  • added a description of the work completed to the history file;
  • successfully generated the documentation, and it meets expectations;
  • successfully compiled the library on Linux;

Testing

  • ./linux_build.sh -c -d
  • make debug
  • manual UI check

The build was performed on Linux Mint 21.3.

@malikalhack malikalhack added this to the Stage 3: USB layer milestone Sep 4, 2026
@malikalhack malikalhack self-assigned this Sep 4, 2026
@malikalhack malikalhack added the enhancement New feature or request label Sep 4, 2026
@malikalhack malikalhack linked an issue Sep 4, 2026 that may be closed by this pull request
@malikalhack

Copy link
Copy Markdown
Owner Author
  • Added a fixed-capacity FIFO between USB reads and packet processing.
  • Store each raw response with its actual transferred length and support the
    largest known two-channel DSO-2250 capture without allocation in the active
    acquisition loop.
  • Keep the USB producer non-blocking by discarding the oldest queued response
    when processing falls behind, with a thread-safe dropped-packet count.
  • Added a processing consumer that preserves the existing capture-state update
    while decoupling it from the USB polling thread.
  • Close the queue and wake the consumer during Stop and terminal USB errors;
    join both workers before releasing USB resources.
  • Added deterministic CTest coverage for FIFO order, response length, overflow,
    close/reset behavior, and concurrent producer-consumer operation.
  • Moved the expanded capture module into capture/inc/ and capture/src/.

@malikalhack
malikalhack merged commit 6b2425d into development Sep 4, 2026
1 check passed
@malikalhack
malikalhack deleted the 11-add-buffer-management-for-raw-usb-reads branch September 4, 2026 21:23
@malikalhack malikalhack added PR Pull Request and removed enhancement New feature or request labels Sep 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR Pull Request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add buffer management for raw USB reads

1 participant