BTT V2.0 Smart Filament Sensor on Taz 6 with Archim 2

I’m installing a Big Tree Tech V2 Smart Filament Sensor on my Taz 6 which has an Archim2 board and is running DrunkenOctopus. Looking at the wiring guide for DO, I see that I can use pins 15 and 16 of the GPIO header for filament runout sensors 1 & 2 respectively. The BTTV2 sensor has two outputs (pull up), a motion sensor (PC2) and a switch sensor (PA0). PA0 goes to low when no filament is detected and PC2 alternates between high and low for every 2.88 mm of filament movement.

I’m guessing I can put PC2 directly to pin 15 of the GPIO and have filament detection working for extruder one, but am not sure what to do with the motion sensor (though I have a suspicion it will be a custom FW build). Has anyone tackled this yet, and if so do you have any advice?

Thanks!

Here’s the new extruder body to accommodate the sensor if anyone is curious. Taz 6 Extruder Body for BTT V2 Smart Filament Sensor - Work in Progress by cmadson - Thingiverse

So, I think that for the filament detection sensor I can wire directly into Pin 15, but for the movement sensor I will have to follow this path: