Prusa-MMU-Private
PrusaMultiMaterialUpgradev3firmwareforMK3SMK4
Classes | Enumerations | Functions | Variables
modules::globals Namespace Reference

The globals namespace provides all necessary facilities related to keeping track of global state of the firmware. More...

Classes

class  Globals
 Globals keep track of global state variables in the firmware. More...
 

Enumerations

enum  FilamentLoadState : uint8_t {
  NotLoaded = 0 , AtPulley = 1 , InSelector = 2 , InFSensor = 4 ,
  InNozzle = 8
}
 

Functions

void __attribute__ ((noinline)) Globals
 

Variables

Globals globals
 The one and only instance of global state variables.
 

Detailed Description

The globals namespace provides all necessary facilities related to keeping track of global state of the firmware.

Enumeration Type Documentation

◆ FilamentLoadState

Different stages of filament load. Beware:

  • the firmware depends on the order of these values to check for various situations.
  • the unit tests abuse the bitmask-like values to check for multiple situations easily
Enumerator
NotLoaded 

not loaded in the MMU at all

AtPulley 

loaded to mmu (idler and pulley can grab it)

InSelector 

'P1' loaded in selector (i.e. unsure where the filament is while doing some operation)

InFSensor 

'f1' loaded into printer's filament sensor

InNozzle 

'f2' loaded into printer's nozzle