pyamaha icon indicating copy to clipboard operation
pyamaha copied to clipboard

New functions for ISX-18D / ISX-80

Open Morg42 opened this issue 5 years ago • 2 comments

Hi,

can you incorporate functions for reading/setting the alarm clock on the ISX series?

What I found out:

/YamahaExtendedControl/v1/clock/getSettings /YamahaExtendedControl/v1/clock/setAlarmSettings

getSettings returns (e.g.) { "alarm": { "alarm_on": true, // boolean, on/off "fade_interval": 180, // seconds between start of {source} and beep, valid 0-180 "fade_type": 1, // don't know "mode": "oneday", // don't know, can't set via app "oneday": { "beep": true, // switch to beep after {fade_interval} "enable": true, // alarm is on "playback_type": "preset",
// this seems a bit complex. playback_type can be either // - "preset" (choose a preset from netusb source), // - "resume" (then specify any source), // - "none" (only beep) or // - "tuner" (choose a preset from tuner/dab source) // as yet, I have not seen all source details, // might need to test this a bit more "preset": // specifies necessary info for selecting playback mode { "netusb_info": { "input": "server", // "server" or "net_radio" "text": "(selected track name)"
// not sure, this seems to be only informational }, "num": 4, // select preset # "type": "netusb" // select source for preset (netusb, tuner, ...) }, "time": "0629" // alarm time as plain string. this is the BEEP time, // specified playback starts {fade_interval} secs before! }, "repeat": false, // repeat alarm or one-shot "volume": 25 // final playback volume, usually 0-60 (depending on zone) }, "auto_sync": true, // auto-sync device time via musiccast control app "format": "24h" // time format for display on device, "24h", "12h" "response_code": 0 // well-known }

setAlarmSettings (not been able to set via http GET, only POST): // this can set only alarm_on or set any number of alarm settings (or both) { "alarm_on": bool // enable/disable alarm "detail": // set alarm details { "beep": true // finish with beeping on time "day": "oneday" // don't know, no option in control app "enable": true // alarm enabled "fade_interval": 180 // seconds to fade in playback till beep, valid 0-180 "playback_type": "preset"/"resume" // see explanation above on getSettings "preset": // if playback_type "preset" selected: { "num": 4 // use preset # "type": "netusb" // source for preset (netusb, tuner, ...?) } "resume": // if playback_type "resume" selected: { "input": "net_radio" // source for playback resume acc. to device capabilities } "snooze": false // enable snooze "time": "2325" // alarm time (beep!) as plain string } "mode": "oneday" // only mode supported? "repeat": "false" // repeat alarm next day? "volume": 25 // final playback volume, device/zone dependent (usually 0-60) }

Morg42 avatar Sep 10 '18 21:09 Morg42

Add-on: from getFeatures:

"clock": {
    "alarm_fade_type_num": 1,
    "alarm_input_list": [
        "none",
        "tuner",
        "server",
        "net_radio",
        "napster",
        "spotify",
        "juke",
        "qobuz",
        "tidal",
        "deezer"
    ],
    "alarm_mode_list": [
        "oneday"
    ],
    "alarm_preset_list": [
        "netusb",
        "fm",
        "dab"
    ],
    "func_list": [
        "date_and_time",
        "alarm",
        "format"
    ],
    "range_step": [
        {
            "id": "alarm_volume",
            "max": 60,
            "min": 5,
            "step": 1
        },
        {
            "id": "alarm_fade",
            "max": 180,
            "min": 180,
            "step": 1
        }
    ]
},

Morg42 avatar Sep 11 '18 18:09 Morg42

I know, this issue is more than two years old, but anyway - it has been implemented in PR #26

micha91 avatar Feb 14 '21 08:02 micha91