Skip to content

Rane SL 4 driver 1.4.0

Choose a tag to compare

@ben-xo ben-xo released this 03 Dec 21:04
· 55 commits to main since this release
v1.4.0
e092e52

Install: download Rane-SL4-Installer-Mac-M1-M2-M3-M4.zip, unzip it and run Installer/Instalar-Rane-SL4.command, or open RaneSL4-macOS-Universal.pkg directly. Universal (Apple Silicon and Intel).

The SL 2 and SL 3 drivers' work (pepeleedj/Rane-SL2-Macos-ARM-Driver and Rane-SL3-Macos-ARM-Driver,
v1.4.0) ported to the SL 4, with the SL 4's protocol worked out from Rane's SL4 driver 2.0.1f1 and
firmware 1.02 (docs/SL4-COMMANDS.md). Tested on one SL 4 (firmware 1.02, its USB port B, an Apple
Silicon Mac) at 48 and 96 kHz, and with Serato DJ Pro 2.5.5, its timecode control (ABS, REL and THRU)
included: docs/SL4-AUDIO-ENGINE.md gives the results ("Results") and what is left to check ("Still
open"): the box's USB port A, two computers on ports A and B at once, an Intel Mac, and a real firmware
update.

Added

  • The SL 2 driver's low-latency engine in SL4Device.driver: deep-scheduled late-write playback,
    a timeline that follows the box's clock, capture placed on the timeline with gaps filled, the early
    capture read (with the SL 3's fill template, as the SL 4's pad byte is not known to be 0), input
    health and the input safety offset setting (sl4panel safety), stream teardown on the USB queue,
    and a debug build (make plugin DEBUG=1) with test hooks (sl4dbg).
  • The device follows the box's sample rate (48 or 96 kHz, chosen on the SL 4): read with 0x4A
    at connect and in the settle check, followed through a configuration change when the box reports a
    change (0x4B). Only the box's rate is offered.
  • Thru on all four decks (notes 0x5C–0x5F), the state dump at connect, and the decks' routing
    kept across a replug mid-stream.
  • Settle check: thru and the rate are checked again 2 s after the box is opened and 4 s after the
    Mac wakes.
  • The box's two USB ports: which one this Mac is on and whether a computer is on the other (0x45,
    and the 0x46 / 0x49 reports), in the status, sl4panel and the control panel.
  • Boot mode: a box in its firmware updater (bcdDevice 0x9900) is left to the firmware tools and
    reported in the status.
  • Output volume and mute, master and per channel (10), in the driver.
  • SL 4 Control Panel.app (macOS 13+): thru for decks 1–4, level meters, output volume, the sample
    rate, the USB ports, the input safety offset, and the firmware version in red when older than 1.02.
    Its icon, and the installer's background, are the SL 4's front and top panels as they are on the box.
  • Firmware tools (tools/firmware/): extract-sl4-firmware.py (from Rane's RaneSL4_2.0.1f1.pkg
    or its SL4Api, validated as Rane's IsValidFirmwareImage does), sl4flash (Rane's update
    sequence), and sl4dump (read-only status, and the flash summary table of a box in its updater).
  • Tests: make hwtest (the hardware tests in one run), tools/latency/ (round-trip latency and
    glitch tests), sl4apitest (SL4Api as Serato DJ Pro 2.5.5 calls it).
  • make package: the installer package and zip built from source, with no Rane binaries.
  • Docs: docs/SL4-AUDIO-ENGINE.md (design, bug catalogue, what to check on hardware),
    docs/SL4-COMMANDS.md (the box's protocol, image format and update sequence, from Rane's binaries),
    docs/usb-descriptors.txt, AGENTS.md.

Changed

  • SL4Api.framework matches Rane's 2.0.1f1 export for export (handles, return codes, signatures,
    callbacks from the box's reports, the bridge packets between the two ports' computers).
  • sl4panel works through the driver, so it works while the driver runs.
  • Channel names: Deck 1–4 and Aux, on channels 1–8 and 9–10 (measured on a box).
  • The box's interfaces are no longer offered to other drivers, and the driver takes the HID interface
    back if macOS's HID driver holds it.

Removed

  • 44.1 kHz and the 0x31 rate command (the SL 4 has neither).
  • The 0x37 heartbeat: the SL 4's USB chip answers it alone, and Rane's driver never sends it.
  • Rane's "SL 4 Audio Control Panel" System Settings pane from the installer (the app replaces it).

Fixed

  • No isochronous transaction list crosses a memory page: one that did could panic macOS in Apple's XHCI
    driver. Each list is a 256-byte block aligned to 256 bytes, which make plugin and make hwtest check
    (tools/check-txlists.sh).
  • 520-byte packets (13 frames, for 96 kHz) in place of 280.
  • The firmware version from 0x01 (0x10 and 0x04, from other Rane boxes, are not SL 4 commands).
  • The reported latency matches the measured round trip at 96 kHz too (the output stream's latency is
    0.6 ms, in place of 32 frames).
  • The SL 4 has its own HAL clock domain ('RAN4'), not the SL 2's, so macOS doesn't take an SL 2 and an
    SL 4 on one Mac as sharing a clock.
  • No stale audio at stream start: the box sends the end of the previous stream's audio again when
    capture restarts, and sometimes a packet of an odd length; the driver discards a stream's first
    millisecond of capture, and ignores packets that aren't whole frames of a size the box uses, as
    Rane's driver does.

Known issues

  • Moving the SAMPLE RATE switch while Serato DJ Pro 2.5.5 is running can leave Serato DJ Pro
    working at the old rate: the SL 4's outputs may then carry a continuous buzz, even with nothing
    playing, until the switch is moved back or Serato DJ Pro is restarted. Set SAMPLE RATE before
    starting Serato DJ Pro, or restart it after a change. The driver itself follows the switch: an app
    that keeps playing across the change gets clean output at the new rate.
  • After a USB replug while Serato DJ Pro is running, or when SAMPLE RATE changes, the decks can pass
    the turntable signal through for a fraction of a second before Serato takes them back. A later
    release removes this.

SHA-256

3d55c622d5655ae34ad718d2c8df0503da8b1061b5da509cec56a657b8b00569  RaneSL4-macOS-Universal.pkg
2aacb03c1e7c91791c00fac10c4831ec689aa35a63b8784d5ad10b59612ac3ec  Rane-SL4-Installer-Mac-M1-M2-M3-M4.zip