mirror of
https://github.com/Ralim/IronOS.git
synced 2025-07-23 12:23:06 +02:00
Merge branch 'dev' into dev
This commit is contained in:
@@ -38,7 +38,7 @@ The model should be replaced by one of the following options:
|
||||
- `miniware` for older Miniware Irons -> TS100, TS80, TS80P
|
||||
- `pinecilv1` for the Pinecil V1
|
||||
- `pinecilv2` for the Pinecil V2
|
||||
- `ts101` for the Miniware TS101 [^1]
|
||||
- `ts101` for the Miniware TS101 [^1] [^2]
|
||||
- `s60` for the Squire S60 [^1]
|
||||
- `mhp30` for the Miniware MHP30
|
||||
|
||||
@@ -50,6 +50,28 @@ After processing its expected to have a `.hex` and `.dfu` file created to be use
|
||||
Note: make sure your image file is in the same folder as script files (img2logo.py, output_dfu.py, output_hex.py).
|
||||
|
||||
[^1] Note that these devices have larger resolution screens that the logo system supports right now. Fixes are coming for this soon, roughly scheduled for 2.23.
|
||||
[^2] The TS101 requires extra steps, see below.
|
||||
|
||||
### TS101 Quirks
|
||||
|
||||
When Miniware designed the TS101 they cut cost by using an STM32 clone with some odd quirks. They also re-wrote their USB bootloader, which has introduced new bugs for us to deal with.
|
||||
Their bootloader appears to have kept the existing limit of not being able to flash small hex files, but they no longer fall for the older "just repeat the content" trick and instead reject the file.
|
||||
Additionally, while the MCU in use has 128K of flash, their bootloader (at least for me) fails to write to anything above 99K. It _looks_ like a watchdog reset or hard crash. Unsure.
|
||||
|
||||
This has flow on effects, where the settings can still be located in the upper ~28K of flash, but it cant be used for anything we flash over USB.
|
||||
Of that 100K we can use, they waste 32K of it for their bootloader (Old bootloaders were 16K).
|
||||
This means the main "app" of IronOS is limited to around 67K (100K-32K for bootloader, -1K for logo).
|
||||
|
||||
For this device the Logo is not located at the end of flash but instead at the last writable page (99K).
|
||||
|
||||
Additionally, as we need to do a large write, to avoid having to waste more flash space; the logo is merged with the normal firmware. This means that the firmware and logo are flashed together once.
|
||||
Future updates can be done without merging as it will leave the logo data there as normal firmware doesnt touch that area of flash.
|
||||
|
||||
To do this, download the latest version of IronOS and merge it with the logo using the `--merge` command line argument.
|
||||
|
||||
To create the logo file for a TS101 the full command looks like `python3 img2logo.py <image file path> <output folder path> -m ts101 --merge <Path to main firmware>`.
|
||||
|
||||
For this reason, there are no TS101 logo's generated by the IronOS-Meta repo.
|
||||
|
||||
## Flashing the Logo
|
||||
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Эфект Хола\nадчувальнасць",
|
||||
"description": "Узровень адчувальнасці датчыка хола ў рэжыме сну (1=Мін. | ... | 9=Макс.)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Адзінкі\nтэмпературы",
|
||||
"description": "Адзінкі вымярэння тэмпературы (C=Цэльcія | F=Фарэнгейта)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Датчик\nна Хол",
|
||||
"description": "Чувствителност на сензора към магнитно поле (1=Слабо | ... | 9=Силно)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Единици за\nтемпературата",
|
||||
"description": "Единици за температурата (C=Целзии | F=Фаренхайт)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Citlivost\nHall. čidla",
|
||||
"description": "Citlivost Hallova čidla pro detekci spánku (1=nejméně citlivé | ... | 9=nejvíce citlivé)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Jednotka\nteploty",
|
||||
"description": "C=Celsius | F=Fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall sensor\nfølsomhed",
|
||||
"description": "følsomhed overfor magneten (1=Mindst følsom | ... | 9=Mest følsom)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperatur\nEnhed",
|
||||
"description": "Temperatur Enhed (C=Celsius | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Empfindlichkeit\nder Hall-Sonde",
|
||||
"description": "Empfindlichkeit der Hall-Sonde um den Ruhemodus auszulösen (1=minimal | ... | 9=maximal)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperatur-\neinheit",
|
||||
"description": "C=°Celsius | F=°Fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Ευαισθ. αισθ. \nφαιν. Hall",
|
||||
"description": "Ευαισθησία του αισθητήρα φαινομένου Hall για εντοπισμό αδράνειας (1=λιγότερο ευαίσθητο | ... | 9=περισσότερο ευαίσθητο)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Μονάδες\nθερμοκρασίας",
|
||||
"description": "C=Κελσίου | F=Φαρενάιτ"
|
||||
|
@@ -233,6 +233,10 @@
|
||||
"displayText": "Hall sensor\nsensitivity",
|
||||
"description": "Sensitivity to magnets (1=least sensitive | ... | 9=most sensitive)"
|
||||
},
|
||||
"HallEffSleepTimeout": {
|
||||
"displayText": "HallSensor\nSleepTime",
|
||||
"description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperature\nunit",
|
||||
"description": "C=°Celsius | F=°Fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall Eff\nSensibilidad",
|
||||
"description": "Sensibilidad del sensor de efecto Hall en la detección de reposo (1=menos sensible | ... | 9=más sensible)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Unidad de\ntemperatura",
|
||||
"description": "Unidad de temperatura (C=entígrados | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Halli anduri\ntundlikkus",
|
||||
"description": "Tundlikkus magnetite suhtes (1=vähetundlikum | ... | 9=kõige tundlikum)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperatuuri\nühik",
|
||||
"description": "C=°Celsius | F=°Fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall-\nherk.",
|
||||
"description": "Hall-efektianturin herkkyys lepotilan tunnistuksessa (1=vähäinen herkkyys | ... | 9=suurin herkkyys)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Lämpötilan\nyksikkö",
|
||||
"description": "C=celsius, F=fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Sensibilité\ncapteur effet hall",
|
||||
"description": "Sensibilité du capteur à effet Hall pour la mise en veille (1=peu sensible | ... | 9=très sensible)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Unité de\ntempérature",
|
||||
"description": "C=Celsius | F=Fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Osjetljivost\nHall senzora",
|
||||
"description": "Osjetljivost senzora magnetskog polja za detekciju spavanja (N=Najmanja | S=Srednja | V=Visoka)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Jedinica\ntemperature",
|
||||
"description": "Jedinica temperature (C=Celzij | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Alvásérzékelő\nérzékenység",
|
||||
"description": "Alvásérzékelő gyorsulásmérő érzékenysége (1=legkevésbé érzékeny | ... | 9=legérzékenyebb)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Hőmérséklet\nmértékegysége",
|
||||
"description": "Hőmérséklet mértékegysége (C=Celsius | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Sensore\nHall",
|
||||
"description": "Regola la sensibilità del sensore ad effetto Hall per entrare in modalità riposo [1: minima; 9: massima]"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Unità di\ntemperatura",
|
||||
"description": "Scegli l'unità di misura per la temperatura [C: grado Celsius; F: grado Farenheit]"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "磁界感度",
|
||||
"description": "スタンバイモードに入るのに使用される磁場センサーの感度 <1=最低感度 | ... | 9=最高感度>"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "温度単位",
|
||||
"description": "C=摂氏 | F=華氏"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Holo\njutiklis",
|
||||
"description": "Holo jutiklio jautrumas nustatant miegą (1=Mažiausias | ... | 9=Didžiausias)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperatūros\nvienetai",
|
||||
"description": "Temperatūros vienetai (C=Celsijus | F=Farenheitas)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall-sensor\nfølsomhet",
|
||||
"description": "Sensitiviteten til Hall-effekt-sensoren for å detektere inaktivitet (1=Minst følsom | ... | 9=Mest følsom)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "TmpEnh\n",
|
||||
"description": "Temperaturskala (C=Celsius | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall sensor\ngevoeligheid",
|
||||
"description": "Gevoeligheid naar de magneten (1=minst gevoelig | ... | 9=meest gevoelig)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperatuur\neenheid",
|
||||
"description": "C=°Celsius | F=°Fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall sensor\ngevoeligheid",
|
||||
"description": "Gevoeligheid naar de magneten (1=minst gevoelig | ... | 9=meest gevoelig)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperatuur\nschaal",
|
||||
"description": "Temperatuurschaal (°C=Celsius | °F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Czułość\ncz. Halla",
|
||||
"description": "Czułość czujnika Halla, używanego do przechodznia w tryb uśpienia (1: Minimalna | ... | 9: Maksymalna)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Jednostka\ntemperatury",
|
||||
"description": "Jednostka temperatury (C: Celciusz | F: Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Sensibilidade de\nmagnetismo",
|
||||
"description": "Sensibilidade de magnetismo (1=Menor | ... | 9=Maior)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Unidade\ntemperatura",
|
||||
"description": "Unidade de temperatura (C=Celsius | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Sensibilitate\nsenzor Hall",
|
||||
"description": "Sensibilitate senzor cu efect Hall pentru a detecta repausul (1=putin sensibil | ... | 9=cel mai sensibil)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Unitate de\ntemperatură",
|
||||
"description": "C=Celsius | F=Fahrenheit"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Датчик\nХолла",
|
||||
"description": "Чувствительность датчика Холла к магнитному полю (1=мин. | ... | 9=макс.)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Единицы\nизмерения",
|
||||
"description": "Единицы измерения температуры (C=°Цельcия | F=°Фаренгейта)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Citliv.\nHall",
|
||||
"description": "Citlivosť Hallovho senzora pre detekciu spánku (1=Min | ... | 9=Max)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Jednotka\nteploty",
|
||||
"description": "Jednotky merania teploty (C=stupne Celzia | F=stupne Fahrenheita)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Občut.\nHall son",
|
||||
"description": "Občutljivost Hallove sonde za zaznavanje spanja (1=najmanjša | ... | 9=največja)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Enota za\ntemperaturo",
|
||||
"description": "Enota za temperaturo (C=celzij | F=fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall sensor\nsensitivity",
|
||||
"description": "Sensitivity to magnets (1=најмање осетљиво | ... | 9=најосетљивије)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Јединица\nтемпературе",
|
||||
"description": "Јединице у којима се приказује температура. (C=целзијус | F=фаренхајт)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall sensor\nsensitivity",
|
||||
"description": "Sensitivity to magnets (1=najmanje osetljivo | ... | 9=najosetljivije)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Jedinica\ntemperature",
|
||||
"description": "Jedinice u kojima se prikazuje temperatura. (C=celzijus | F=farenhajt)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Sensor-\nkänslght",
|
||||
"description": "Känslighet för halleffekt-sensorn för viloläges-detektering (1=minst känslig | ... | 9=mest känslig)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Temperatur-\nenheter",
|
||||
"description": "Temperaturenhet (C=Celsius | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall Sensör\nHassasiyeti",
|
||||
"description": "Mıknatıslara duyarlılık (1=En az duyarlı | ... | 9=En duyarlı)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "SCKBRM\n",
|
||||
"description": "Sıcaklık Birimi (C=Celsius | F=Fahrenheit)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Чутливість\nЕфекту Холла",
|
||||
"description": "Чутливість датчика ефекту Холла при виявленні сну (1=мін. чутливості | ... | 9=макс. чутливості)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Формат темпе-\nратури(C°/F°)",
|
||||
"description": "Одиниця виміру температури (C=Цельсій | F=Фаренгейт)"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "Hall\nđo nhay",
|
||||
"description": "Đo nhay cam bien Hall đe phát hien che đo ngu (1=ít nhay nhat |...| 9=nhay nhat)"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "Đon vi\nnhiet đo",
|
||||
"description": "C= Đo C | F= Đo F"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "磁場敏感度",
|
||||
"description": "磁場感應器用嚟啓動待機模式嘅敏感度 <1=最低敏感度 | ... | 9=最高敏感度>"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "温度單位",
|
||||
"description": "C=攝氏 | F=華氏"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "磁场灵敏度",
|
||||
"description": "霍尔效应传感器用作启动待机模式的灵敏度 <1=最低灵敏度 | ... | 9=最高灵敏度>"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "温度单位",
|
||||
"description": "C=摄氏 | F=华氏"
|
||||
|
@@ -233,6 +233,8 @@
|
||||
"displayText": "磁場敏感度",
|
||||
"description": "磁場感應器用作啟動待機模式的敏感度 <1=最低敏感度 | ... | 9=最高敏感度>"
|
||||
},
|
||||
"HallEffSleepTimeout": { "displayText": "HallSensor\nSleepTime", "description": "Interval before \"sleep mode\" starts when hall effect is above threshold"
|
||||
},
|
||||
"TemperatureUnit": {
|
||||
"displayText": "溫標",
|
||||
"description": "C=攝氏 | F=華氏"
|
||||
|
@@ -411,6 +411,13 @@
|
||||
"include": ["HALL_SENSOR"],
|
||||
"description": "If the unit has a hall effect sensor (Pinecil), this adjusts how sensitive it is at detecting a magnet to put the device into sleep mode."
|
||||
},
|
||||
{
|
||||
"id": "HallEffSleepTimeout",
|
||||
"maxLen": 10,
|
||||
"maxLen2": 10,
|
||||
"include": ["HALL_SENSOR"],
|
||||
"description": "If the unit has a hall effect sensor (Pinecil), this adjusts how long the device takes before it drops down to the sleep temperature when hall sensor is over threshold."
|
||||
},
|
||||
{
|
||||
"id": "TemperatureUnit",
|
||||
"maxLen": 6,
|
||||
|
@@ -194,7 +194,7 @@
|
||||
#define POWER_LIMIT_STEPS 5
|
||||
#define OP_AMP_GAIN_STAGE OP_AMP_GAIN_STAGE_TS100
|
||||
#define TEMP_uV_LOOKUP_HAKKO
|
||||
#define ACCEL_LIS_CLONE 1
|
||||
#define ACCEL_LIS_CLONE 1
|
||||
#define HARDWARE_MAX_WATTAGE_X10 1000
|
||||
#define TIP_THERMAL_MASS 65 // X10 watts to raise 1 deg C in 1 second
|
||||
#define TIP_RESISTANCE 75 // x10 ohms, 7.5 typical for ts100 tips
|
||||
@@ -272,7 +272,12 @@
|
||||
#endif /* TS80P */
|
||||
|
||||
#ifdef MODEL_TS101
|
||||
#define FLASH_LOGOADDR (0x08000000 + (126 * 1024))
|
||||
// For whatever reason, Miniware decided to not build a reliable DFU bootloader
|
||||
// It can't appear to flash to some of the upper pages of flash,
|
||||
// I'm slightly suspect a watchdog or something runs out
|
||||
// as device resets before file finishes copying
|
||||
// So logo has to be located on page 99 or else it cant be flashed on stock bootloader
|
||||
#define FLASH_LOGOADDR (0x08000000 + (99 * 1024))
|
||||
#define SETTINGS_START_PAGE (0x08000000 + (127 * 1024))
|
||||
#else
|
||||
#define FLASH_LOGOADDR (0x08000000 + (62 * 1024))
|
||||
|
@@ -73,8 +73,9 @@ enum SettingsOptions {
|
||||
ProfilePhase5Temp = 50, // Temperature to target for the end of phase 5
|
||||
ProfilePhase5Duration = 51, // Target duration for phase 5
|
||||
ProfileCooldownSpeed = 52, // Maximum allowed cooldown speed in degrees per second
|
||||
HallEffectSleepTime = 53, // Seconds (/5) timeout to sleep when hall effect over threshold
|
||||
//
|
||||
SettingsOptionsLength = 53, //
|
||||
SettingsOptionsLength = 54, //
|
||||
};
|
||||
|
||||
typedef enum {
|
||||
|
@@ -84,6 +84,7 @@ enum class SettingsItemIndex : uint8_t {
|
||||
SleepTimeout,
|
||||
ShutdownTimeout,
|
||||
HallEffSensitivity,
|
||||
HallEffSleepTimeout,
|
||||
TemperatureUnit,
|
||||
DisplayRotation,
|
||||
CooldownBlink,
|
||||
|
@@ -104,6 +104,7 @@ static const SettingConstants settingsConstants[(int)SettingsOptions::SettingsOp
|
||||
{ MIN_TEMP_C, MAX_TEMP_F, 5, 90}, // ProfilePhase5Temp
|
||||
{ 10, 180, 5, 30}, // ProfilePhase5Duration
|
||||
{ 1, 10, 1, 2}, // ProfileCooldownSpeed
|
||||
{ 0, 12, 1, 0}, // HallEffectSleepTime
|
||||
};
|
||||
static_assert((sizeof(settingsConstants) / sizeof(SettingConstants)) == ((int)SettingsOptions::SettingsOptionsLength));
|
||||
|
||||
|
@@ -111,6 +111,7 @@ static void displayLogoTime(void);
|
||||
|
||||
#ifdef HALL_SENSOR
|
||||
static void displayHallEffect(void);
|
||||
static void displayHallEffectSleepTime(void);
|
||||
static bool showHallEffect(void);
|
||||
#endif /* HALL_SENSOR */
|
||||
|
||||
@@ -162,6 +163,7 @@ static void displayAdvancedMenu(void);
|
||||
* -Sleep Time
|
||||
* -Shutdown Time
|
||||
* Hall Sensor Sensitivity
|
||||
* Hall Sensor Sleep Time
|
||||
*
|
||||
* UI
|
||||
* Temperature Unit
|
||||
@@ -346,6 +348,8 @@ const menuitem PowerSavingMenu[] = {
|
||||
#ifdef HALL_SENSOR
|
||||
/* Hall Effect Sensitivity */
|
||||
{SETTINGS_DESC(SettingsItemIndex::HallEffSensitivity), nullptr, displayHallEffect, showHallEffect, SettingsOptions::HallEffectSensitivity, SettingsItemIndex::HallEffSensitivity, 7},
|
||||
/* Hall Effect Sleep Time */
|
||||
{SETTINGS_DESC(SettingsItemIndex::HallEffSleepTimeout), nullptr, displayHallEffectSleepTime, showHallEffect, SettingsOptions::HallEffectSleepTime, SettingsItemIndex::HallEffSleepTimeout, 5},
|
||||
#endif /* HALL_SENSOR */
|
||||
/* vvvv end of menu marker. DO NOT REMOVE vvvv */
|
||||
{0, nullptr, nullptr, nullptr, SettingsOptions::SettingsOptionsLength, SettingsItemIndex::NUM_ITEMS, 0}
|
||||
@@ -740,6 +744,16 @@ static void displayHallEffect(void) {
|
||||
}
|
||||
}
|
||||
static bool showHallEffect(void) { return getHallSensorFitted(); }
|
||||
static void displayHallEffectSleepTime(void) {
|
||||
if (getSettingValue(SettingsOptions::HallEffectSleepTime)) {
|
||||
OLED::printNumber(getSettingValue(SettingsOptions::HallEffectSleepTime) * 5, 2, FontStyle::LARGE, false);
|
||||
OLED::print(LargeSymbolSeconds, FontStyle::LARGE);
|
||||
} else {
|
||||
// When sleep time is set to zero, we sleep for 1 second anyways. This is the default.
|
||||
OLED::printNumber(1, 2, FontStyle::LARGE, false);
|
||||
OLED::print(LargeSymbolSeconds, FontStyle::LARGE);
|
||||
}
|
||||
}
|
||||
#endif /* HALL_SENSOR */
|
||||
|
||||
static void setTempF(const enum SettingsOptions option) {
|
||||
|
@@ -11,4 +11,14 @@
|
||||
/* Functions */
|
||||
void initialise_monitor_handles() {}
|
||||
|
||||
/* Syscalls (stub implementations to avoid compile warnings and possibe future problems) */
|
||||
int _getpid(void) { return 1; }
|
||||
|
||||
#if defined(MODEL_Pinecil) || defined(MODEL_Pinecilv2)
|
||||
// do nothing here because some stubs and real implementations added for Pinecils already
|
||||
#else
|
||||
off_t _lseek(int fd, off_t ptr, int dir) { return -1; }
|
||||
ssize_t _read(int fd, void *ptr, size_t len) { return -1; }
|
||||
ssize_t _write(int fd, const void *ptr, size_t len) { return -1; }
|
||||
int _close(int fd) { return -1; }
|
||||
#endif
|
||||
|
@@ -7,6 +7,7 @@
|
||||
void GUIDelay(); //
|
||||
bool checkForUnderVoltage(void); //
|
||||
uint32_t getSleepTimeout(void); //
|
||||
uint32_t getHallEffectSleepTimeout(void); //
|
||||
bool shouldBeSleeping(); //
|
||||
bool shouldShutdown(void); //
|
||||
void printVoltage(void); //
|
||||
|
@@ -0,0 +1,13 @@
|
||||
#include "OperatingModeUtilities.h"
|
||||
|
||||
#ifndef NO_SLEEP_MODE
|
||||
#ifdef HALL_SENSOR
|
||||
uint32_t getHallEffectSleepTimeout(void) {
|
||||
if (getSettingValue(SettingsOptions::HallEffectSensitivity) && getSettingValue(SettingsOptions::HallEffectSleepTime)) {
|
||||
uint32_t sleepThres = getSettingValue(SettingsOptions::HallEffectSleepTime) * 5 * TICKS_SECOND;
|
||||
return sleepThres;
|
||||
}
|
||||
return TICKS_SECOND;
|
||||
}
|
||||
#endif
|
||||
#endif
|
@@ -32,7 +32,7 @@ bool shouldBeSleeping() {
|
||||
if (lastHallEffectSleepStart == 0) {
|
||||
lastHallEffectSleepStart = xTaskGetTickCount();
|
||||
}
|
||||
if ((xTaskGetTickCount() - lastHallEffectSleepStart) > TICKS_SECOND) {
|
||||
if ((xTaskGetTickCount() - lastHallEffectSleepStart) > getHallEffectSleepTimeout()) {
|
||||
return true;
|
||||
}
|
||||
} else {
|
||||
|
@@ -84,7 +84,8 @@ DEVICE_BSP_DIR=./Core/BSP/Miniware
|
||||
LDSCRIPT=./Core/BSP/Miniware/stm32f103.ld
|
||||
|
||||
ifeq ($(model),$(filter $(model),TS101))
|
||||
flash_size=126k
|
||||
# 128K, but logo must be at 99K so their broken ass DFU can flash it
|
||||
flash_size=98k
|
||||
bootldr_size=0x8000
|
||||
DEVICE_DFU_ADDRESS=0x08008000
|
||||
else
|
||||
|
Reference in New Issue
Block a user