Skip to content

Commit

Permalink
fix border first grid first order
Browse files Browse the repository at this point in the history
  • Loading branch information
mikey0000 committed Oct 23, 2024
1 parent b9108fd commit 75cb20c
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 8 deletions.
15 changes: 15 additions & 0 deletions FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# These are supported funding model platforms

github: mikey0000 # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: DenimJackRabbit
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
polar: # Replace with a single Polar username
buy_me_a_coffee: # Replace with a single Buy Me a Coffee username
thanks_dev: # Replace with a single thanks.dev username
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
3 changes: 2 additions & 1 deletion pymammotion/data/model/device_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ class OperationSettings(DataClassORJSONMixin):
toward: int = 0 # is just angle
toward_included_angle: int = 90
toward_mode: int = 0 # angle type relative etc
border_mode: int = 0
obstacle_laps: int = 1
mowing_laps: int = 1 # border laps
start_progress: int = 0
Expand All @@ -46,7 +47,7 @@ def create_path_order(operation_mode: OperationSettings, device_name: str) -> st
# TODO add scheduling logic from getReserved() WorkSettingViewModel.java
i2 = 0
bArr = bytearray(8)
bArr[0] = operation_mode.mowing_laps
bArr[0] = operation_mode.border_mode
bArr[1] = operation_mode.obstacle_laps
bArr[3] = int(operation_mode.start_progress)
bArr[2] = 0
Expand Down
3 changes: 1 addition & 2 deletions pymammotion/data/model/generate_route_information.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import logging
from dataclasses import dataclass
from typing import List

logger = logging.getLogger(__name__)

Expand All @@ -10,7 +9,7 @@ class GenerateRouteInformation:
"""Creates a model for generating route information and mowing plan before starting a job."""

one_hashs: list[int] = list
job_mode: int = 0 # taskMode
job_mode: int = 4 # taskMode
job_version: int = 0
job_id: int = 0
speed: float = 0.3
Expand Down
4 changes: 2 additions & 2 deletions pymammotion/data/model/mowing_modes.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ class ObstacleLapsMode(IntEnum):
class MowOrder(IntEnum):
"""path_order"""

grid_first = 0
border_first = 1
border_first = 0
grid_first = 1


class BypassStrategy(IntEnum):
Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[project]
name = "pymammotion"
version = "0.2.74"
version = "0.2.76"

[tool.poetry]
name = "pymammotion"
version = "0.2.74"
version = "0.2.76"
license = "GNU-3.0"
description = ""
readme = "README.md"
Expand Down Expand Up @@ -61,7 +61,7 @@ mypy = "^1.11.2"
autotyping = "^24.3.0"

[tool.bumpver]
current_version = "0.2.74"
current_version = "0.2.76"
version_pattern = "MAJOR.MINOR.PATCH"
commit_message = "Bump version {old_version} -> {new_version}"
commit = true
Expand Down

0 comments on commit 75cb20c

Please sign in to comment.