Implement for Waveshare 6 inch HD screen#48
Implement for Waveshare 6 inch HD screen#48FutureTravelATM wants to merge 1 commit into21isenough:masterfrom
Conversation
For English and Vietnamese.
|
To Waveshare 6 in HD screen, it requires the driver from https://github.com/GregDMeyer/IT8951 |
lightisfaster
left a comment
There was a problem hiding this comment.
The PR brings some interesting things to discuss. Overall, the commit is huge and i think it would be nicer to make some smaller PR that are easier to review.
The PR contains several local configurations that have no global added value. In my opinion, PR cannot be merged like this local defines. Local settings need to be configurable without touch the code. I still think it's nice that the atm is used in vn. Have fun.
| config.SATSFEE = utils.get_sats_with_fee() | ||
| config.SATS -= config.SATSFEE | ||
| logger.info("2 cents added") | ||
| logger.info("10,000 VND added") |
There was a problem hiding this comment.
Affects all devices, must be configurable and have cents as the default value. Otherwise it will confuse users.
| display.update_amount_screen() | ||
| if config.PULSES == 3: | ||
| config.FIAT += 0.05 | ||
| config.FIAT += 20000 |
There was a problem hiding this comment.
Affects all devices, must be configurable. Otherwise it will confuse users. Is fixed with #37
| import logging | ||
| import os | ||
| import math | ||
| from shutil import copyfile |
There was a problem hiding this comment.
Is that absolutely necessary or just style?
| SATSFEE = 0 | ||
| INVOICE = "" | ||
| # This markup will make the rate in VN nearer the market | ||
| MARKUP = 1.08 |
There was a problem hiding this comment.
I'm not sure with this variables. A fixed definition of MARKUP is not a good idea, better was is to config this because VN is not of global importance, sorry.
| restart_screen_1 = "ATM rebooting" | ||
| restart_screen_2 = "Please wait for" | ||
| restart_screen_3 = "some seconds." | ||
| restart_screen_4 = "ATM đang khởi động" |
There was a problem hiding this comment.
Breaks the current concept. We can discuss this but my idea would be to use different message files for different languages.
| # Set your fiat currency with the three letter | ||
| # currency code (https://www.xe.com/symbols.php) | ||
| cur = eur | ||
| cur = vnd |
There was a problem hiding this comment.
It is a local change that has no global added value.
| # Define what a cent is called in the currency | ||
| # of your choice for price display (singular). | ||
| centname = cent | ||
| centname = Dong |
There was a problem hiding this comment.
It is a local change that has no global added value
|
|
||
| # Set the Fee in % | ||
| fee = 2 | ||
| fee = 8.5 |
There was a problem hiding this comment.
It is a local change that has no global added value. Changing default value is not necessary
| # display = papiruszero2in | ||
| # display = waveshare2in13 | ||
| display = papiruszero2in | ||
| display = waveshare6in |
There was a problem hiding this comment.
Changing default value is not necessary
| # activewallet = btcpay_lnd | ||
| # activewallet = lntxbot | ||
| activewallet = | ||
| activewallet = |
For English and Vietnamese.