Welcome to the Cumulus Support forum.

Latest Cumulus MX V4 release 4.0.1 (build 4023) - 16 May 2024

(Note that 4.1.0 (build 4024) - 05 June 2024 remains available, but usage of this version is not recommended - particularly for Davis stations - and the included utility in this distribution for migrating to v4 is known to contain errors affecting conversion of dayfile.txt)

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

Using norwegian locale

Discussion of the Cumulusutils tool and website generator.

Moderator: HansR

sutne
Posts: 388
Joined: Sun 14 Oct 2012 4:23 pm
Weather Station: HP2553 (WS80) and HP2564 (WS90)
Operating System: Raspbian Bullseye and Bookworm
Location: Rjoanddalen and Kronstad, Norway
Contact:

Using norwegian locale

Post by sutne »

I have a new installation where I want set up CumulusMX using norwegian locale.
This seems to work with CumulusMX, I have comma as decimal points and dates in norwegian, but CumulusUtils does not like the time format in my dayfile (08.15).
As mentioned elsewhere, this is a bit strange setup, running on a MacBook Air and I start CumulusMX with the -lang nb-NO option.
You do not have the required permissions to view the files attached to this post.
sutne
Posts: 388
Joined: Sun 14 Oct 2012 4:23 pm
Weather Station: HP2553 (WS80) and HP2564 (WS90)
Operating System: Raspbian Bullseye and Bookworm
Location: Rjoanddalen and Kronstad, Norway
Contact:

Re: Using norwegian locale

Post by sutne »

Mark,
I think this one is for you.
using -lang nb-NO gives time format hh.mm
This format is kind of unknown.

Using -lang nn-NO gives time format hh:mm
which is much more common, and accepted by Cumulusutils.

I can use nn-NO, so there is no rush to have it fixed.
User avatar
rogerthn
Posts: 531
Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:

Re: Using norwegian locale

Post by rogerthn »

I did have "similar" issues some time back, 2015 :lol:
The culprit was found in Mono "languages handling".
I did write a small program but now I cannot find the source code and the program only do as below.

Code: Select all

echo $LANG
en_GB.UTF-8
mono HelloWorldMMM.exe
Hello World, below is DateTime.Now.ToString MMM, MMMM, ddd and dddd
Oct
October
Sun
Sunday

Code: Select all

export LANG=sv_SE.UTF-8
mono HelloWorldMMM.exe
Hello World, below is DateTime.Now.ToString MMM, MMMM, ddd and dddd
okt
oktober
sön
söndag
Enclosing the program, maybe someone could create a more complete "Mono languages handling program"
You do not have the required permissions to view the files attached to this post.
Image
User avatar
HansR
Posts: 6084
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: Using norwegian locale

Post by HansR »

I am not really sure it can formally be solved because the language system (as far as I found) does use a dot for hours/minutes separator in Norwegian Bokmål. There is no guilty: if that is the official way then it is used correctly. If you are sure it is not then you will have to work your way through the bureaucracy to change this and I wish you GOOD LUCK :lol:

Anyway, I you nevertheless wish to use the official version (the dot -separator for the hrs) then let me know, I need to adjust something in CUtils because I did not anticipate this. Afaics this is not a bug in CMX nor in CUtils. You may see it as an omission in CUtils which I am prepared to correct if really wanted.
Hans

https://meteo-wagenborgen.nl
CMX build 4023+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
sutne
Posts: 388
Joined: Sun 14 Oct 2012 4:23 pm
Weather Station: HP2553 (WS80) and HP2564 (WS90)
Operating System: Raspbian Bullseye and Bookworm
Location: Rjoanddalen and Kronstad, Norway
Contact:

Re: Using norwegian locale

Post by sutne »

I have never seen the ´.´ used in time before. It has always been ´:´ in Norway.
And there is no reason nb and nn should have different time notation.

I thought this was something inside of CMX, but Rogerthn points to mono, and then it will be difficult to change.

Edit:
Official norwegian sites says you can use both: 08.15 or 08:15 (or even 0815)

Solution: I have to use nn-NO, no problem.
Last edited by sutne on Sun 09 Oct 2022 9:22 am, edited 1 time in total.
User avatar
HansR
Posts: 6084
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: Using norwegian locale

Post by HansR »

sutne wrote: Sun 09 Oct 2022 8:05 am I have never seen the ´.´ used in time before. It has always been ´:´ in Norway.
And there is no reason nb and nn should have different time notation.

I thought this was something inside of CMX, but Rogerthn points to mono, and then it will be difficult to change.
It goes even beyond mono. Mono simply implements the rules as does Microsoft in general. This is an international thing.
There is ISO 8601, then there are per country deviations (The Norway wiki btw says nothing about points)
sutne wrote: Sun 09 Oct 2022 8:05 am the link you provide, what is it? IBM?
Yes, it is a HCL Leap page (fka: IBM Forms Experience Builder). Anyway, if it is a point don't think that can be easily changed.

