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

Let tachograph.lua work with lua5.3 while being backwards compatible. #110

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

howl
Copy link

@howl howl commented Feb 8, 2020

This just makes the necesarry changes to apdu.lua and tachograph.lua to work with Lua 5.3 and also maintain the same output.

Signed-off-by: David Santamaría Rogado [email protected]

Lua 5.3 changes the way behaves with floats and integers.
To maintain the same output as with Lua 5.2 convert #atr to integer.
This way cold ATR appears as for example 23 instead 23.0.

Signed-off-by: David Santamaría Rogado <[email protected]>
howl added 2 commits February 8, 2020 22:27
This changes the bare-minimum to let tachograph.lua work over Lua 5.3.
Just the ISO-8859- part converted to integer to avoid conversion be nil
and the hours calculation floored.

Signed-off-by: David Santamaría Rogado <[email protected]>
Just convert to integers some output values to avoid .0 appearing in the output.

Signed-off-by: David Santamaría Rogado <[email protected]>
@howl howl force-pushed the tachograph-lua5.3 branch from aa0048c to 1450a9b Compare February 8, 2020 21:29
@howl
Copy link
Author

howl commented Feb 8, 2020

Ok, my first amend to a non last commit. I have changed the commit message of the bare minimum changes to also reflect that hours calculation have been floored.

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.

1 participant