Hi Chris,
I have done more listening to the App traffic for my particular model 632C. This model needs a “startMowing” command, and does not recognise the command that is currently programmed “startMowingFromPoint”. In fact there is no such option in my App at all.
I have added START_MOWING_NOW to reference to “startMowing” in the IMowActions() class in api/ common/actions.py.
There are two ways to execute start mowing for the 632 model:
- With a default endtime, approximately 2 hours after current time at a 10 minute internal (00, 10, 20, 30, 40, 50) :
The action_object looks like this: please note “startMowing” rather than “startMowingFromPoint”
{“actionName”:“startMowing”,“actionValue”:“16 digit externalid,2023-08-12 20:50”}
- With an endtime about 2 hours after now, and starttime a little later than now at a 10 minute interval:
{“actionName”:“startMowing”,“actionValue”:“16 digit externalid,2023-08-12 21:00,2023-08-12 19:00”}
I have started to experiment with this and have it working now for the test script.
The function call is:
await mower.intent(IMowActions.START_MOWING_NOW,0,'2023-08-14 14:00')
I have added a 0 as default startpoint, because the code in __init__.py refers to it. And I wanted to minimise the changes to it.
To make this work I needed to change two lines of code in imow/api/__init__.py:
In line 363 I eliminated the quotes around the 0: (I think the startpoint is an int not a str):
if "-" in str(duration) and startpoint == 0:
In line 370 I added some code to ensure the startpoint does not get added to the action_object, because it is not needed for the 632 model:
if imow_action == IMowActions.START_MOWING or imow_action == IMowActions.START_MOWING_NOW
This now works for my 632 model at least in the test script that you provided.
Next step is to figure out how this command can get entered into Home Assistant. That is a whole new ballgame for me.