CustomDataStructures.h 2.39 KB
Newer Older
1 2 3 4 5 6
/*
  CustomDataStructures.h - Data structures helper for the brew project.
  Created by João Lino, August 11, 2015.
  Released into the public domain.
*/
#ifndef CustomDataStructures_h
João Lino's avatar
Rel.3  
João Lino committed
7
#define CustomDataStructures_h
8

9 10
#define SYS_MAX_MENU_ELEMENTS   16

11 12 13 14 15 16 17 18
enum eRotaryEncoderMode {
	eRotaryEncoderMode_Menu,
	eRotaryEncoderMode_Time,
	eRotaryEncoderMode_Generic,
	eRotaryEncoderMode_Disabled
};

// menu
João Lino's avatar
Rel.3  
João Lino committed
19 20
enum eMenuType {
	eMenuType_Main,
João Lino's avatar
João Lino committed
21
  eMenuType_StartFromStage,
João Lino's avatar
Rel.3  
João Lino committed
22 23 24 25 26
	eMenuType_BeerProfile,
	eMenuType_Stage,
	eMenuType_Malt,
	eMenuType_Settings
};
27
enum eMainMenuOptions {
João Lino's avatar
Rel.3  
João Lino committed
28
	eMainMenu_NULL,
João Lino's avatar
João Lino committed
29
  eMainMenu_GO,
João Lino's avatar
João Lino committed
30
  eMainMenu_GO_FROM_STAGE,
João Lino's avatar
Rel.3  
João Lino committed
31 32 33 34
	eMainMenu_STOP,
	eMainMenu_SKIP,
	eMainMenu_BeerProfile,
	eMainMenu_Stage,
35 36
	eMainMenu_Malt,
	eMainMenu_Hops,
João Lino's avatar
Rel.3  
João Lino committed
37 38
	eMainMenu_Clean,
	eMainMenu_Purge,
39 40 41 42
	eMainMenu_Settings,
	eMainMenu_Back
};

João Lino's avatar
Rel.3  
João Lino committed
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59
enum eStageMenuOptions {
	eStageMenu_NULL,
	eStageMenu_Startpoint,
	eStageMenu_BetaGlucanase,
	eStageMenu_Debranching,
	eStageMenu_Proteolytic,
	eStageMenu_BetaAmylase,
	eStageMenu_AlphaAmylase,
	eStageMenu_Mashout,
	eStageMenu_Recirculation,
	eStageMenu_Sparge,
	eStageMenu_Boil,
	eStageMenu_Cooling,
	eStageMenu_Back
};

enum eBeerProfileMenuOptions {
João Lino's avatar
João Lino committed
60 61 62 63 64 65 66 67 68
  eBeerProfileMenu_NULL,
  eBeerProfileMenu_Basic,
  eBeerProfileMenu_Trigo,
  eBeerProfileMenu_IPA,
  eBeerProfileMenu_Belga,
  eBeerProfileMenu_Red,
  eBeerProfileMenu_APA,
  eBeerProfileMenu_Custom,
  eBeerProfileMenu_Back
69 70 71
};

enum eMaltMenuOptions {
João Lino's avatar
Rel.3  
João Lino committed
72
	eMaltMenu_NULL,
73 74 75 76 77 78
	eMaltMenu_CastleMalting_Chteau_Pilsen_2RS,
	eMaltMenu_CastleMalting_Wheat_Blanc,
	eMaltMenu_Back
};

enum eSettingsMenuOptions {
João Lino's avatar
Rel.3  
João Lino committed
79
	eSettingsMenu_NULL,
João Lino's avatar
João Lino committed
80
	eSettingsMenu_Pump,
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
	eSettingsMenu_PT100_Element,
	eSettingsMenu_PT100_Up,
	eSettingsMenu_PT100_Down,
	eSettingsMenu_Back
};

// cooking
enum eCookingStages {
	eCookingStage_Startpoint,
	eCookingStage_BetaGlucanase,
	eCookingStage_Debranching,
	eCookingStage_Proteolytic,
	eCookingStage_BetaAmylase,
	eCookingStage_AlphaAmylase,
	eCookingStage_Mashout,
	eCookingStage_Recirculation,
	eCookingStage_Sparge,
	eCookingStage_Boil,
	eCookingStage_Cooling,
João Lino's avatar
Rel.3  
João Lino committed
100 101
	eCookingStage_Clean,
	eCookingStage_Purge,
102 103 104
	eCookingStage_Done
};

João Lino's avatar
Rel.3  
João Lino committed
105 106 107 108 109 110 111 112 113 114
enum eBeerProfile {
	eBeerProfile_Basic,
	eBeerProfile_Trigo,
	eBeerProfile_IPA,
	eBeerProfile_Belga,
	eBeerProfile_Red,
	eBeerProfile_APA,
	eBeerProfile_Custom
};

João Lino's avatar
João Lino committed
115
typedef struct menuData_ {
116 117
  const char *_title;
  const char *_dialog[ SYS_MAX_MENU_ELEMENTS ];
João Lino's avatar
João Lino committed
118 119 120 121 122
  int  _position;
  int  _selection;
  bool _repaint;
} MenuData;

João Lino's avatar
João Lino committed
123
#endif