Knitout is a language for controlling knitting machines. Knitout files are utf8 text files with linux line-endings. Each line of the file contains an operation and/or a comment.
All knitout files must begin with a magic string that indicates that knitout is the file format and specifies the version—;!knitout-VERSION
. (NOTE: it is important that this is the very first line of code; not even a ;comment
can precede it).
Next, a number of headers can be added, with the only required header being ;;Carriers:
.
Comments start with a semi-colon (e.g. ;a comment
); any text in that line of code that follows the semi-colon will be ignored.
Needle operations form or manipulate loops.
tuck
— adds a loop of to a needleknit
— pulls a loop through the loops on a needlesplit
— pulls a loop through the loops on a needle, transfer the loops to an aligned needleamiss
— (tuck with no yarns) pulls on the loops on a needle without otherwise influencing them (rarely used)drop
— (knit with no yarns) drops loops held on a needlexfer
— (split with no yarns) moves loops held on a needle to an aligned needleYarn operations control yarn carriers.
in
— bring a yarn carrier into action from grippersout
— bring a yarn carrier out of action with grippersinhook
— bring a yarn carrier into action using yarn holding hookreleasehook
— bring yarn holding hook out of actionouthook
— yarn carrier(s) into action using yarn holding hookmiss
— moves a yarn carrier past a given needleConfiguration operations Other Operations — adjust machine settings or state.
rack
— adjusts the alignment of the needle bedsstitch
— adjusts the stitch sizex-stitch-number
— sets the stitch size table index for knits, tucks, and splitsx-xfer-stitch-number
— sets the stitch size table index for transfersx-*
— other extension operations