ver 1.8b
This commit is contained in:
parent
f9649f8437
commit
1e8684f258
41 changed files with 21495 additions and 64 deletions
|
|
@ -74,6 +74,7 @@ _Далее, с помощью соединения BLE в [PHY62x2BTHome.html](
|
|||
| 1.5 | Добавлен вариант шифрования BLE рекламы с помощью BindKey. |
|
||||
| 1.6 | Добавлено усреднение расчета напряжения батареи, дублирование состояния контакта open/close и счетчика через 12..20 сек (кратно интервалу рекламы) после срабатывания и далее каждые 30 минут. |
|
||||
| 1.7 | Исправление ошибки (> 42 C) для сенсора CHT8305 |
|
||||
| 1.8b | Добавлено отображение температуры в градусах Фаренгейта |
|
||||
|
||||
## Прошивка
|
||||
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ Files for updating boot via OTA are located in the [update_boot](update_boot) di
|
|||
| 1.5 | <ul><li>Added option to encrypt BLE ads with BindKey.</li></ul> |
|
||||
| 1.6 | <ul><li>Added averaging of battery voltage calculation</li><li>Added duplication of open/close contact</li><li>Added counter status 12..20 sec (multiple of ad interval) after triggering and then every 30 min. |
|
||||
| 1.7 | <ul><li>Fixed en error (> 42 C) for sensor CHT8305</li></ul> |
|
||||
| 1.8beta | <ul><li>Added display of temperature in degrees Fahrenheit</li></ul> |
|
||||
|
||||
## Firmware
|
||||
|
||||
|
|
|
|||
3003
bin/BOOT_BTH01_v18.hex
Normal file
3003
bin/BOOT_BTH01_v18.hex
Normal file
File diff suppressed because it is too large
Load diff
3076
bin/BOOT_TH05D_v18.hex
Normal file
3076
bin/BOOT_TH05D_v18.hex
Normal file
File diff suppressed because it is too large
Load diff
3073
bin/BOOT_TH05F_v18.hex
Normal file
3073
bin/BOOT_TH05F_v18.hex
Normal file
File diff suppressed because it is too large
Load diff
3070
bin/BOOT_TH05_v18.hex
Normal file
3070
bin/BOOT_TH05_v18.hex
Normal file
File diff suppressed because it is too large
Load diff
3067
bin/BOOT_THB1_v18.hex
Normal file
3067
bin/BOOT_THB1_v18.hex
Normal file
File diff suppressed because it is too large
Load diff
3000
bin/BOOT_THB2_v18.hex
Normal file
3000
bin/BOOT_THB2_v18.hex
Normal file
File diff suppressed because it is too large
Load diff
3067
bin/BOOT_THB3_v18.hex
Normal file
3067
bin/BOOT_THB3_v18.hex
Normal file
File diff suppressed because it is too large
Load diff
BIN
bin/BTH01_v18.bin
Normal file
BIN
bin/BTH01_v18.bin
Normal file
Binary file not shown.
BIN
bin/TH05D_v18.bin
Normal file
BIN
bin/TH05D_v18.bin
Normal file
Binary file not shown.
BIN
bin/TH05F_v18.bin
Normal file
BIN
bin/TH05F_v18.bin
Normal file
Binary file not shown.
BIN
bin/TH05_v18.bin
Normal file
BIN
bin/TH05_v18.bin
Normal file
Binary file not shown.
BIN
bin/THB1_v18.bin
Normal file
BIN
bin/THB1_v18.bin
Normal file
Binary file not shown.
BIN
bin/THB2_v18.bin
Normal file
BIN
bin/THB2_v18.bin
Normal file
Binary file not shown.
BIN
bin/THB3_v18.bin
Normal file
BIN
bin/THB3_v18.bin
Normal file
Binary file not shown.
|
|
@ -1,5 +1,5 @@
|
|||
@set PATH=D:\MCU\GNU_Tools_ARM_Embedded\13.2.rel1\bin;%PATH%
|
||||
@set SWVER=_v17
|
||||
@set SWVER=_v18
|
||||
@del /Q "build\THB2%SWVER%.hex"
|
||||
@del /Q "build\THB2%SWVER%.bin"
|
||||
@mkdir .\bin
|
||||
|
|
|
|||
|
|
@ -104,6 +104,8 @@ int cmd_parser(uint8_t * obuf, uint8_t * ibuf, uint32_t len) {
|
|||
obuf[1] = 0; // no err
|
||||
if (cmd == CMD_ID_DEVID) { // Get DEV_ID
|
||||
memcpy(obuf, &dev_id, sizeof(dev_id));
|
||||
dev_id_t * p = (dev_id_t *)&obuf;
|
||||
p->dev_spec_data = thsensor_cfg.sensor_type;
|
||||
olen = sizeof(dev_id);
|
||||
} else if (cmd == CMD_ID_CFG) { // Get/Set device config
|
||||
if (--len > sizeof(cfg))
|
||||
|
|
@ -151,7 +153,7 @@ int cmd_parser(uint8_t * obuf, uint8_t * ibuf, uint32_t len) {
|
|||
memcpy(&obuf[1], &thsensor_cfg, thsensor_cfg_send_size);
|
||||
olen = thsensor_cfg_send_size + 1;
|
||||
} else if (cmd == CMD_ID_SEN_ID) {
|
||||
memcpy(&obuf[1], (uint8_t *)&thsensor_cfg.mid, 5);
|
||||
memcpy(&obuf[1], (uint8_t *)&thsensor_cfg.mid, 6);
|
||||
olen = 1 + 5;
|
||||
#if (OTA_TYPE == OTA_TYPE_APP) && ((DEV_SERVICES & SERVICE_TH_TRG) || (DEV_SERVICES & SERVICE_SCREEN))
|
||||
} else if (cmd == CMD_ID_TRG) { // Get/Set tigger data config
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
// #include "bus_dev.h"
|
||||
|
||||
#ifndef APP_VERSION
|
||||
#define APP_VERSION 0x17 // BCD
|
||||
#define APP_VERSION 0x18 // BCD
|
||||
#endif
|
||||
|
||||
/* rf_phy_ana_cfg
|
||||
|
|
@ -64,6 +64,7 @@
|
|||
#define SERVICE_TIME_ADJUST 0x00001000 // пока нет // есть функция коррекции счета времени
|
||||
#define SERVICE_HARD_CLOCK 0x00002000 // пока нет // есть реальные часы RTC
|
||||
#define SERVICE_TH_TRG 0x00004000 // триггер по температуре и влажности
|
||||
#define SERVICE_LED 0x00008000 // use led
|
||||
|
||||
#define OTA_TYPE_NONE 0 // нет OTA, только переключение из APP на boot прошивку
|
||||
#define OTA_TYPE_BOOT SERVICE_OTA // вариант для прошивки boot + OTA
|
||||
|
|
@ -380,6 +381,7 @@ extern const cfg_t def_cfg;
|
|||
#define FLG_SHOW_TRG 0x00000008 // смайлик поаказывает TRG
|
||||
#define FLG_DISPLAY_OFF 0x00000010 // отключить дисплей
|
||||
#define FLG_ADV_CRYPT 0x00000020 // Зашифрованная BLE реклама (bindkey)
|
||||
#define FLG_SHOW_TF 0x00000040 // Show temperature in F.
|
||||
|
||||
typedef struct _adv_work_t {
|
||||
uint32_t measure_interval_ms;
|
||||
|
|
|
|||
|
|
@ -210,10 +210,18 @@ void chow_clock(void) {
|
|||
|
||||
static void chow_measure(void) {
|
||||
#if (DEV_SERVICES & SERVICE_THS)
|
||||
show_big_number_x10(measured_data.temp/10);
|
||||
show_small_number(measured_data.humi/100, true);
|
||||
if(cfg.flg & FLG_SHOW_TF) {
|
||||
show_big_number_x10(((int32_t)((int32_t)measured_data.temp * 9)/ 50) + 320); // convert C to F
|
||||
show_temp_symbol(LCD_TSYMBOL_F); // "°F"
|
||||
} else {
|
||||
show_big_number_x10((measured_data.temp + 5)/10);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
}
|
||||
int16_t h = (measured_data.humi + 50)/100;
|
||||
if(h > 99)
|
||||
h = 99;
|
||||
show_small_number(h, true);
|
||||
show_battery_symbol(measured_data.battery < 20);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
#if (OTA_TYPE == OTA_TYPE_APP)
|
||||
if(cfg.flg & FLG_SHOW_SMILEY) {
|
||||
#if (DEV_SERVICES & SERVICE_TH_TRG)
|
||||
|
|
|
|||
|
|
@ -302,10 +302,18 @@ void chow_clock(void) {
|
|||
|
||||
static void chow_measure(void) {
|
||||
#if (DEV_SERVICES & SERVICE_THS)
|
||||
show_big_number_x10(measured_data.temp/10);
|
||||
show_small_number(measured_data.humi/100, true);
|
||||
if(cfg.flg & FLG_SHOW_TF) {
|
||||
show_big_number_x10(((int32_t)((int32_t)measured_data.temp * 9)/ 50) + 320); // convert C to F
|
||||
show_temp_symbol(LCD_TSYMBOL_F); // "°F"
|
||||
} else {
|
||||
show_big_number_x10((measured_data.temp + 5)/10);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
}
|
||||
int16_t h = (measured_data.humi + 50)/100;
|
||||
if(h > 99)
|
||||
h = 99;
|
||||
show_small_number(h, true);
|
||||
show_battery(measured_data.battery);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
#if (OTA_TYPE == OTA_TYPE_APP)
|
||||
if(cfg.flg & FLG_SHOW_SMILEY) {
|
||||
#if (DEV_SERVICES & SERVICE_TH_TRG)
|
||||
|
|
|
|||
|
|
@ -220,10 +220,18 @@ void chow_clock(void) {
|
|||
|
||||
static void chow_measure(void) {
|
||||
#if (DEV_SERVICES & SERVICE_THS)
|
||||
show_big_number_x10(measured_data.temp/10);
|
||||
show_small_number(measured_data.humi/100, true);
|
||||
if(cfg.flg & FLG_SHOW_TF) {
|
||||
show_big_number_x10(((int32_t)((int32_t)measured_data.temp * 9)/ 50) + 320); // convert C to F
|
||||
show_temp_symbol(LCD_TSYMBOL_F); // "°F"
|
||||
} else {
|
||||
show_big_number_x10((measured_data.temp + 5)/10);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
}
|
||||
int16_t h = (measured_data.humi + 50)/100;
|
||||
if(h > 99)
|
||||
h = 99;
|
||||
show_small_number(h, true);
|
||||
show_battery_symbol(measured_data.battery < 20);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
#if (OTA_TYPE == OTA_TYPE_APP)
|
||||
if(cfg.flg & FLG_SHOW_SMILEY) {
|
||||
#if (DEV_SERVICES & SERVICE_TH_TRG)
|
||||
|
|
|
|||
|
|
@ -227,10 +227,18 @@ void chow_clock(void) {
|
|||
|
||||
static void chow_measure(void) {
|
||||
#if (DEV_SERVICES & SERVICE_THS)
|
||||
show_big_number_x10(measured_data.temp/10);
|
||||
show_small_number(measured_data.humi/100, true);
|
||||
if(cfg.flg & FLG_SHOW_TF) {
|
||||
show_big_number_x10(((int32_t)((int32_t)measured_data.temp * 9)/ 50) + 320); // convert C to F
|
||||
show_temp_symbol(LCD_TSYMBOL_F); // "°F"
|
||||
} else {
|
||||
show_big_number_x10((measured_data.temp + 5)/10);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
}
|
||||
int16_t h = (measured_data.humi + 50)/100;
|
||||
if(h > 99)
|
||||
h = 99;
|
||||
show_small_number(h, true);
|
||||
show_battery(measured_data.battery);
|
||||
show_temp_symbol(LCD_TSYMBOL_C);
|
||||
#if (OTA_TYPE == OTA_TYPE_APP)
|
||||
if(cfg.flg & FLG_SHOW_SMILEY) {
|
||||
#if (DEV_SERVICES & SERVICE_TH_TRG)
|
||||
|
|
|
|||
|
|
@ -27,25 +27,28 @@ dev_i2c_t i2c_dev0 = {
|
|||
|
||||
thsensor_cfg_t thsensor_cfg;
|
||||
|
||||
const thsensor_coef_t def_thcoef_cht8215 = {
|
||||
.temp_k = 25606,
|
||||
.humi_k = 20000,
|
||||
.temp_z = 0,
|
||||
.humi_z = 0
|
||||
const thsensor_def_cfg_t def_thcoef_cht8215 = {
|
||||
.coef.temp_k = 25606,
|
||||
.coef.humi_k = 20000,
|
||||
.coef.temp_z = 0,
|
||||
.coef.humi_z = 0,
|
||||
.sensor_type = TH_SENSOR_CHT8215
|
||||
};
|
||||
|
||||
const thsensor_coef_t def_thcoef_cht8305 = {
|
||||
.temp_k = 16500,
|
||||
.humi_k = 10000,
|
||||
.temp_z = -4000,
|
||||
.humi_z = 0
|
||||
const thsensor_def_cfg_t def_thcoef_cht8305 = {
|
||||
.coef.temp_k = 16500,
|
||||
.coef.humi_k = 10000,
|
||||
.coef.temp_z = -4000,
|
||||
.coef.humi_z = 0,
|
||||
.sensor_type = TH_SENSOR_CHT8305
|
||||
};
|
||||
|
||||
const thsensor_coef_t def_thcoef_aht30 = {
|
||||
.temp_k = 1250,
|
||||
.humi_k = 625,
|
||||
.temp_z = -5000,
|
||||
.humi_z = 0
|
||||
const thsensor_def_cfg_t def_thcoef_aht30 = {
|
||||
.coef.temp_k = 1250,
|
||||
.coef.humi_k = 625,
|
||||
.coef.temp_z = -5000,
|
||||
.coef.humi_z = 0,
|
||||
.sensor_type = TH_SENSOR_AHT2x
|
||||
};
|
||||
|
||||
|
||||
|
|
@ -55,7 +58,7 @@ int read_sensor_cht8305(pdev_i2c_t pi2c_dev) {
|
|||
if (!read_i2c_nabuf(pi2c_dev, thsensor_cfg.i2c_addr, reg_data, 4)) {
|
||||
_temp = (reg_data[0] << 8) | reg_data[1];
|
||||
measured_data.temp = ((uint32_t)(_temp * thsensor_cfg.coef.temp_k) >> 16) + thsensor_cfg.coef.temp_z;; // x 0.01 C
|
||||
_temp = ((reg_data[2] << 8) | reg_data[3]); // & 0x7fff ;
|
||||
_temp = (reg_data[2] << 8) | reg_data[3];
|
||||
measured_data.humi = ((uint32_t)(_temp * thsensor_cfg.coef.humi_k) >> 16) + thsensor_cfg.coef.humi_z; // x 0.01 %
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -70,7 +73,7 @@ int read_sensor_cht821x(pdev_i2c_t pi2c_dev) {
|
|||
&& read_i2c_bytes(pi2c_dev, thsensor_cfg.i2c_addr, CHT83xx_REG_HMD, ®_data[2], 2) == 0) {
|
||||
_r16 = (reg_data[0] << 8) | reg_data[1];
|
||||
measured_data.temp = ((int32_t)(_r16 * thsensor_cfg.coef.temp_k) >> 16) + thsensor_cfg.coef.temp_z;; // x 0.01 C
|
||||
_r32 = ((reg_data[2] << 8) | reg_data[3]); // & 0x7fff ;
|
||||
_r32 = ((reg_data[2] << 8) | reg_data[3]); // & 0x7fff;
|
||||
measured_data.humi = ((uint32_t)(_r32 * thsensor_cfg.coef.humi_k) >> 16) + thsensor_cfg.coef.humi_z; // x 0.01 %
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -133,8 +136,9 @@ void start_measure(void) {
|
|||
|
||||
__ATTR_SECTION_XIP__
|
||||
void init_sensor(void) {
|
||||
uint8_t *ptabinit = NULL;
|
||||
thsensor_def_cfg_t *ptabinit = NULL;
|
||||
thsensor_cfg.read_sensor = NULL;
|
||||
thsensor_cfg.sensor_type = TH_SENSOR_NONE;
|
||||
init_i2c(&i2c_dev0);
|
||||
//send_i2c_byte(0,6);
|
||||
thsensor_cfg.i2c_addr = CHT83xx_I2C_ADDR;
|
||||
|
|
@ -150,13 +154,13 @@ void init_sensor(void) {
|
|||
// Configure
|
||||
send_i2c_wreg(&i2c_dev0, thsensor_cfg.i2c_addr, CHT8305_REG_CFG, CHT8305_CFG_MODE );
|
||||
#endif
|
||||
ptabinit = (uint8_t *)&def_thcoef_cht8305;
|
||||
ptabinit = (thsensor_def_cfg_t *)&def_thcoef_cht8305;
|
||||
thsensor_cfg.read_sensor = read_sensor_cht8305;
|
||||
} else if(thsensor_cfg.vid == CHT8215_VID) { // 0x8210/0x8215 ?
|
||||
if(adv_wrk.measure_interval_ms >= 5000) // > 5 sec
|
||||
send_i2c_wreg(&i2c_dev0, thsensor_cfg.i2c_addr, CHT8215_REG_CRT, 0x0300); // Set conversion ratio 5 sec
|
||||
// else 1 sec
|
||||
ptabinit = (uint8_t *)&def_thcoef_cht8215;
|
||||
ptabinit = (thsensor_def_cfg_t *)&def_thcoef_cht8215;
|
||||
thsensor_cfg.read_sensor = read_sensor_cht821x;
|
||||
}
|
||||
} else
|
||||
|
|
@ -164,7 +168,7 @@ void init_sensor(void) {
|
|||
} else {
|
||||
thsensor_cfg.i2c_addr = AHT2x_I2C_ADDR;
|
||||
if(!send_i2c_wreg(&i2c_dev0, thsensor_cfg.i2c_addr, AHT2x_CMD_TMS, AHT2x_DATA_TMS)) {
|
||||
ptabinit = (uint8_t *)&def_thcoef_aht30;
|
||||
ptabinit = (thsensor_def_cfg_t *)&def_thcoef_aht30;
|
||||
thsensor_cfg.read_sensor = read_sensor_ahtxx;
|
||||
thsensor_cfg.vid = 0xAAAA;
|
||||
} else
|
||||
|
|
@ -172,6 +176,7 @@ void init_sensor(void) {
|
|||
}
|
||||
if(thsensor_cfg.coef.temp_k == 0 && ptabinit) {
|
||||
memcpy(&thsensor_cfg.coef, ptabinit, sizeof(thsensor_cfg.coef));
|
||||
thsensor_cfg.sensor_type = ptabinit->sensor_type;
|
||||
}
|
||||
deinit_i2c(&i2c_dev0);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
Author: pvvx
|
||||
*/
|
||||
|
||||
#ifndef _SENSORS_H_
|
||||
#define _SENSORS_H_
|
||||
#ifndef _SRC_SENSORS_H_
|
||||
#define _SRC_SENSORS_H_
|
||||
|
||||
#include "config.h"
|
||||
|
||||
|
|
@ -136,6 +136,16 @@ struct __attribute__((packed)) _cht8305_config_t{
|
|||
#define AHT2x_CMD_RST 0x0BA // Soft Reset Command
|
||||
#define AHT2x_DATA_LPWR 0x0800 // go into low power mode
|
||||
|
||||
enum {
|
||||
TH_SENSOR_NONE = 0,
|
||||
TH_SENSOR_SHTC3, // 1
|
||||
TH_SENSOR_SHT4x, // 2
|
||||
TH_SENSOR_SHT30, // 3
|
||||
TH_SENSOR_CHT8305, // 4
|
||||
TH_SENSOR_AHT2x, // 5
|
||||
TH_SENSOR_CHT8215, // 6
|
||||
TH_SENSOR_TYPE_MAX // 7
|
||||
}; // TH_SENSOR_TYPES
|
||||
|
||||
typedef struct __attribute__((packed)) _measured_flg_t {
|
||||
uint8_t pin_input : 1; // GPIO_INP input pin
|
||||
|
|
@ -162,7 +172,13 @@ typedef struct _thsensor_coef_t {
|
|||
uint32_t humi_k;
|
||||
int16_t temp_z;
|
||||
int16_t humi_z;
|
||||
} thsensor_coef_t;
|
||||
} thsensor_coef_t; // [12]
|
||||
|
||||
typedef struct _thsensor_def_cfg_t {
|
||||
thsensor_coef_t coef;
|
||||
// uint32_t measure_timeout;
|
||||
uint8_t sensor_type; // TH_SENSOR_TYPES
|
||||
} thsensor_def_cfg_t;
|
||||
|
||||
typedef int (*psernsor_rd_t)(pdev_i2c_t pi2c_dev);
|
||||
//typedef void (*psernsor_sm_t)(void);
|
||||
|
|
@ -172,6 +188,7 @@ typedef struct _thsensor_cfg_t {
|
|||
uint16_t mid;
|
||||
uint16_t vid;
|
||||
uint8_t i2c_addr;
|
||||
uint8_t sensor_type; // TH_SENSOR_TYPES
|
||||
psernsor_rd_t read_sensor;
|
||||
// psernsor_sm_t start_measure;
|
||||
} thsensor_cfg_t;
|
||||
|
|
@ -197,4 +214,4 @@ extern measured_data_t measured_data;
|
|||
|
||||
#endif // (DEV_SERVICES & SERVICE_THS)
|
||||
|
||||
#endif // _SENSORS_H_
|
||||
#endif // _SRC_SENSORS_H_
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<html class="phy6222Class"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>PHY62x2 BTHome v1.5</title>
|
||||
<title>PHY62x2 BTHome v1.6</title>
|
||||
<!--<link rel="stylesheet" type="text/css" href="styles.css" />
|
||||
<link rel="stylesheet" type="text/css" href="chart.css" />
|
||||
<script type="text/javascript" src="dygraph.min.js" /></script> /-->
|
||||
|
|
@ -591,6 +591,8 @@ div#divChart {
|
|||
INVALID_BINDKEY_LENGTH: { en: 'Bindkey must be 16 bytes, hex encoded (=32 characters)', ru: 'BindKey должен соднержать 16 байт в HEX виде (32 символа)' },
|
||||
UPLOAD_FIRMWARE: { en: 'Download firmware file', ru: 'Загрузка firmware файла' },
|
||||
WARNING_BOOT_FW: { en: 'Attention!: Uploading boot FW is not safe. In order to avoid firmware failure use a fresh battery!', ru: 'Внимание!: Обновление Boot fw не безопасно. Во избежание сбоя прошивки желательно использование полной батареи!' },
|
||||
MEMO_OFF: {en: 'Disabled', ru: 'Отключено'},
|
||||
SHOW_TEMPF: {en: 'Show Temperature in Fahrenheit', ru: 'Показывать температуру в градусах Фаренгейта'},
|
||||
};
|
||||
|
||||
function getUserLang() {
|
||||
|
|
@ -1425,6 +1427,8 @@ function showConfig() {
|
|||
$('chkCfgTrg').checked = (devCfg.flg & 8) != 0;
|
||||
$('chkCfgLcdOff').checked = (devCfg.flg & 16) != 0;
|
||||
$('chkCfgBindKey').checked = (devCfg.flg & 32) != 0;
|
||||
$('chkCfgFahrenheit').checked = (devCfg.flg & 64) != 0;
|
||||
|
||||
let txPwr = 31;
|
||||
el = $('selTxPwr');
|
||||
for(let n = 0; n < el.options.length; n++) if(el.options[n].value >= devCfg.tx_power) txPwr = el.options[n].value;
|
||||
|
|
@ -1437,7 +1441,7 @@ function showConfig() {
|
|||
$('lblMeasInt').innerHTML = "= " + msri.toFixed(1) + ` ${i18n.getTag('MS')}`;
|
||||
$('inpAverInt').value = devCfg.averaging_measurements; // запись истории: при 0 - отключена, 1...255 * шаг опроса датчика = интерал записи истории
|
||||
if(devCfg.averaging_measurements == 0)
|
||||
$('lblAverInt').innerHTML = "отключена";
|
||||
$('lblAverInt').innerHTML = ` ${i18n.getTag('MEMO_OFF')}`;
|
||||
else {
|
||||
let hsti = (msri*devCfg.averaging_measurements)/1000.0;
|
||||
if(hsti > 60) {
|
||||
|
|
@ -1797,6 +1801,7 @@ function chkDevCfg() {
|
|||
devCfg.flg |= ($('chkCfgTrg').checked) ? 8 : 0;
|
||||
devCfg.flg |= ($('chkCfgLcdOff').checked) ? 16 : 0;
|
||||
devCfg.flg |= ($('chkCfgBindKey').checked) ? 32 : 0;
|
||||
devCfg.flg |= ($('chkCfgFahrenheit').checked) ? 64 : 0;
|
||||
devCfg.tx_power = $('selTxPwr').value & 0x3f; // 0..0x1f -> -20..+5 dBm ? нелинейное 0x1f = +0 дБм
|
||||
let connect_latency = parseInt($('inpLat').value); // = (connect_latency + 1)*30 ms
|
||||
if (connect_latency < 0) {
|
||||
|
|
@ -2365,6 +2370,7 @@ window.onload = function() {
|
|||
<td><label><input type="checkbox" id="chkCfgSmiley"/><span data-i18ntag="SHOW_SMILEY">Отображать смайлик</span></label></td>
|
||||
<td><label><input type="checkbox" id="chkCfgTrg"/><span data-i18ntag="SHOW_TRIGGER">Отображать триггер</span></label></td>
|
||||
<td><label><input type="checkbox" id="chkCfgLcdOff"/><span data-i18ntag="DISCONNECT_DISPLAY">Отключить дисплей</span></label></td>
|
||||
<td><label><input type="checkbox" id="chkCfgFahrenheit"/><span data-i18ntag="SHOW_TEMPF">Показывать температуру в градусах Фаренгейта</span></label></td>
|
||||
</tr>
|
||||
</table>
|
||||
<table>
|
||||
|
|
|
|||
25
fw.json
25
fw.json
|
|
@ -7,13 +7,22 @@
|
|||
"bin/TH05D_v17.bin",
|
||||
"bin/TH05F_v17.bin",
|
||||
"bin/THB3_v17.bin"],
|
||||
"updateboot":[
|
||||
"update_boot/BOOT_THB2_v17.bin",
|
||||
"update_boot/BOOT_BTH01_v17.bin",
|
||||
"update_boot/BOOT_TH05_v17.bin",
|
||||
"betafw":[
|
||||
"bin/THB2_v18.bin",
|
||||
"bin/BTH01_v18.bin",
|
||||
"bin/TH05_v18.bin",
|
||||
"?",
|
||||
"update_boot/BOOT_THB1_v17.bin",
|
||||
"update_boot/BOOT_TH05D_v17.bin",
|
||||
"update_boot/BOOT_TH05F_v17.bin",
|
||||
"update_boot/BOOT_THB3_v17.bin"]
|
||||
"bin/THB1_v18.bin",
|
||||
"bin/TH05D_v18.bin",
|
||||
"bin/TH05F_v18.bin",
|
||||
"bin/THB3_v18.bin"],
|
||||
"updateboot":[
|
||||
"update_boot/BOOT_THB2_v18.bin",
|
||||
"update_boot/BOOT_BTH01_v18.bin",
|
||||
"update_boot/BOOT_TH05_v18.bin",
|
||||
"?",
|
||||
"update_boot/BOOT_THB1_v18.bin",
|
||||
"update_boot/BOOT_TH05D_v18.bin",
|
||||
"update_boot/BOOT_TH05F_v18.bin",
|
||||
"update_boot/BOOT_THB3_v18.bin"]
|
||||
}
|
||||
|
|
|
|||
BIN
update_boot/BOOT_BTH01_v18.bin
Normal file
BIN
update_boot/BOOT_BTH01_v18.bin
Normal file
Binary file not shown.
BIN
update_boot/BOOT_TH05D_v18.bin
Normal file
BIN
update_boot/BOOT_TH05D_v18.bin
Normal file
Binary file not shown.
BIN
update_boot/BOOT_TH05F_v18.bin
Normal file
BIN
update_boot/BOOT_TH05F_v18.bin
Normal file
Binary file not shown.
BIN
update_boot/BOOT_TH05_v18.bin
Normal file
BIN
update_boot/BOOT_TH05_v18.bin
Normal file
Binary file not shown.
BIN
update_boot/BOOT_THB1_v18.bin
Normal file
BIN
update_boot/BOOT_THB1_v18.bin
Normal file
Binary file not shown.
BIN
update_boot/BOOT_THB2_v18.bin
Normal file
BIN
update_boot/BOOT_THB2_v18.bin
Normal file
Binary file not shown.
BIN
update_boot/BOOT_THB3_v18.bin
Normal file
BIN
update_boot/BOOT_THB3_v18.bin
Normal file
Binary file not shown.
|
|
@ -1,2 +1,2 @@
|
|||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_BTH01_v17.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/BTH01_v17.bin
|
||||
python3 rdwr_phy62x2.py -p COM12 -e -r wh ./bin/BOOT_BTH01_v18.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM12 -r we 0x10000 ./bin/BTH01_v18.bin
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_TH05_v17.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/TH05_v17.bin
|
||||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_TH05_v18.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/TH05_v18.bin
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_TH05D_v17.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/TH05D_v17.bin
|
||||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_TH05D_v18.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/TH05D_v18.bin
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_TH05F_v17.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/TH05F_v17.bin
|
||||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_TH05F_v18.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/TH05F_v18.bin
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_THB1_v17.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/THB1_v17.bin
|
||||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_THB1_v18.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/THB1_v18.bin
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_THB2_v17.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/THB2_v17.bin
|
||||
python3 rdwr_phy62x2.py -p COM12 -e -r wh ./bin/BOOT_THB2_v18.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM12 -r we 0x10000 ./bin/THB2_v18.bin
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_THB3_v17.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/THB3_v17.bin
|
||||
python3 rdwr_phy62x2.py -p COM11 -e -r wh ./bin/BOOT_THB3_v18.hex
|
||||
@rem python3 rdwr_phy62x2.py -p COM11 -r we 0x10000 ./bin/THB3_v18.bin
|
||||
Loading…
Add table
Add a link
Reference in a new issue