How to use analogWave lib to output my own waveform

I'm trying to use the analogWave library to output a simple waveform by using the constructor that takes an array of wave values as an arg:

analogWave(pin_size_t pinNumber, uint16_t *_buffer, uint32_t _size, uint32_t _offset);

I just want to output a simple square wave (0 or 5V) to generate a PWM signal at a fairly high frequency. So I call the constructor, with an array of 10 samples (using values of either 0 or 255), then call:

analogWave.begin(float freq_hz);

I have tried calling analogWave.amplitude, with values of 1.0 or0.99, but that has no effect.

I get no output. I can see output if I use the analogWave.square method to load a square wave. (I am detecting output by running a motor driver that accepts a PWM signal. I don't have an oscilloscope.) That seems to work, but I have no way of varying the signal.

So my question is how do I use this functionality? Is 255 not the correct value for the height of a square wave? (I want 5V, using a UNO R4 wifi board.)

Time to read the forum guide.

Oops. I did find a relevant similar topic that allowed me to solve my problem. I just needed to set the max value of the waveform to 65535 rather than 255. I was assuming 8 bit, when I needed to think 16 bit.