Hi, I'm testing the REW API. Cool idea! It looks like it should be possible to set the PEQ on a WiiM Ultra streamer automatically from REW measurements, for faster, "simpler" adjustments.
I am getting an error and this is just about error handling. If the measurement isn't selected in the GUI, REW throws an NPE (error dialog) during the import/EQ setup calls, and Match target then never reports completion. If you select it first, it's OK. Details below.
Environment: REW V5.40 Beta 135, Eclipse Adoptium JRE 17.0.20.1 64-bit, macOS 27.0.1, started with -api.
Steps to reproduce:
1. Start REW fresh with the API: open -a /Applications/REW/REW.app --args -api. No measurements are loaded, and GET /measurements/selected returns 0.
2. POST /application/blocking with body true.
3. POST /import/frequency-response-data with {"identifier":"npe-repro","isImpedance":false,"startFreq":20,"ppo":48,"magnitude":"<base64 BE float32[]>"}. This is a synthetic response from 20 Hz to 20 kHz. → Import … ID 1 completed
4. Don't select the measurement. GET /measurements/selected still returns 0.
5. POST /measurements/1/equaliser with {"manufacturer":"Generic","model":"Configurable PEQ"}. → Equaliser selected
6. PUT /measurements/1/target-settings with {"shape":"Full range"}. → Update processed
7. POST /measurements/1/eq/command with {"command":"Calculate target level"}. → Completed
8. POST /measurements/1/eq/command with {"command":"Match target"}.
Expected: Match target finishes and returns 200.
REW V5.40 Beta 135 running Eclipse Adoptium JRE 17.0.20.1 64-bit on OS X 27.0.1 Language en, country US, keyboard US, UTF-8 Screen 3840 x 1600 at 111 DPI Running in /Applications/REW
Message:
java.lang.NullPointerException: Cannot invoke "roomeqwizard.MeasData.getEqualiser()" because "this.K" is null
Stack Trace:
Cannot invoke "roomeqwizard.MeasData.getEqualiser()" because "this.K" is null
roomeqwizard.F.A.<init>(y:1047)
roomeqwizard.F.G.run(y:1349)