This project shows how to create a square / puls wave with two sawtooths, one of them inversed. Set the volume to 1 and the offset to 0.5, then you have a square. And set the volume to 0 and you have a sawtooth.
It's basicly a copy of this: https://scratch.mit.edu/projects/412400346/ which is a copy of this: https://scratch.mit.edu/projects/412396362/