Add language selection
This commit is contained in:
parent
0100a84c89
commit
d27d6eea9f
2 changed files with 11 additions and 1 deletions
|
@ -53,6 +53,10 @@
|
|||
#define MW_RTC_DATE_MMDD 0x00
|
||||
#define MW_RTC_DATE_DDMM 0x01
|
||||
|
||||
#define MW_LANG_EN 0x00
|
||||
#define MW_LANG_FI 0x01
|
||||
#define MW_LANG_DE 0x02
|
||||
|
||||
#define MW_NVAL_OPERATION 0x30
|
||||
#define MW_NVAL_OPERATION_RSP 0x31
|
||||
|
||||
|
@ -60,7 +64,7 @@
|
|||
#define MW_NVAL_OPERATION_WRITE 0x02
|
||||
#define MW_NVAL_TIME_FORMAT 0x2009
|
||||
#define MW_NVAL_DATE_FORMAT 0x200a
|
||||
|
||||
#define MW_NVAL_LANGUAGE 0x200c
|
||||
|
||||
#define MW_RESERVED 0x32
|
||||
#define MW_STATUS_CHANGE_EVENT 0x33
|
||||
|
|
|
@ -715,6 +715,12 @@ void process_cmd(char *cmdline, int clinep, mwdata_t *mwdata)
|
|||
if (strncmp(cmd, "wet", 3) == 0) {
|
||||
do_weather(mwdata);
|
||||
}
|
||||
if (strncmp(cmd, "lang_de", 7) == 0) {
|
||||
mdata[0] = MW_LANG_DE;
|
||||
mw_nval_operation(&mwdata->mwdevice, MW_NVAL_OPERATION_WRITE, MW_NVAL_LANGUAGE
|
||||
|
||||
ls -l , 1, mdata);
|
||||
}
|
||||
if (strncmp(cmd, "c24", 3) == 0) {
|
||||
mdata[0] = MW_RTC_CLOCK_24HR;
|
||||
mw_nval_operation(&mwdata->mwdevice, MW_NVAL_OPERATION_WRITE, MW_NVAL_TIME_FORMAT, 1, mdata);
|
||||
|
|
Loading…
Reference in a new issue