Skip to content

Commit

Permalink
- Added condition 'Current price is !{{|not}} among the X highest hou…
Browse files Browse the repository at this point in the history
…rs before TIME'

- Added condition 'Current price is !{{|not}} among the X lowest hours before TIME'
- Added condition 'Current price is !{{|not}} among the X highest hours in the next Y hours'
- Added condition 'Current price is !{{|not}} among the X lowest hours in the next Y hours'
  • Loading branch information
balmli committed Jan 1, 2023
1 parent 5c41941 commit 1e99069
Show file tree
Hide file tree
Showing 12 changed files with 410 additions and 14 deletions.
3 changes: 3 additions & 0 deletions .homeychangelog.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
{
"1.13.0": {
"en": "Added condition 'Current price is !{{|not}} among the X highest hours before TIME'. Added condition 'Current price is !{{|not}} among the X lowest hours before TIME'. Added condition 'Current price is !{{|not}} among the X highest hours in the next Y hours'. Added condition 'Current price is !{{|not}} among the X lowest hours in the next Y hours'."
},
"1.12.3": {
"en": "Bug fix for the 'Holiday today' / 'Not a holiday today' action. Added conditions 'Current price is !{{|not}} among the [[hours]] hours of lowest / highest between [[start]] and [[end]]' and 'The following [[hours]] consecutive hours have !{{|not}} the lowest / highest total price between [[start]] and [[end]]' with hours as numbers. Added action card 'Fetch prices'."
},
Expand Down
2 changes: 1 addition & 1 deletion .homeycompose/app.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"id": "no.almli.heatingcontroller",
"version": "1.12.3",
"version": "1.13.0",
"compatibility": ">=5.0.0",
"sdk": 3,
"brandColor": "#d06830",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"id": "current_price_among_x_highest_before_time",
"title": {
"en": "Current price is !{{|not}} among the X highest hours before"
},
"titleFormatted": {
"en": "Current price is !{{|not}} among the [[num_hours]] highest hours before [[time]]"
},
"hint": {
"en": "Condition to check if the current price is among the X highest hours before a time of day."
},
"args": [
{
"name": "device",
"type": "device",
"filter": "driver_id=HeatingController"
},
{
"name": "num_hours",
"type": "number",
"min": 1,
"max": 23,
"step": 1,
"title": {
"en": "High hours"
},
"placeholder": {
"en": "High hours"
}
},
{
"name": "time",
"type": "time",
"title": {
"en": "Hour"
},
"placeholder": {
"en": "04:00"
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
"id": "current_price_among_x_highest_next_y_hours",
"title": {
"en": "Current price is !{{|not}} among the X highest hours in the next Y hours"
},
"titleFormatted": {
"en": "Current price is !{{|not}} among the [[num_hours]] highest hours in the next [[next_hours]] hours"
},
"hint": {
"en": "Condition to check if the current price is among the X highest hours the next Y hours."
},
"args": [
{
"name": "device",
"type": "device",
"filter": "driver_id=HeatingController"
},
{
"name": "num_hours",
"type": "number",
"min": 1,
"max": 23,
"step": 1,
"title": {
"en": "High hours"
},
"placeholder": {
"en": "High hours"
}
},
{
"name": "next_hours",
"type": "number",
"min": 1,
"max": 23,
"step": 1,
"title": {
"en": "Hours"
},
"placeholder": {
"en": "Hours"
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"id": "current_price_among_x_lowest_before_time",
"title": {
"en": "Current price is !{{|not}} among the X lowest hours before"
},
"titleFormatted": {
"en": "Current price is !{{|not}} among the [[num_hours]] lowest hours before [[time]]"
},
"hint": {
"en": "Condition to check if the current price is among the X lowest hours before a time of day."
},
"args": [
{
"name": "device",
"type": "device",
"filter": "driver_id=HeatingController"
},
{
"name": "num_hours",
"type": "number",
"min": 1,
"max": 23,
"step": 1,
"title": {
"en": "Low hours"
},
"placeholder": {
"en": "Low hours"
}
},
{
"name": "time",
"type": "time",
"title": {
"en": "Hour"
},
"placeholder": {
"en": "04:00"
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
"id": "current_price_among_x_lowest_next_y_hours",
"title": {
"en": "Current price is !{{|not}} among the X lowest hours in the next Y hours"
},
"titleFormatted": {
"en": "Current price is !{{|not}} among the [[num_hours]] lowest hours in the next [[next_hours]] hours"
},
"hint": {
"en": "Condition to check if the current price is among the X lowest hours the next Y hours."
},
"args": [
{
"name": "device",
"type": "device",
"filter": "driver_id=HeatingController"
},
{
"name": "num_hours",
"type": "number",
"min": 1,
"max": 23,
"step": 1,
"title": {
"en": "Low hours"
},
"placeholder": {
"en": "Low hours"
}
},
{
"name": "next_hours",
"type": "number",
"min": 1,
"max": 23,
"step": 1,
"title": {
"en": "Hours"
},
"placeholder": {
"en": "Hours"
}
}
]
}
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,10 @@ The 'Night starts', 'Night ends', 'At work starts' and 'At work ends' will trigg
- Is at work / not at work
- Is comfort mode / ECO mode
- Is current price below / above
- Current price is !{{|not}} among the X highest hours before TIME
- Current price is !{{|not}} among the X lowest hours before TIME
- Current price is !{{|not}} among the X highest hours in the next Y hours
- Current price is !{{|not}} among the X lowest hours in the next Y hours
- Current price is among / is not among the X hours of the days lowest prices
- Current price is among / is not among the X hours of the days highest prices
- Current price is among / is not among the X hours of lowest between START and END
Expand All @@ -240,13 +244,15 @@ The 'Night starts', 'Night ends', 'At work starts' and 'At work ends' will trigg

#### Actions

- Fetch prices
- Set home
- Set away
- Set away, and automatically switch to home mode on next schedule
- Set home override on
- Set home override on, and automatically off on next schedule
- Set home override off
- Set holiday today. Holiday can be overridden with this action.
- Set holiday today. Holiday can be overridden with this action
- Use automatic holiday

#### Capabilities

Expand Down Expand Up @@ -274,6 +280,13 @@ Please report issues on the [community forum page](https://community.homey.app/t

### Release Notes:

#### 1.13.0

- Added condition 'Current price is !{{|not}} among the X highest hours before TIME'
- Added condition 'Current price is !{{|not}} among the X lowest hours before TIME'
- Added condition 'Current price is !{{|not}} among the X highest hours in the next Y hours'
- Added condition 'Current price is !{{|not}} among the X lowest hours in the next Y hours'
-
#### 1.12.3

- Bug fix for the 'Holiday today' / 'Not a holiday today' action
Expand Down
Loading

0 comments on commit 1e99069

Please sign in to comment.