Build me a methodology to Measure yarn consumption using PMW3360 sensor and an Arduino UNO

Job ID: 31183646

Budget: $100 – $200 USD

I would like to measure the yarn consumed while knitting using and optical sensor PMW3360 and an Arduino UNO. I would like to know the methodology and the code for the data analysing also pin connections. I need help as soon as possible.