samer@34: function [y,phi]=block(o,phi,duty,f) samer@34: % block - generate square wave samer@34: samer@34: u=cumsum([phi,1./ceil(1./f)]); samer@34: y=mod(u(1:end-1),1)