System Variables of TJC Panel

No

Name

Meaning

Example/Description

1

dp

Current

Page ID

1.dp=1 (Set current page to 1)

2.prints dp,0(Send current page ID)

3.n0.val=dp (Set n0.val to current page ID)

2

dim

Brightness of Backlight(0-100)

1.dim=50   2.dim=dim+10   3.dim=dim-10

3

dims

Default Brightness (0-100)

1.dims=50   2.dims=dims+10   3.dims=dims-10

4

baud

Baud Rate

Lost set when power off

baud=9600v

Supported:2400 4800 9600 19200 38400 57600 115200 230400 256000 512000 921600

5

bauds

Default Baud Rate

Will not lost when power off

bauds=9600

6

spax

Font Spacing horizontally (Default 0)

spax=2

Sets the default rendering space for xstr

7

spay

Font Spacing vertically (Default 0)

spay=2

Sets the default rendering space for xstr

8

thc

Touch Draw Brush Color

1.thc=RED   2.thc=1024

9

thdra

Touch Drawing

thdra=0 (Turn Off)   thdra=1(Turn On)

10

ussp

Sleep on No Serial (in seconds,minimum 3,maximum 65535,default 0, no sleep)

ussp=30

11

thsp

Sleep on No Touch(in seconds,minimum 3,maximum 65535,default 0, no sleep)

thsp=30

12

thup

Auto Wake on Touch (Default 0)

thup=0(do not wake)

thup=1(wake on touch)

thup has no influence on sendxy, sendxy will operate independently

13

usup

Wake On Serial Data (Default 0)

usup=0(do not wake)

usup=1(wake on serial data)

When usup=1, any serial received wakes

14

wup

Wake Up Page

wup=255(Default, wake up page before sleep)

wup=2   (wake up to page:2)

wup can be set even when panel is in sleep mode

15

sleep

Sleep

sleep=0 (Exit sleep mode)

sleep=1 (Enter sleep mode)

 A get/print/printh/wup/sleep instruction can be executed during sleep mode. Extended IO binding interrupts do not occur in sleep

 

16

bkcmd

Pass / Fail

Return Data

min 0, max 3, default 2

– Level 0 is Off – no pass/fail will be returned

– Level 1 is OnSuccess, only when last serial command successful.

– Level 2 is OnFailure, only when last serial command failed

– Level 3 is Always, returns 0x00 to 0x23 result of serial command.

17

sendxy

RealTime Touch Coordinates

sendxy=1 (start sending) sendxy=0 (stop sending)

18

delay

delay

delay=100   (halt 100ms)

As delay is interpreted, a total halt is avoided. Incoming serial data is received and stored in buffer but not be processed until delay ends.

19

rand

Random number

dim=rand

n0.val=rand

Readonly. Value returned by rand is random every time it is referred to.range of rand is user customizable using the randset command range as set with randset will persist until reboot or reset

20

tch0-tch3

Touch Coordinates

tch0:current x coordinate

tch1:current y coordinate

tch2:last click x coordinate

tch3:last click y coordinate

Readonly.

21

addr

Address of device

addr=256 or addr=0x0100

Range: 256-2815(0x0100-0x0aff)

0 mean no addr (default value)

When send command to a device with addr. The address (two bytes Hex) are add before the command.

22

crcval

crc status

n0.val=crcval

prints crcval,2 

Read only. Use crcrest to reset and initialize

Use crcputs, crcputh or crcputu to accumulate

23

rtc0-rtc6

RTC value

n0.val=rtc5

rtc0 is year 2000 to 2099, rtc1 is month 1 to 12, rtc2 is day 1 to 31,

rtc3 is hour 0 to 23, rtc4 is minute 0 to 59, rtc5 is second 0 to 59.

rtc6 is dayofweek 0 to 6 (Sunday=0, Saturday=6)

rtc6 is readonly and calculated by RTC when date is valid.

24

pio0-pio7

GPIO

pio4=1    

Default mode when power on: pull up input mode

Internal pull up resistor: 50K

GPIO is digital. Value of 0 or 1 only.

– refer to cfgpio command for setting GPIO mode

read if in input mode, write if in output mode   

25

pwm4-pwm7

PWM Duty Cycle

pwm6=30  pwm7=90 

 Value in percentage. min 0, max 100, default 50.

– refer to cfgpio command for setting GPIO mode

K0:io4-io7 (pwm4-pwm7)

X5:io6-io7 (pwm6-pwm7)

26

pwmf

PWM Frequency

pwmf=1024 (set frequency of pwm to1024HZ)

n0.val=pwmf

Value is in Hz. min value 1 Hz, max value 65535 Hz. default 1000 Hz

All PWM output is unified to only one Frequency, no independent individual settings are allowed.

– refer to cfgpio command for setting GPIO mode

27

eql

Equalizer Groupings

eql: Bass (31Hz to 125Hz, eq0..eq2)

eqm: Midrange (250Hz to 2000Hz, eq3..eq6)

eqh: Treble (4000Hz to 1600Hz, eq7..eq9)

Vaule:0-15

Setting to 7 is Balanced with no attenuation, no gain

Setting 0..6, the lower the value the higher the attenuation

Setting 8..15, the higher the value the higher the gain

NOTE: The base of the equalizer is operated according to eq0..eq9,

when a group is modified the corresponding individual bands are modified, however modifying an individual band does not modify the group. (ie: setting eql=4 sets eq0, eq1 and eq2 to 4, but setting eq1=3 does not modify eql to 3, eq0 and eq2 remain at 4).

28

eq0-eq9

Equalizer Individual Bands

eq0@31HZ

eq1@62HZ

eq2@125HZ

eq3@250HZ

eq4@500HZ   

eq5@1000HZ

eq6@2000HZ  

eq7@4000HZ

eq8@8000HZ

eq9@16000HZ

Range: 0-15

Valid on Device, not supported in Debug Simulator.

Setting to 7 is Balanced with no attenuation, no gain

Setting 0..6, the lower the value the higher the attenuation

Setting 8..15, the higher the value the higher the gain

NOTE: The base of the equalizer is operated according to eq0..eq9,

when a group is modified the corresponding individual bands are modified, however modifying an individual band does not modify the group. (ie: setting eql=4 sets eq0, eq1 and eq2 to 4, but setting eq1=3 does not modify eql to 3, eq0 and eq2 remain at 4).

29

volume

Audio Volume

volume=60

min is 0, max is 100

volume persists and sets the power-on default setting for the audio volume

30

audio0

Audio Channel Control

audio0=0// stop channel 0 audio playback

min is 0, max is 2

0 (stop), 1 (resume), 2 (pause).

 The play instruction is used to configure and start audio playback. audio0 and audio1 are only used to control the channel. Only if the channel is paused can it be resumed, if the channel is stopped then the play instruction is required to start it again. Audio playback is global and playback continues after leaving and changing pages, if you want the channel to stop on leaving the page, you must do so in the page leave event


Selection Guide of DACAI USART HMI Display