Add GrblSerialSimpleDriver (ping-pong protocol)#263
Merged
Conversation
knipknap
force-pushed
the
feat/grbl-simple-serial-driver
branch
from
June 4, 2026 17:49
cdfba84 to
ff4f5be
Compare
Implements a minimal GRBL serial driver that sends one G-code line at a time and waits for 'ok' before proceeding. No character-counting buffer management, no deadlock detection, no buffer stall recovery. Key differences from GrblSerialDriver: - Uses raw SerialTransport instead of GrblSerialTransport - No RX buffer tracking or backpressure - Strict ping-pong: send -> wait ok -> send next - Simpler connection loop with handshake detection - No command queue or interactive/queued command separation - Marked as EXPERIMENTAL maturity level Useful for devices where the advanced buffer-counting protocol causes issues (false ALARM:3, communication errors, etc.).
- Make cleanup() async to match Driver base class - Make _start_job() sync (not async) like GrblSerialDriver - Add assert for machine.dialect None check in create_encoder - Fix parse_state() call to pass required default arg - Remove invalid pos_x/pos_y assignments (use parse_state instead) - Fix alarm_code_to_device_error() to pass single alarm_code arg
knipknap
force-pushed
the
feat/grbl-simple-serial-driver
branch
from
June 9, 2026 16:14
ff4f5be to
96e5383
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new
GrblSerialSimpleDriverthat uses the simplest possible GRBL communication strategy: send one G-code line, wait forok, send the next. No character-counting buffer management, no deadlock detection, no buffer stall recovery.Motivation
Some users experience persistent communication issues with the advanced
GrblSerialDriver(false ALARM:3 errors, buffer desync, etc.) as documented in #256. This driver provides an alternative that trades throughput for robustness — since there is no buffer management, there is nothing to desynchronize.Key Differences from
GrblSerialDriverGrblSerialTransport(buffer counting)SerialTransportok)What's Included
rayforge/machine/driver/grbl/grbl_serial_simple.pygrbl/__init__.pyanddriver/__init__.pygrbl_utilhelpersTesting
Related: #256