wiki:SamsungSPF

Version 2 (modified by anonymous, 3 years ago) (diff)

--

Display dpf {

Driver 'DPF' Port 'usb0' Font '6x8' Foreground 'ffffff' Background 'ffffff00' Basecolor '000000' #ffffff00 Orientation 0 # Orientation value from 0-3 Backlight 3 # Backlight variable control, 0..7 (0=off, 7=max)

}

Display Image {

Driver 'Image' Format 'PNG' Size '320x240' Font '6x8' Pixel '4+1' Gap '-1x-1' Border 20 Foreground 'ffffff' Background 'ffffff00' Halfground '#70c000'

}

Widget Bgnd {

class 'Image' file imgadir . 'bakground.png' reload 1 update minute inverted 0 visible 1

}

Widget Year1 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%Y', time()),0,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Year2 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%Y', time()),1,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Year3 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%Y', time()),2,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Year4 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%Y', time()),3,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Month1 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%m', time()),0,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Month2 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%m', time()),1,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Day1 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%d', time()),0,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Day2 {

class 'Image' file imgadir . 'datenumber'. substr(strftime('%d', time()),1,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Week1 {

class 'Image' file imgadir . 'weeknumber'. strftime('%u', time()) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Hour1 {

class 'Image' file imgadir . 'timenumber'. substr(strftime('%H', time()),0,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Hour2 {

class 'Image' file imgadir . 'timenumber'. substr(strftime('%H', time()),1,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Minute1 {

class 'Image' file imgadir . 'timenumber'. substr(strftime('%M', time()),0,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Minute2 {

class 'Image' file imgadir . 'timenumber'. substr(strftime('%M', time()),1,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Second1 {

class 'Image' file imgadir . 'secnumber'. substr(strftime('%S', time()),0,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Second2 {

class 'Image' file imgadir . 'secnumber'. substr(strftime('%S', time()),1,1) . '.png' reload 1 update tick inverted 0 visible 1

}

Widget Weather1 {

class 'Image' file imgadir . 'wbicons/'. file::readline(datadir . 'weather', 2) . DorN . '.png' reload 1 update minute inverted 0 visible 1

}

Widget Weather2 {

class 'Image' file imgadir . 'wsicons/'. file::readline(datadir . 'weather', 6) . 'd.png' reload 1 update minute inverted 0 visible 1

}

Widget WeatherT {

class 'Image' file imgadir . 'tomorrow.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplA01 {

class 'Image' file imgadir . 'tmpnumber'. substr(file::readline(datadir . 'weather', 3), 0, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplA02 {

class 'Image' file imgadir . 'tmpnumber'. substr(file::readline(datadir . 'weather', 3), 1, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplA03 {

class 'Image' file imgadir . 'tmpnumber'. substr(file::readline(datadir . 'weather', 3), 2, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplA04 {

class 'Image' file imgadir . 'tmpnumber'. substr(file::readline(datadir . 'weather', 3), 3, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB01 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 0, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB02 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 1, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB03 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 2, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB04 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 3, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB05 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 4, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB06 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 5, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB07 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 6, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB08 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 7, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB09 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 8, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplB10 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'weather', 5), 9, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC01 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 0, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC02 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 1, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC03 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 2, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC04 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 3, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC05 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 4, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC06 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 5, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC07 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 6, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC08 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 7, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC09 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 8, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaTmplC10 {

class 'Image' file imgadir . 'small'. substr(file::readline(datadir . 'weather', 7), 9, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget WeaInformation1 {

class 'Text' expression file::readline(datadir . 'weather', 8) prefix 'Wind' width 32

# speed tick

align 'R' update tick Background 'FFFFFF00'

}

Widget WeaInformation2 {

class 'Text' expression file::readline(datadir . 'weather', 9) prefix 'Atmos..:' width 32

# speed tick

align 'R' update tick Background 'FFFFFF00'

}

Widget WeaInformation3 {

class 'Text' expression file::readline(datadir . 'weather', 10) width 32 prefix 'Astr..:'

# speed tick

align 'R' update tick Background 'FFFFFF00'

}

Widget PMInfoLevel {

class 'Image' file imgadir . 'airlevel'. file::readline(datadir . 'aqi', 3) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget PMInfoMain {

class 'Image' file imgadir . 'aqi'. file::readline(datadir . 'aqi', 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget PMDetail1 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'aqi', 2), 0, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget PMDetail2 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'aqi', 2), 1, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget PMDetail3 {

class 'Image' file imgadir . 'tmpnums'. substr(file::readline(datadir . 'aqi', 2), 2, 1) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget Kernel1 {

class 'Text' expression uname('sysname') width 13 align 'R' update minute Background 'FFFFFF00'

}

Widget Kernel2 {

class 'Text' expression uname('release') width 13 align 'R' update minute Background 'FFFFFF00'

}

Widget CPUText {

class 'Text' expression uname('machine') prefix 'CPU' width 13 align 'R' update minute Background 'FFFFFF00'

}

Widget CPUBar {

class 'Bar' expression proc_stat::cpu('busy', 500) length 13 direction 'E'

# style 'H'

update tack Foreground '5f5f5f' Background '00FF00FF' BarColor0 'FF0000' BarColor1 'EE3333'

}

Widget RAMText1 {

class 'Text' expression meminfo('MemTotal?')/1024 prefix 'RAM' postfix 'MB' precision 0 width 13 align 'R' update tick Background 'FFFFFF00'

}

Widget RAMText2 {

class 'Text' expression meminfo('MemFree?')/1024 prefix 'Free' postfix 'MB' precision 0 width 13 align 'R' update tick Background 'FFFFFF00'

}

Widget RAMBar {

class 'Bar' expression meminfo('MemTotal?') - meminfo('MemFree?') max meminfo('MemTotal?') length 13 direction 'E'

# style 'H'

update tack Foreground '5f5f5f' Background '00FF00FF' BarColor0 'FF0000' BarColor1 'EE3333'

}

Widget LoadText? {

class 'Text' expression loadavg(1) prefix 'Load:' postfix loadavg(1)>1.0?'!': width 13 align 'R' precision 1 update tack Background 'FFFFFF00'

}

Widget LoadBar? {

class 'Bar' expression loadavg(1) max 2.0 length 13 direction 'E'

# style 'H'

update tack Foreground '5f5f5f' Background '00FF00FF' BarColor0 'FF0000' BarColor1 'EE3333'

}

Widget DiskText1 {

class 'Text' expression diskstats('sda', 'read_sectors', 500)/2 prefix 'Read:' postfix 'K' precision 0 width 13 align 'R' update tick Foreground 'ffffff' Background 'FFFFFF00'

}

Widget DiskText2 {

class 'Text' expression diskstats('sda', 'write_sectors', 500)/2 prefix 'Write:' postfix 'K' precision 0 width 13 align 'R' update tick Foreground 'ffffff' Background 'FFFFFF00'

}

Widget DiskBar? {

class 'Bar' expression diskstats('sda', 'read_sectors', 500) expression2 diskstats('sda', 'write_sectors', 500) length 13 direction 'E'

# style 'H'

update tack Foreground '5f5f5f' Background '3f3f3fFF' BarColor0 '00FF00' BarColor1 'FF0000'

}

Widget SpaceText1 {

class 'Text' expression statfs(SpaceDir?, 'blocks')*statfs(SpaceDir?, 'bsize')/1073741824 prefix SpaceDir? postfix 'G' precision 0 width 13 align 'R' update minute Foreground 'ffffff' Background 'FFFFFF00'

}

Widget SpaceText2 {

class 'Text' expression statfs(SpaceDir?, 'bavail')*statfs(SpaceDir?, 'bsize')/1073741824 prefix 'Free:' postfix 'G' precision 0 width 13 align 'R' update minute Foreground 'ffffff' Background 'FFFFFF00'

}

Widget SpaceBar? {

class 'Bar' expression statfs(SpaceDir?, 'blocks') - statfs(SpaceDir?, 'bavail') length 13 direction 'E'

# style 'H'

max statfs(SpaceDir?, 'blocks') update tick Foreground '5f5f5f' Background '00FF00FF' BarColor0 'FF0000' BarColor1 'EE3333'

}

Widget NetText1 {

class 'Text' expression netdev::fast('eth1', 'Tx_bytes', 500)/1024 prefix 'Up:' postfix 'K/s' width 13 precision 0 align 'R' update tick Foreground 'ffffff' Background 'FFFFFF00'

}

Widget NetText2 {

class 'Text' expression netdev::fast('eth1', 'Rx_bytes', 500)/1024 prefix 'Down:' postfix 'K/s' precision 0 width 13 align 'R' update tick Foreground 'ffffff' Background 'FFFFFF00'

}

Widget NetBar? {

class 'Bar' expression netdev('eth1', 'Tx_bytes', 500) expression2 netdev('eth1', 'Rx_bytes', 500) length 13 direction 'E'

# style 'H' # max 2097152 # max 204800

update tack Foreground '5f5f5f' Background '3F3F3FFF' BarColor0 '00FF00' BarColor1 'FF0000'

}

Widget UpText? {

class 'Text' expression uptime('%dd %H:%M:%S') width 13 align 'R' update tick Foreground 'ffffff' Background 'FFFFFF00'

}

Widget IPText {

class 'Text' expression netinfo::ipaddr('eth1') width 15 align 'L' update minute Foreground 'ffffff' Background 'FFFFFF00'

}

Widget AqiBar01 {

class 'Image'

# file datadir . 'aqi' . (file::readline(datadir . 'aqilast', 1)) . '.png'

file datadir . 'aqi.png' reload 1 update minute inverted 0 visible 1

}

Widget AqiMain? {

class 'Image' file imgadir . 'aqi' . (file::readline(datadir . 'aqi', 1)) . '.png' reload 1 update minute inverted 0 visible 1

}

Widget DorNFlag {

class 'Timer' expression DorN=(((strftime('%H%M', time()))>(file::readline(datadir.'weather',11))) & ((strftime('%H%M', time()))<(file::readline(datadir.'weather',12)+1200)))?'d':'n' active 1 update second

}

Display 'DPF'

#Display 'Image'

Layout mylayout {

Row02.Col40 'Kernel1' Row03.Col40 'Kernel2' Row05.Col40 'CPUText' Row06.Col40 'CPUBar' Row08.Col40 'LoadText?' Row09.Col40 'LoadBar?' Row11.Col40 'RAMText1' Row12.Col40 'RAMText2' Row13.Col40 'RAMBar' Row15.Col40 'DiskText1' Row16.Col40 'DiskText2' Row17.Col40 'DiskBar?' Row19.Col40 'SpaceText1' Row20.Col40 'SpaceText2' Row21.Col40 'SpaceBar?' Row23.Col40 'NetText1' Row24.Col40 'NetText2' Row25.Col40 'NetBar?' Row27.Col40 'UpText?' Row28.Col40 'IPText' Row27.Col2 'WeaInformation1' Row28.Col2 'WeaInformation2' Row29.Col2 'WeaInformation3'

Layer 2 {

X1.Y1 'Bgnd'

} Layer 1 {

X99.Y1 'Weather1'

X107.Y141 'Weather2'

X14.Y10 'Year1' X14.Y24 'Year2' X14.Y38 'Year3' X14.Y52 'Year4' X14.Y72 'Month1' X14.Y86 'Month2' X14.Y106 'Day1' X14.Y120 'Day2' X12.Y145 'Week1' X52.Y22 'Hour1' X52.Y61 'Hour2' X52.Y116 'Minute1' X52.Y154 'Minute2' X103.Y99 'Second1' X103.Y107 'Second2'

} Layer 0 {

X155.Y140 'PMDetail1' X155.Y148 'PMDetail2' X155.Y156 'PMDetail3'

X153.Y166 'PMInfoLevel' X169.Y134 'AqiMain?' X185.Y124 'AqiBar01'

X161.Y44 'WeaTmplA01' X161.Y62 'WeaTmplA02' X161.Y80 'WeaTmplA03' X161.Y98 'WeaTmplA04'

X189.Y36 'WeaTmplB01' X189.Y44 'WeaTmplB02' X189.Y52 'WeaTmplB03' X189.Y60 'WeaTmplB04' X189.Y68 'WeaTmplB05' X189.Y76 'WeaTmplB06' X189.Y84 'WeaTmplB07' X189.Y92 'WeaTmplB08' X189.Y100 'WeaTmplB09' X189.Y108 'WeaTmplB10'

X137.Y138 'WeaTmplC01' X137.Y144 'WeaTmplC02' X137.Y150 'WeaTmplC03' X137.Y156 'WeaTmplC04' X137.Y162 'WeaTmplC05' X137.Y168 'WeaTmplC06' X137.Y174 'WeaTmplC07' X137.Y180 'WeaTmplC08' X137.Y186 'WeaTmplC09' X137.Y192 'WeaTmplC10' X117.Y182 'WeatherT'

} Timer1 'DorNFlag'

}

Layout 'mylayout'

Variables {

backlight 4 tick 500 tack 200 second 1000 minute 60000 DorN 'd' imgadir '/mnt/lcd4linux/img/' datadir '/mnt/lcd4linux/data/' SpaceDir? '/volume2'

} # Timer

Widget FlagOnOffTimer? {

class 'Timer' expression flagOnOff=(time() % 10 < 5)?0:1 active 1 update tick

}

Widget FlagStateTimer? {

class 'Timer' expression flagState=(time() % 15 < 5)?1:((time() % 15 > 9)?3:2) active 1 update tick

}

Widget LcdLightTimer?{

class 'Timer' expression LCD::backlight(file::readline(cfgpath . 'light.conf', 1)) active 1 update second * 5

} # Timer

Timer1 'FlagOnOffTimer?' Timer2 'FlagStateTimer?' Timer3 'LcdLightTimer?'

}

Attachments (1)

Download all attachments as: .zip