- GCode and Part Programs
- CAD CAM
- NativeCAM
- NCam : Can not enter float values after update to latest deb
NCam : Can not enter float values after update to latest deb
- eFalegname
- Offline
- Elite Member
Less
More
- Posts: 253
- Thank you received: 30
08 Sep 2017 13:31 #98684
by eFalegname
Replied by eFalegname on topic NCam : Can not enter float values after update to latest deb
Please Log in or Create an account to join the conversation.
08 Sep 2017 14:50 #98691
by FernV
Replied by FernV on topic NCam : Can not enter float values after update to latest deb
You should be able to update now
I used it for days without issue, let me know if you do have some
Fern
I used it for days without issue, let me know if you do have some
Fern
Please Log in or Create an account to join the conversation.
- eFalegname
- Offline
- Elite Member
Less
More
- Posts: 253
- Thank you received: 30
08 Sep 2017 16:55 #98703
by eFalegname
Replied by eFalegname on topic NCam : Can not enter float values after update to latest deb
Fern and Norbert
all it's ok, now the calculator works fine.
Thank you!
all it's ok, now the calculator works fine.
Thank you!
Please Log in or Create an account to join the conversation.
12 Sep 2017 08:38 #98866
by newbynobi
Replied by newbynobi on topic NCam : Can not enter float values after update to latest deb
Hallo Fern,
you changes did solve the problem of the decimal separator with German Localization, but the "Pi" problem is still there.
If I push Pi, the display of the calculator shows Pi, if I then press "=" I get 314159265359,000
I I press enter, the value is concerted to be "25399997,460"
But I expected to get something like 3.14159....
That happens, because math(Pi) does return a dot separated value, nevertheless what localization you have.
That is why i changed the conversion to be
temp = temp.replace('Pi', str(math.pi).replace(".",decimal_point))
Norbert
you changes did solve the problem of the decimal separator with German Localization, but the "Pi" problem is still there.
If I push Pi, the display of the calculator shows Pi, if I then press "=" I get 314159265359,000
I I press enter, the value is concerted to be "25399997,460"
But I expected to get something like 3.14159....
That happens, because math(Pi) does return a dot separated value, nevertheless what localization you have.
That is why i changed the conversion to be
temp = temp.replace('Pi', str(math.pi).replace(".",decimal_point))
Norbert
Please Log in or Create an account to join the conversation.
12 Sep 2017 08:38 #98868
by newbynobi
Replied by newbynobi on topic NCam : Can not enter float values after update to latest deb
Hallo Floris,
have you tried the Pi part?
Norbert
have you tried the Pi part?
Norbert
Please Log in or Create an account to join the conversation.
12 Sep 2017 10:27 - 12 Sep 2017 10:41 #98873
by FernV
Replied by FernV on topic NCam : Can not enter float values after update to latest deb
This is really strange because even on your pc locale.atof('2.5') returned 2.5 the right value.
It will be changed tonight.
Fern
It will be changed tonight.
Fern
Last edit: 12 Sep 2017 10:41 by FernV.
Please Log in or Create an account to join the conversation.
12 Sep 2017 13:27 - 12 Sep 2017 13:29 #98888
by FernV
Replied by FernV on topic NCam : Can not enter float values after update to latest deb
Hi Norbert,
I was finally able to reproduce your issue. I had to use :
export LANG='de_DE'
run the test and locale.atof('2.5') finally resulted in 25.000
de_DE and fr_CA both use ',' for decimal separator and this issue never occured on my pc's as
locale.atof('2.5') always resulted in 2.500
Fern
I was finally able to reproduce your issue. I had to use :
export LANG='de_DE'
run the test and locale.atof('2.5') finally resulted in 25.000
de_DE and fr_CA both use ',' for decimal separator and this issue never occured on my pc's as
locale.atof('2.5') always resulted in 2.500
Fern
Last edit: 12 Sep 2017 13:29 by FernV.
Please Log in or Create an account to join the conversation.
- GCode and Part Programs
- CAD CAM
- NativeCAM
- NCam : Can not enter float values after update to latest deb
Time to create page: 0.217 seconds