diff --git a/nspanel_esphome.yaml b/nspanel_esphome.yaml index b1692d9..6bbd78f 100644 --- a/nspanel_esphome.yaml +++ b/nspanel_esphome.yaml @@ -805,7 +805,7 @@ api: if (supported_features & 32 and state != "off") id(disp1).show_component("bt_next"); else id(disp1).hide_component("bt_next"); // Stop button - STOP - if (supported_features & 4096 and (state == "playing" or state == "paused")) id(disp1).show_component("bt_stop"); else id(disp1).hide_component("bt_stop"); + //if (supported_features & 4096 and (state == "playing" or state == "paused")) id(disp1).show_component("bt_stop"); else id(disp1).hide_component("bt_stop"); // mute/unmute button - VOLUME_MUTE id(disp1).set_component_value("is_muted", (is_volume_muted) ? 1 : 0); @@ -1411,7 +1411,7 @@ text_sensor: id(disp1).set_component_text_printf("bt_prev", "%s", "\uE4AD"); //mdi:skip-previous id(disp1).set_component_text_printf("bt_next", "%s", "\uE4AC"); //mdi:skip-next id(disp1).set_component_text_printf("bt_play_pause", "%s", "\uE40D"); //mdi:play-pause - id(disp1).set_component_text_printf("bt_stop", "%s", "\uE4DA"); //mdi:stop + //id(disp1).set_component_text_printf("bt_stop", "%s", "\uE4DA"); //mdi:stop id(disp1).set_component_text_printf("bt_mute", "%s", "\uE75E"); //mdi:volume-mute id(disp1).set_component_text_printf("bt_vol_down", "%s", "\uE75D"); //mdi:volume-minus id(disp1).set_component_text_printf("bt_vol_up", "%s", "\uE75C"); //mdi:volume-plus diff --git a/nspanel_eu.HMI b/nspanel_eu.HMI index 82c218c..8665ad2 100644 Binary files a/nspanel_eu.HMI and b/nspanel_eu.HMI differ diff --git a/nspanel_eu.tft b/nspanel_eu.tft index c1303dc..54b51e1 100644 Binary files a/nspanel_eu.tft and b/nspanel_eu.tft differ diff --git a/nspanel_eu_code/media_player.txt b/nspanel_eu_code/media_player.txt index c43db7f..f1fb7c5 100644 --- a/nspanel_eu_code/media_player.txt +++ b/nspanel_eu_code/media_player.txt @@ -48,33 +48,33 @@ Variable (string) back_page Variable (string) lastclick Attributes - ID : 20 + ID : 19 Scope : local Text : Max. Text Size: 255 Variable (string) va0 Attributes - ID : 23 + ID : 22 Scope : local Text : Max. Text Size: 10 Variable (int32) is_muted Attributes - ID : 24 + ID : 23 Scope: local Value: 0 Variable (int32) prg_current Attributes - ID : 26 + ID : 25 Scope: local Value: 0 Variable (int32) prg_total Attributes - ID : 27 + ID : 26 Scope: local Value: 0 @@ -391,35 +391,9 @@ Text bt_play_pause printh 00 printh FF FF FF -Text bt_stop - Attributes - ID : 17 - Scope : local - Dragging : 0 - Send Component ID : disabled - Associated Keyboard: none - Text : - Max. Text Size : 10 - - Events - Touch Press Event - printh 91 - prints "touchevent",0 - printh 00 - prints rand,0 - printh FF FF FF - - Touch Release Event - printh 92 - prints "localevent",0 - printh 00 - prints "{\"page\": \"media_player\", \"key\": \"media_stop\"}",0 - printh 00 - printh FF FF FF - Text bt_next Attributes - ID : 18 + ID : 17 Scope : local Dragging : 0 Send Component ID : disabled @@ -445,7 +419,7 @@ Text bt_next Text bt_on_off Attributes - ID : 19 + ID : 18 Scope : local Dragging : 0 Send Component ID : disabled @@ -551,7 +525,7 @@ Button button_back Timer wakeup_timer Attributes - ID : 21 + ID : 20 Scope : local Period (ms): 100 Enabled : yes @@ -574,7 +548,7 @@ Timer wakeup_timer Timer timer0 Attributes - ID : 22 + ID : 21 Scope : local Period (ms): 1000 Enabled : no @@ -594,7 +568,7 @@ Timer timer0 Timer prg_timer Attributes - ID : 25 + ID : 24 Scope : local Period (ms): 1000 Enabled : no diff --git a/nspanel_us.HMI b/nspanel_us.HMI index 7ea1b3a..f773fc8 100644 Binary files a/nspanel_us.HMI and b/nspanel_us.HMI differ diff --git a/nspanel_us.tft b/nspanel_us.tft index 3984ea5..4abffc7 100644 Binary files a/nspanel_us.tft and b/nspanel_us.tft differ diff --git a/nspanel_us_code/media_player.txt b/nspanel_us_code/media_player.txt index 646aa33..22ac87a 100644 --- a/nspanel_us_code/media_player.txt +++ b/nspanel_us_code/media_player.txt @@ -48,33 +48,33 @@ Variable (string) back_page Variable (string) lastclick Attributes - ID : 20 + ID : 19 Scope : local Text : Max. Text Size: 255 Variable (string) va0 Attributes - ID : 23 + ID : 22 Scope : local Text : Max. Text Size: 10 Variable (int32) is_muted Attributes - ID : 24 + ID : 23 Scope: local Value: 0 Variable (int32) prg_current Attributes - ID : 26 + ID : 25 Scope: local Value: 0 Variable (int32) prg_total Attributes - ID : 27 + ID : 26 Scope: local Value: 0 @@ -390,35 +390,9 @@ Text bt_play_pause printh 00 printh FF FF FF -Text bt_stop - Attributes - ID : 17 - Scope : local - Dragging : 0 - Send Component ID : disabled - Associated Keyboard: none - Text : - Max. Text Size : 10 - - Events - Touch Press Event - printh 91 - prints "touchevent",0 - printh 00 - prints rand,0 - printh FF FF FF - - Touch Release Event - printh 92 - prints "localevent",0 - printh 00 - prints "{\"page\": \"media_player\", \"key\": \"media_stop\"}",0 - printh 00 - printh FF FF FF - Text bt_next Attributes - ID : 18 + ID : 17 Scope : local Dragging : 0 Send Component ID : disabled @@ -444,7 +418,7 @@ Text bt_next Text bt_on_off Attributes - ID : 19 + ID : 18 Scope : local Dragging : 0 Send Component ID : disabled @@ -550,7 +524,7 @@ Button button_back Timer wakeup_timer Attributes - ID : 21 + ID : 20 Scope : local Period (ms): 100 Enabled : yes @@ -573,7 +547,7 @@ Timer wakeup_timer Timer timer0 Attributes - ID : 22 + ID : 21 Scope : local Period (ms): 1000 Enabled : no @@ -593,7 +567,7 @@ Timer timer0 Timer prg_timer Attributes - ID : 25 + ID : 24 Scope : local Period (ms): 1000 Enabled : no diff --git a/nspanel_us_land.HMI b/nspanel_us_land.HMI index 7eabe90..84d6ab4 100644 Binary files a/nspanel_us_land.HMI and b/nspanel_us_land.HMI differ diff --git a/nspanel_us_land.tft b/nspanel_us_land.tft index 7dfda87..04bfacc 100644 Binary files a/nspanel_us_land.tft and b/nspanel_us_land.tft differ diff --git a/nspanel_us_land_code/media_player.txt b/nspanel_us_land_code/media_player.txt index 5e885d0..f1fb7c5 100644 --- a/nspanel_us_land_code/media_player.txt +++ b/nspanel_us_land_code/media_player.txt @@ -48,33 +48,33 @@ Variable (string) back_page Variable (string) lastclick Attributes - ID : 20 + ID : 19 Scope : local Text : Max. Text Size: 255 Variable (string) va0 Attributes - ID : 23 + ID : 22 Scope : local Text : Max. Text Size: 10 Variable (int32) is_muted Attributes - ID : 24 + ID : 23 Scope: local Value: 0 Variable (int32) prg_current Attributes - ID : 26 + ID : 25 Scope: local Value: 0 Variable (int32) prg_total Attributes - ID : 27 + ID : 26 Scope: local Value: 0 @@ -98,6 +98,21 @@ Text icon_state Text :  Max. Text Size : 10 + Events + Touch Press Event + printh 91 + prints "touchevent",0 + printh 00 + prints rand,0 + printh FF FF FF + + Touch Release Event + printh 91 + prints "touchevent",0 + printh 00 + prints rand,0 + printh FF FF FF + Text vol_text Attributes ID : 6 @@ -376,35 +391,9 @@ Text bt_play_pause printh 00 printh FF FF FF -Text bt_stop - Attributes - ID : 17 - Scope : local - Dragging : 0 - Send Component ID : disabled - Associated Keyboard: none - Text : - Max. Text Size : 10 - - Events - Touch Press Event - printh 91 - prints "touchevent",0 - printh 00 - prints rand,0 - printh FF FF FF - - Touch Release Event - printh 92 - prints "localevent",0 - printh 00 - prints "{\"page\": \"media_player\", \"key\": \"media_stop\"}",0 - printh 00 - printh FF FF FF - Text bt_next Attributes - ID : 18 + ID : 17 Scope : local Dragging : 0 Send Component ID : disabled @@ -430,7 +419,7 @@ Text bt_next Text bt_on_off Attributes - ID : 19 + ID : 18 Scope : local Dragging : 0 Send Component ID : disabled @@ -496,14 +485,14 @@ Slider vol_slider printh FF FF FF Touch Release Event + covx vol_slider.val,va0.txt,0,0 + vol_text.txt=va0.txt+"%" + timer0.en=1 printh 91 prints "touchevent",0 printh 00 prints rand,0 printh FF FF FF - covx vol_slider.val,va0.txt,0,0 - vol_text.txt=va0.txt+"%" - timer0.en=1 Button button_back Attributes @@ -517,11 +506,6 @@ Button button_back Events Touch Press Event - printh 91 - prints "touchevent",0 - printh 00 - prints rand,0 - printh FF FF FF if(back_page.txt=="buttonpage01") { page buttonpage01 @@ -541,7 +525,7 @@ Button button_back Timer wakeup_timer Attributes - ID : 21 + ID : 20 Scope : local Period (ms): 100 Enabled : yes @@ -564,7 +548,7 @@ Timer wakeup_timer Timer timer0 Attributes - ID : 22 + ID : 21 Scope : local Period (ms): 1000 Enabled : no @@ -584,7 +568,7 @@ Timer timer0 Timer prg_timer Attributes - ID : 25 + ID : 24 Scope : local Period (ms): 1000 Enabled : no