Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bootup logo settings #1241

Merged
merged 178 commits into from
Apr 2, 2022
Merged

Bootup logo settings #1241

merged 178 commits into from
Apr 2, 2022

Conversation

discip
Copy link
Collaborator

@discip discip commented Feb 23, 2022

@Ralim
Tried my best to implement bootup logo settings by digging through other PRs.
But since I am not absolutely sure what is missing / went wrong, I need help / advice on what to do to get this going.

resolves #292
closes #1253

Thanks in advance.

@discip
Copy link
Collaborator Author

discip commented Mar 17, 2022

@Ralim
If you have time at hand, it would be nice if you could help me solving the final issue regarding space.
It seems that I have reached the limit of maximum firmware size for the TS80P. 🤷‍♂️🤔
Is the TS80P the one with the least space?
For all the other devices the firmware was compiled without any difficulties.

I'm using a fork without the screen invert option and that one works even for the TS80P.

@Ralim
Copy link
Owner

Ralim commented Mar 18, 2022

TS80P is indeed the lowest on space, the Miniware irons have less room than Pinecil; and TS80P has QC + PD which chews up space. Its been creeping closer over time.

It may be worth running it locally if you can to see which language failed for a quick-win (by figuring out if we can reduce the different characters used in that language).

Otherwise its a bit of code optimisation golf to find a good location to trim the size of the code. Which I can do when I get time 😓

@discip
Copy link
Collaborator Author

discip commented Mar 18, 2022

It may be worth running it locally if you can to see which language failed for a quick-win (by figuring out if we can reduce the different characters used in that language).

I am not able to compile the firmware on my machine if you meant that. I always use the CI compiled ones from github.

Otherwise its a bit of code optimisation golf to find a good location to trim the size of the code. Which I can do when I get time 😓

That would be nice!

Should I put this PR in draft mode until then?

@ghost
Copy link

ghost commented Mar 18, 2022

I using a fork without the screen invert option and that one works even for the TS80P.

Would replacing brightness control and invert colours icons with text help us?

@discip discip marked this pull request as draft March 19, 2022 23:33
@Ralim
Copy link
Owner

Ralim commented Mar 20, 2022

It depends dramatically on the language really, if the text brings in less new glyphs than the images take up; then i would help.
The issue is ZH-CN where we are 0x44 bytes over our space.
I've dropped some Timer code that I believe we will never follow the path of to trim the size down by ~0x50 bytes

@Ralim Ralim marked this pull request as ready for review March 20, 2022 11:12
@Ralim
Copy link
Owner

Ralim commented Mar 20, 2022

Can you just give the TS80 or TS80P or TS100 a test to make sure all works?

@discip
Copy link
Collaborator Author

discip commented Mar 20, 2022

@Ralim

Can you just give the TS80 or TS80P or TS100 a test to make sure all works?

What exactly should I look for? Or what could the changes have tampered with?

As for the heat up, the motion sensitivity, the menu navigation and the boot logo functionality this works. At least for the TS80P out of the ones you requested to test.

@Ralim
Copy link
Owner

Ralim commented Mar 20, 2022

Tamper was with timer, so heater control. Try a heat up - hold temp - cool down cycle would be my best bet

@ghost
Copy link

ghost commented Mar 21, 2022

It depends dramatically on the language really, if the text brings in less new glyphs than the images take up; then i would help.
The issue is ZH-CN where we are 0x44 bytes over our space.
I've dropped some Timer code that I believe we will never follow the path of to trim the size down by ~0x50 bytes

@alvinhochun it also worths notifying this to you.

I really don't know if this may be practical but here I have a list of characters divided by number of occurrence:
言=1, 退=1, 适=1, 后=1, 尔=1,下=1, 同=1, 而=1, 个=1, 两=1, 是=1, 串=1, 否=1, 到=1, 应=1, 些=1, 颜=1, 求=1, B=1, 6=1, 摄=1, F=1, 降=1, 偏=1, X=1, d=1, g=1, 器=1, l=1, n=1, 色=1, v=1, w=1, 白=1, 交=1, 被=1, 磁=1, 仍=1, 黑=1, 目=1, 更=1, 省=1, 锂=1, 有=1, 霍=1, 伏=1, :=1, 会=1, 感=1, 传=1, 大=1, 失=1, 场=1, 允=1, 效=1, 先=1, 位=1, 华=1, 协=1, 你=1, 止=1, 此=1, 兼=1, 简=1, 要=1, 涉=1, 完=1, 计=1, 控=1, 议=1, 过=1, 某=1, 提=1, 进=1, 只=1, 可=1, 路=1, 说=1, 出=1, 移=1,