I would advise to use nn-NO unless you seriously have a reason not to.
Hans

https://meteo-wagenborgen.nl
CMX build 4023+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
User avatar
HansR
Posts: 6084
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: Using norwegian locale

Post by HansR »

@Steinar: You might be interested in this link which even has a name in Oslo somewhere where you may complain or otherwise point to the anomaly. (Clause 5 and Clause 7)
Hans

https://meteo-wagenborgen.nl
CMX build 4023+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
sutne
Posts: 388
Joined: Sun 14 Oct 2012 4:23 pm
Weather Station: HP2553 (WS80) and HP2564 (WS90)
Operating System: Raspbian Bullseye and Bookworm
Location: Rjoanddalen and Kronstad, Norway
Contact:

Re: Using norwegian locale

Post by sutne »

As I edited in a previous post.
Officially in Norway you can use . : or nothing.

It is not easy.

I will use nn-NO, that for some reason use :
User avatar
rogerthn
Posts: 531
Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:

Re: Using norwegian locale

Post by rogerthn »

@sutne, maybe try enclosed program with different LANGs to check if it's mono or not?
Compiled as below on jessie using Mono 3.2.8
mcs HelloWorldTestingDateTimeFormats.cs

Code: Select all

export LANG=en_GB.UTF-8
mono HelloWorldTestingDateTimeFormats.exe
Hello World, below is DateTime.Now.ToString()
09/10/2022 11:49:35

Code: Select all

export LANG=sv_SE.UTF-8
mono HelloWorldTestingDateTimeFormats.exe
Hello World, below is DateTime.Now.ToString()
2022-10-09 11:51:05
PS

Code: Select all

export LANG=en_US.UTF-8
mono HelloWorldTestingDateTimeFormats.exe
Hello World, below is DateTime.Now.ToString()
10/9/2022 12:06:44 PM
You do not have the required permissions to view the files attached to this post.
Image
sutne
Posts: 388
Joined: Sun 14 Oct 2012 4:23 pm
Weather Station: HP2553 (WS80) and HP2564 (WS90)
Operating System: Raspbian Bullseye and Bookworm
Location: Rjoanddalen and Kronstad, Norway
Contact:

Re: Using norwegian locale

Post by sutne »

Thank you, Roger,
but will just use nynorsk (nn-NO) which uses : as time separator.

Officially everything can be used in norwegian bokmål.
User avatar
rogerthn
Posts: 531
Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:

Re: Using norwegian locale

Post by rogerthn »

OK :!:
PS
But I needed to know ;)

Code: Select all

export LANG=nb_NO.UTF-8
mono HelloWorldTestingDateTimeFormats.exe
Hello World, below is DateTime.Now.ToString()
09.10.2022 13.19.45

Code: Select all

export LANG=nn_NO.UTF-8
mono HelloWorldTestingDateTimeFormats.exe
Hello World, below is DateTime.Now.ToString()
09.10.2022 13:20:21
Image
User avatar
HansR
Posts: 6084
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: Using norwegian locale

Post by HansR »

@roger: interesting. But does it also have the same result on windows? Because that would say it is not mono which is guilty.
Hans

https://meteo-wagenborgen.nl
CMX build 4023+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
User avatar
HansR
Posts: 6084
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: Using norwegian locale

Post by HansR »

@Steinar: Attached is patch 2 which solves the problem when the date has point separators.
You do not have the required permissions to view the files attached to this post.
Hans

https://meteo-wagenborgen.nl
CMX build 4023+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
sutne
Posts: 388
Joined: Sun 14 Oct 2012 4:23 pm
Weather Station: HP2553 (WS80) and HP2564 (WS90)
Operating System: Raspbian Bullseye and Bookworm
Location: Rjoanddalen and Kronstad, Norway
Contact:

Re: Using norwegian locale

Post by sutne »

Thank you, Hans.
That patch solved it! :clap:

And I deleted the DoneToday in the Map, so now there is a Website in the User Map.
User avatar
HansR
Posts: 6084
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: Using norwegian locale

Post by HansR »

@Steinar, @rogerthn, anybody:
Find enclosed the little program by roger (modified) which runs anywhere under mono and straight away under windows. It takes a locale as argument (e.g. nb-NO) and displays the current date/time and PI with the separators for that locale. It works with any locale defined.

NOTE: this shows that the nb-NO locale is differently implemented under Windows than it is under mono.
You do not have the required permissions to view the files attached to this post.
Hans

https://meteo-wagenborgen.nl
CMX build 4023+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
Post Reply