Skip to content

Commit

Permalink
Merge pull request #184 from AndreWohnsland/dev
Browse files Browse the repository at this point in the history
Reworked Options Config
  • Loading branch information
AndreWohnsland authored Sep 8, 2024
2 parents fa90151 + 0f9316d commit 89a619c
Show file tree
Hide file tree
Showing 41 changed files with 931 additions and 624 deletions.
4 changes: 2 additions & 2 deletions docs/addons.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ Also use an appropriate, not too long name, as well as all capital letters and u
You can have a look at the other values as a reference.

```python
from src.config_manager import CONFIG as cfg # (1)!
from src.config.config_manager import CONFIG as cfg # (1)!

def setup(self):
cfg.add_config("ADDON_CONFIG", "DefaultValue") # (2)!
Expand Down Expand Up @@ -200,7 +200,7 @@ The description of the error should inform the user, why it is not valid.
Cases may be limiting length of characters, only specific number ranges or similar.

```python
from src.config_manager import ConfigError # (1)!
from src.config.errors import ConfigError # (1)!

def _check_function(configname: str, configvalue: str): # (2)!
if configvalue == "forbidden": # (3)!
Expand Down
2 changes: 1 addition & 1 deletion docs/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ With this setting, the window will be minimized before the rest of the program a
### What about Tube Volume

If your pumps got a long tube to the bottle, the first cocktail may have too little volume.
You can set the `MAKER_TUBE_VOLUME` to an approximate value which corresponds to the average of the tube volume.
You can set the tube volume of each pump in `PUMP_CONFIG`.
When applying a new bottle, CocktailBerry will also pump that much volume up.

### Implementing LEDs
Expand Down
4 changes: 1 addition & 3 deletions docs/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ They can be used at own risk of CocktailBerry not working 100% properly.
| `MAKER_CLEAN_TIME` | Time the machine will execute the cleaning program |
| `MAKER_MAX_HAND_INGREDIENTS` | Max x ingredients are allowed to add by hand |
| `MAKER_CHECK_INTERNET` | Do a connection check at start for time adjustment window |
| `MAKER_TUBE_VOLUME` | Volume in ml to pump up when bottle is set to new |
| `MAKER_USE_RECIPE_VOLUME` | Do not scale but use defined amounts |
| `MAKER_ADD_SINGLE_INGREDIENT` | Allows spending single ingredient in maker view |

Expand All @@ -67,8 +66,7 @@ They can be used at own risk of CocktailBerry not working 100% properly.

| Value Name | Description |
| :--------------------- | :--------------------------------------------------------------------------------------- |
| `PUMP_PINS` | List of the [Pins](#configuring-the-pins-or-used-board) where each Pump is connected |
| `PUMP_VOLUMEFLOW` | List of the according volume flow for each pump in ml/s |
| `PUMP_CONFIG` | List with config for each pump: pin, volume flow, tube volume to pump up |
| `LED_PINS` | List of pins connected to LEDs for preparation |
| `LED_BRIGHTNESS` | Brightness for the WS281x LED (1-255) |
| `LED_COUNT` | Number of LEDs on the WS281x |
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "CocktailBerry"
version = "1.35.1"
version = "1.36.0"
description = "A Python and Qt based App for a Cocktail Machine on a Raspberry Pi. Easily serve Cocktails with Raspberry Pi and Python"
authors = [{ name= "Andre Wohnsland" , email = "Andre_Wohnsland@web.de" }]
readme = "readme.md"
Expand Down
2 changes: 1 addition & 1 deletion src/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from typing import Literal

__version__ = "1.35.2"
__version__ = "1.36.0"
PROJECT_NAME = "CocktailBerry"
MAX_SUPPORTED_BOTTLES = 24
SupportedLanguagesType = Literal["en", "de"]
Expand Down
Empty file added src/config/__init__.py
Empty file.
Loading

0 comments on commit 89a619c

Please sign in to comment.