Skip to navigation


Utility routines: CopyWorkToPoint

Name: CopyWorkToPoint [Show more] Type: Subroutine Category: Utility routines Summary: Copy a point from the variable workspace to the point tables Deep dive: Multi-byte variables
Arguments: X The low byte of the x-coordinate of the 16-bit workspace point to copy: * LO(xTurnHi) = (xTurn, yTurn, zTurn) * LO(xVelocityHi) = (xVelocity, yVelocity, zVelocity) * LO(xTemp2Lo) = (xTemp2, yTemp2, zTemp2) * LO(xPlaneLo) = (xPlane, yPlane, zPlane) Y The ID of the point to update in the point tables
.CopyWorkToPoint LDA xTurnHi,X \ Copy the X-th coordinate in the variable workspace to STA xPointLo,Y \ the Y-th point coordinate, starting with the low bytes LDA yTurnHi,X STA yPointLo,Y LDA zTurnHi,X STA zPointLo,Y LDA xTurnTop,X \ And then the high bytes STA xPointHi,Y LDA yTurnTop,X STA yPointHi,Y LDA zTurnTop,X STA zPointHi,Y RTS \ Return from the subroutine