====== WSUB, DWSUB ====== ''WSUB s1, s2, d'' \\ ''DWSUB s1, s2, d'' These commands subtracts s2 from s1 and store the result in d. WADD subtracts word values and DWADD subtracts double word values. | |P |M |F |S |C |T |D |Constants| |s1 | | | | |O |O |O |O| |s2 | | | | |O |O |O |O| |d | | | | |O |O |O | | {{ :cubloc:wsub_dwsub:wsub.png?nolink |}} In the ladder above, D1 will get 95. [[cubloc:index#Ladder_Logic:|Go CUBLOC Ladder Logic home]]