AllYarnsAreBeautiful / ayab-hardware

Contains the schematics and layouts for the AYAB Arduino shield
Creative Commons Attribution Share Alike 4.0 International
33 stars 13 forks source link

Correct right hall sensor detection #19

Closed dl1com closed 4 months ago

dl1com commented 1 year ago

see https://github.com/AllYarnsAreBeautiful/ayab-firmware/issues/51#issuecomment-1467086056 and following

VIPQualityPost commented 11 months ago

So what is the resolution to this? Do we want to have two input pins for 910 EOL-RIGHT, one for K and one for L carriages? Or should we just OR the two signals, because we can sense if the carriage has moved >3 needles but shows a pulse longer than single magnet?

maybe we can get some comments from @jpcornil-git

jpcornil-git commented 11 months ago

I would use both (digital) inputs to avoid another (less robust ?) detection mechanism for LKG carriages.

One input is indeed equivalent to "hallValue < FILTER_R_MIN" and the other to "hallValue > FILTER_R_MAX" and existing code can therefore easily be modified to cope with this.

jpcornil-git commented 11 months ago

... and you can't differentiate K and L anymore with an OR approach (one short pulse for both) -> not an option anyway

VIPQualityPost commented 11 months ago

Right, I was thinking because they are a pulse that you can do it, but it doesn't work for other machines (sans comparator) anyway. It will have it's own pin.

VIPQualityPost commented 4 months ago

We did it!