Other unsorted occurrences:
不=2, 小=2, 氏=2, 向=2, 候=2, 通=2, 速=8, 态=4, 调=7, 将=2, 分=2, 标=3, 模=9, 校=8, !=2, 温=20, 中=7, -=11, .=15, /=4, 启=4, 0=7, 1=4, 2=3, 3=6, 4=2, 5=3, 制=3, 7=2, 户=2, 9=2, 为=6, :=4, 主=2, <=16, 值=2, ==28, >=17, 显=6, 所=2, C=5, D=6, E=2, 幅=2, I=2, 之=2, 手=2, L=2, M=2, 前=3, N=2, 屏=4, O=2, 限=5, P=4, Q=3, S=5, 幕=4, U=2, V=9, W=2, Z=2, 停=2, 池=2, a=2, e=3, m=2, 确=2, o=2, r=2, s=3, t=3, 灵=7, x=3, 特=3, z=6, |=19, 节=2, 的=18, 于=5, 源=10, 隔=2, 增=5, 功=6, 钟=2, 加=5, 度=31, 级=2, 动=20, 播=2, 亮=2, 亳=2, 状=4, 检=2,铁=5, 情=3, 高=7, 默=2, 烙=5, 滚=2, 以=3, 瓦=2, 部=2, 热=5,英=2,能=2, 图=2, 最=8, 开=4, 持=3, 锁=6, !=3, 处=5, (=7, )=7, 脉=4, 按=12,焊=8, ,=5, 式=9, ;=2,?=3, 次=2, 唤=3, 用=14, 未=2, 键=8, 头=4, 电=25, 示=5, 机=13, 画=9, 放=2, 等=2, 测=2, 界=2,低=6, 敏=7, 体=3, 单=3, 字=3, 作=2, 慢=3, 换=2, 面=6, 正=6, 入=3, 全=5, 转=2, 置=18, 关=6, 整=3,长=6, 使=2, 禁=5, 待=11, 超=3, 文=2, 率=4, 压=9,醒=4, 输=2, 定=11, 认=2, 室=4, 接=6, 循=2, 环=2, 冲=4, 许=2, 容=2, 方=2, 设=16, 始=3, 反=2, 重=5, 每=4, 减=2,秒=4, 变=2, 菜=2, 保=3, 无=4, 解=2, 详=4, 左=3, 闪=2, 自=10, 快=3, 语=3, 短=2, 闲=2, 已=4, 右=3, 间=7, 时=19, 请=3,

Unluckily I've just a vague idea of how Chinese alphabet works since I don't speak Chinese, thus I don't know either if any of these characters can be replaced. Maybe can be replaced with : and X with x or vice versa. In any case I hope it helps.

As for the heat up, the motion sensitivity, the menu navigation and the boot logo functionality this works. At least for the TS80P out of the ones you requested to test.

@discip can you please give also shutdown time and standby time a try?

@alvinhochun
Copy link
Contributor

If you can exclude the menu strings for hall effect sensitivity on non-Pinecil builds that will also help a bit.

@Ralim
Copy link
Owner

Ralim commented Mar 21, 2022

Do you know if there is a way to "poke" the compiler to do this for us?
Or should we restructure how the strings are stored?

@alvinhochun
Copy link
Contributor

I think hacking make_translation.py to use an empty string when reading it from the JSON would save enough bytes.

@discip
Copy link
Collaborator Author

discip commented Mar 21, 2022

@Ralim

Tamper was with timer, so heater control. Try a heat up - hold temp - cool down cycle would be my best bet

I ran several tests comparing the behavior in regard to heat-up-speed and temp.-stability and could not make out any difference between the version with the altered stm32f1xx_hal_tim.c and the original one.

@discip
Copy link
Collaborator Author

discip commented Mar 24, 2022

@federicodilo

@discip can you please give also shutdown time and standby time a try?

Works as intended! 👍
I did not pay attention to the context the first time. 😅

@Ralim Ralim merged commit 0b8192b into Ralim:master Apr 2, 2022
@discip discip deleted the bootup-logo-settings branch April 2, 2022 01:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Translation files are not consistent Boot Logo Options
3 participants