V repozitáři AUR (Arch User Repository) linuxové distribuce Arch Linux byly nalezeny a odstraněny tři balíčky s malwarem. Jedná se o librewolf-fix-bin, firefox-patch-bin a zen-browser-patched-bin.
Dle plánu by Debian 13 s kódovým názvem Trixie měl vyjít v sobotu 9. srpna.
Vývoj linuxové distribuce Clear Linux (Wikipedie) vyvíjené společností Intel a optimalizováné pro jejich procesory byl oficiálně ukončen.
Byl publikován aktuální přehled vývoje renderovacího jádra webového prohlížeče Servo (Wikipedie).
V programovacím jazyce Go naprogramovaná webová aplikace pro spolupráci na zdrojových kódech pomocí gitu Forgejo byla vydána ve verzi 12.0 (Mastodon). Forgejo je fork Gitei.
Nová čísla časopisů od nakladatelství Raspberry Pi zdarma ke čtení: Raspberry Pi Official Magazine 155 (pdf) a Hello World 27 (pdf).
Hyprland, tj. kompozitor pro Wayland zaměřený na dláždění okny a zároveň grafické efekty, byl vydán ve verzi 0.50.0. Podrobný přehled novinek na GitHubu.
Patrick Volkerding oznámil před dvaatřiceti lety vydání Slackware Linuxu 1.00. Slackware Linux byl tenkrát k dispozici na 3,5 palcových disketách. Základní systém byl na 13 disketách. Kdo chtěl grafiku, potřeboval dalších 11 disket. Slackware Linux 1.00 byl postaven na Linuxu .99pl11 Alpha, libc 4.4.1, g++ 2.4.5 a XFree86 1.3.
Ministerstvo pro místní rozvoj (MMR) jako první orgán státní správy v Česku spustilo takzvaný „bug bounty“ program pro odhalování bezpečnostních rizik a zranitelných míst ve svých informačních systémech. Za nalezení kritické zranitelnosti nabízí veřejnosti odměnu 1000 eur, v případě vysoké závažnosti je to 500 eur. Program se inspiruje přístupy běžnými v komerčním sektoru nebo ve veřejné sféře v zahraničí.
Vláda dne 16. července 2025 schválila návrh nového jednotného vizuálního stylu státní správy. Vytvořilo jej na základě veřejné soutěže studio Najbrt. Náklady na přípravu návrhu a metodiky činily tři miliony korun. Modernizovaný dvouocasý lev vychází z malého státního znaku. Vizuální styl doprovází originální písmo Czechia Sans.
Řešení dotazu:
-- Check the wiki at -- http://www.domoticz.com/wiki/%27dzVents%27:_next_generation_LUA_scripting return { -- 'active' controls if this entire script is considered or not active = true, -- set to false to disable this script -- trigger on = { timer = { -- timer triggers.. if one matches with the current time then the script is executed 'every 5 minutes', } }, -- actual event code -- in case of a timer event or security event, device == nil execute = function(domoticz) local max_level = 5 -- sensos value for max level in tank local min_level = 110 -- sensor value for min level in tank local actual_volume = 0 -- actual volume in m3 local actual_percent = 0 -- actual volume in percent local delta_volume = 22.8245 -- volume for 1cm in tank in litres local DIST_READED = domoticz.devices('Nadrz_vzdalenost') --aktual distance from sensor local D1 = domoticz.variables('distance_1') -- most oldest distance reading local D2 = domoticz.variables('distance_2') -- middle distance reading local D3 = domoticz.variables('distance_3') -- last distance reading local DIST_LAST = domoticz.variables('last_distance') -- previous distance calculated local DIST_ACTUAL = domoticz.variables('actual_distance') -- actual calculated distance - - average from distance_1 to distance_3 local DELTA = domoticz.variables('delta') local d2 = D2.value local d3 = D3.value local d1 = D1.value local distance = DIST_READED.distance local distance_prev = DIST_LAST.value local pom_pritok = 0 local pom_spotreba = 0 local VOLUME = domoticz.variables('volume') local VOLUME_PROC = domoticz.variables('volume_proc') local OBJEM = domoticz.devices('Nadrz_objem_m3') local OBJEM_PROC = domoticz.devices('Nadrz_objem_procenta') D1.set(d2) -- swap values D2.set(d3) D3.set(distance) -- last readings to D3 local distance_actual = math.floor((d2 + d3 + distance ) / 3) DIST_ACTUAL.set(distance_actual) -- smoothing function fro last 3 readings local delta = distance_actual - distance_prev -- priustek ( zaporny ) , ubytek ( kladny ) v nadrzi DELTA.set(delta) if delta ~= 0 then if delta > 0 then -- pritelka voda pom_spotreba = delta * delta_volume -- pritok v litrech else pom_pritok = -1 * ( delta * delta_volume ) -- spotreba v litrech end DIST_LAST.set(DIST_ACTUAL) -- actual calculated distance to previous distance calculated end actual_volume = delta_volume * (min_level - distance_actual) / 1000 actual_percent = (actual_volume * 1000 / (( min_level - max_level ) * delta_volume )) * 100 VOLUME.set( actual_volume ) VOLUME_PROC.set( actual_percent ) OBJEM.updateCustomSensor(actual_volume) OBJEM_PROC.updatePercentage(actual_percent) end }Použitá čidla a Domoticz proměnné zde:
-- Check the wiki at -- http://www.domoticz.com/wiki/%27dzVents%27:_next_generation_LUA_scripting return { -- 'active' controls if this entire script is considered or not active = true, -- set to false to disable this script -- trigger -- can be a combination: on = { devices = { -- timer triggers.. if one matches with the current time then the script is executed 'Koupelna_Setpoint' } }, -- actual event code -- in case of a timer event or security event, device == nil execute = function(domoticz, device) local url= 'http://192.168.1.107/control?cmd=event,HeatSetpoint='..(device.state)..'' print(url) domoticz.openURL(url) end }
Barometer sensor barometer. Number. Barometric pressure. forecast: Number. forecastString: String. updateBarometer(pressure, forecast): Function. Update barometric pressure. Forecast can be domoticz.BARO_STABLE, BARO_SUNNY, BARO_CLOUDY, BARO_UNSTABLE, BARO_THUNDERSTORM.Já bych tedy použil: local hodnota_cidla = domoticz.devices('Moje_cidlo_tlaku').barometer Nebo použít univerzální API pro všechny typy sensorů:
Device attributes and methods for all devices active: Boolean. Is true for some common states like 'On' or 'Open' or 'Motion'. Same as bState. batteryLevel: Number If applicable for that device then it will be from 0-100. bState: Boolean. Is true for some common states like 'On' or 'Open' or 'Motion'. Better to use active. changed: Boolean. True if the device was changed description: String. Description of the device. deviceId: String. Another identifier of devices in Domoticz. dzVents uses the id(x) attribute. See device list in Domoticz' settings table. deviceSubType: String. See Domoticz devices table in Domoticz GUI. deviceType: String. See Domoticz devices table in Domoticz GUI. dump(): Function. Dump all attributes to the Domoticz log. This ignores the log level setting. hardwareName: String. See Domoticz devices table in Domoticz GUI. hardwareId: Number. See Domoticz devices table in Domoticz GUI. hardwareType: String. See Domoticz devices table in Domoticz GUI. hardwareTypeValue: Number. See Domoticz devices table in Domoticz GUI. icon: String. Name of the icon in Domoticz GUI. id: Number. Index of the device. You can find the index in the device list (idx column) in Domoticz settings. It's not truly an index but is unique enough for dzVents to be treated as an id. idx: Number. Same as id: index of the device lastUpdate: Time Object: Time when the device was updated. name: String. Name of the device. nValue: Number. Numerical representation of the state. rawData: Table: All values are String types and hold the raw data received from Domoticz. setDescription(description): Function. 2.4.16 Generic method to update the description for all devices, groups and scenes. E.g.: device.setDescription(device.description .. '/nChanged by '.. item.trigger .. 'at ' .. domoticz.time.raw). Supports command options. setIcon(iconNumber): Function. 2.4.17 method to update the icon for devices. Supports command options. setState(newState): Function. Generic update method for switch-like devices. E.g.: device.setState('On'). Supports command options. setValues(nValue,[ sValue1, sValue2, ...]): Function. 2.4.17 Generic alternative method to update device nValue, sValue. Uses domoticz JSON API to force subsequent events like pushing to influxdb. nValue required but when set to nil it will use current nValue. sValue parms are optional and can be many. state: String. For switches, holds the state like 'On' or 'Off'. For dimmers that are on, it is also 'On' but there is a level attribute holding the dimming level. For selector switches (Dummy switch) the state holds the name of the currently selected level. The corresponding numeric level of this state can be found in the rawData attribute: device.rawData[1]. signalLevel: Number If applicable for that device then it will be from 0-100. switchType: String. See Domoticz devices table in Domoticz GUI (Switches tab). E.g. 'On/Off', 'Door Contact', 'Motion Sensor' or 'Blinds' switchTypeValue: Number. See Domoticz devices table in Domoticz GUI. timedOut: Boolean. Is true when the device couldn't be reached. unit: Number. Device unit. See device list in Domoticz' settings for the unit. update(< params >): Function. Generic update method. Accepts any number of parameters that will be sent back to Domoticz. There is no need to pass the device.id here. It will be passed for you. Example to update a temperature: device.update(0,12). This will eventually result in a commandArray entrylocal hodnota_cidla = domoticz.devices('Moje_cidlo_tlaku').nValue
Pressure pressure: Number. updatePressure(pressure): Function.local hodnota_cidla = domoticz.devices('Moje_cidlo_tlaku').pressure
local rozdil = domoticz.devices('Cidlo_po_vodou').barometer - domoticz.devices('Cidlo_venku').barometer
domoticz.devices('Hloubka').updateDistance(rozdil)
'Cidlo_po_vodou' a 'Cidlo_venku' jsou názvy čidel tlaku, které jste zadal v Domoticz při jejich vytváření.
'Hloubka' je název dummy senzoru vzdálenosti vytvořeném v Domoticz pro zobrazení hloubky.
Pokud máte pravidelný tvar nádrže, snadno pak můžete vypočítat objem vody a uložit do dummy senzoru ( typ custom s ozmačením jednotek m3 ) příkazem:
domoticz.devices('Objem_nadrze').updateCustomSensor(spocitany objem)
Případně objem nádrže v procentech s využitím senzoru procent:
domoticz.devices('Objem_v_procentech').updatePercentage(aktualni objem / maximalni objem * 100)
Když chcete akci provést každých pět minut, tak na začátek skriptu dáte:
return {
active = true, -- set to false to disable this script
on = {
timer = {
'every 5 minutes',
}
},
execute = function(domoticz)
Pokud naopak chcete provést při změně hodnoty:
return {
active = true, -- set to false to disable this script
on = {
devices = {
'Loznice_Setpoint'
}
},
execute = function(domoticz, device)
Třeba sepnutí spínače na dobu 5 minut je s DzVents jednoduché jak facka, v porovnání s počítáním uplynulého času v klasické LUA.
domoticz.devices('Muj_casovy_spinac').switchOn().forMin(5)
Bez využití skriptů budete Domoticz používat tak na 20% toho, co umí.
Tiskni
Sdílej: