소스 검색

Fix return value of WhereIsFilament()

getFilamentPresent returns the state of the IO pin of the sensor.
So we should use AT_FSENSOR instead of IN_NOZZLE
since the fsensor does not know if the filament is actually in the nozzle.
Guðni Már Gilbert 3 년 전
부모
커밋
96540d6e2d
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      Firmware/mmu2_fsensor.cpp

+ 1 - 1
Firmware/mmu2_fsensor.cpp

@@ -4,7 +4,7 @@
 namespace MMU2 {
 
 FilamentState WhereIsFilament(){
-    return fsensor.getFilamentPresent() ? FilamentState::IN_NOZZLE : FilamentState::NOT_PRESENT;
+    return fsensor.getFilamentPresent() ? FilamentState::AT_FSENSOR : FilamentState::NOT_PRESENT;
 }