2 * Copyright (c) 2010-2023 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
7 * This program and the accompanying materials are made available under the
8 * terms of the Eclipse Public License 2.0 which is available at
9 * http://www.eclipse.org/legal/epl-2.0
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.oppo.internal.communication;
15 import static java.util.Map.entry;
16 import static org.openhab.binding.oppo.internal.OppoBindingConstants.*;
18 import java.util.HashMap;
21 import org.eclipse.jdt.annotation.NonNullByDefault;
24 * Provides mapping of various Oppo query status codes to the corresponding set codes
26 * @author Michael Lobstein - Initial contribution
30 public class OppoStatusCodes {
31 // map to lookup random mode
32 public static final Map<String, String> REPEAT_MODE = new HashMap<>();
34 REPEAT_MODE.put("00", "OFF");
35 REPEAT_MODE.put("01", "ONE"); // maybe?"
36 REPEAT_MODE.put("02", "CH");
37 REPEAT_MODE.put("03", "ALL");
38 REPEAT_MODE.put("04", "TT");
39 REPEAT_MODE.put("05", "SHF");
40 REPEAT_MODE.put("06", "RND");
43 // map to lookup zoom mode
44 public static final Map<String, String> ZOOM_MODE = new HashMap<>();
46 ZOOM_MODE.put("00", "1"); // Off (zoom 1x)
47 ZOOM_MODE.put("01", "AR"); // Stretch
48 ZOOM_MODE.put("02", "FS"); // Full screen
49 ZOOM_MODE.put("03", "US"); // Underscan
50 ZOOM_MODE.put("04", "1.2");
51 ZOOM_MODE.put("05", "1.3");
52 ZOOM_MODE.put("06", "1.5");
53 ZOOM_MODE.put("07", "2");
54 ZOOM_MODE.put("08", "3");
55 ZOOM_MODE.put("09", "4");
56 ZOOM_MODE.put("10", "1/2");
57 ZOOM_MODE.put("11", "1/3");
58 ZOOM_MODE.put("12", "1/4");
61 // map to lookup disc type
62 public static final Map<String, String> DISC_TYPE = Map.ofEntries(entry("BDMV", "BD-MV"),
63 entry("DVDV", "DVD-VIDEO"), entry("DVDA", "DVD-AUDIO"), entry("SACD", "SACD"), entry("CDDA", "CDDA"),
64 entry("HDCD", "HDCD"), entry("DATA", "DATA-DISC"), entry("VCD2", "VCD2"), entry("SVCD", "SVCD"),
65 entry("UHBD", "UHBD"), entry("UNKN", UNKNOW_DISC));
67 // map to lookup playback status
68 public static final Map<String, String> PLAYBACK_STATUS = Map.ofEntries(entry("DISC", "NO DISC"),
69 entry("LOAD", "LOADING"), entry("OPEN", "OPEN"), entry("CLOS", "CLOSE"), entry("PLAY", "PLAY"),
70 entry("PAUS", "PAUSE"), entry("STOP", "STOP"), entry("HOME", "HOME MENU"), entry("MCTR", "MEDIA CENTER"),
71 entry("SCSV", "SCREEN SAVER"), entry("MENU", "DISC MENU"));