Yes looks like AM there BUT Still looks like 24hr to me it has a 0 in front of the 5.rogerthn wrote: ↑Wed 17 Apr 2024 8:22 am Do you get AM/PM with the command below?Code: Select all
LC_ALL=en_US.utf8 date
It should read 5:30am
Moderator: mcrossley
Yes looks like AM there BUT Still looks like 24hr to me it has a 0 in front of the 5.rogerthn wrote: ↑Wed 17 Apr 2024 8:22 am Do you get AM/PM with the command below?Code: Select all
LC_ALL=en_US.utf8 date
I cant say what will work for you but it maybe a trial and error approach. remember give ChatGPT as much information as possible with your circumstances and therefore the answer should work without more questions being answered.If you want to permanently change the system's time format, you'll need to adjust the locale settings or the system clock format settings. Here's a general approach to change the system-wide time format on a Raspberry Pi:
Locale Configuration:
You can change the locale settings to a locale that uses the 12-hour time format.
Edit the locale configuration file:
Find the line with the desired locale and uncomment it. For example, uncomment the en_US.UTF-8 UTF-8 line.Code: Select all
sudo nano /etc/locale.gen
Then, generate the locale:
Finally, set the system's default locale:Code: Select all
sudo locale-gen
System Clock Format:Code: Select all
sudo update-locale LANG=en_US.UTF-8
To change the system clock format, you can use the timedatectl command:
This command sets the system's clock format to 12-hour. To revert back to 24-hour format, you can use:Code: Select all
sudo timedatectl set-time-format 12-hour
After making these changes, you may need to restart the system or log out and log back in for the changes to take effect.Code: Select all
sudo timedatectl set-time-format 24-hour
Remember to choose the approach that best suits your needs and preferences!
Can you please post the exact commands i would need to enter to get 12hr AM PM time here in florida it's 6:59am. I don't understand what you mean by "uncommon" . My apologies for all the questions juts trying to get this fixed once and for all. Appreciate all the help.ConligWX wrote: ↑Wed 17 Apr 2024 10:14 am I'm guessing chatgpt would be your best friend.
a quick find there gives some help.
I cant say what will work for you but it maybe a trial and error approach. remember give ChatGPT as much information as possible with your circumstances and therefore the answer should work without more questions being answered.If you want to permanently change the system's time format, you'll need to adjust the locale settings or the system clock format settings. Here's a general approach to change the system-wide time format on a Raspberry Pi:
Locale Configuration:
You can change the locale settings to a locale that uses the 12-hour time format.
Edit the locale configuration file:
Find the line with the desired locale and uncomment it. For example, uncomment the en_US.UTF-8 UTF-8 line.Code: Select all
sudo nano /etc/locale.gen
Then, generate the locale:
Finally, set the system's default locale:Code: Select all
sudo locale-gen
System Clock Format:Code: Select all
sudo update-locale LANG=en_US.UTF-8
To change the system clock format, you can use the timedatectl command:
This command sets the system's clock format to 12-hour. To revert back to 24-hour format, you can use:Code: Select all
sudo timedatectl set-time-format 12-hour
After making these changes, you may need to restart the system or log out and log back in for the changes to take effect.Code: Select all
sudo timedatectl set-time-format 24-hour
Remember to choose the approach that best suits your needs and preferences!
Please tryAdrianwx23 wrote: ↑Wed 17 Apr 2024 11:02 am Can you please post the exact commands i would need to enter to get 12hr AM PM time here in florida it's 6:59am. I don't understand what you mean by "uncommon" . My apologies for all the questions juts trying to get this fixed once and for all. Appreciate all the help.
Code: Select all
sudo sed -i 's/%I/%l/g' /usr/share/i18n/locales/en_US
Code: Select all
sudo locale-gen
Code: Select all
sudo update-locale
Code: Select all
LC_ALL=en_US.utf8 date
Gonna try this now from work after I enter these commands what do I do? Please adviserogerthn wrote: ↑Wed 17 Apr 2024 11:20 amPlease tryAdrianwx23 wrote: ↑Wed 17 Apr 2024 11:02 am Can you please post the exact commands i would need to enter to get 12hr AM PM time here in florida it's 6:59am. I don't understand what you mean by "uncommon" . My apologies for all the questions juts trying to get this fixed once and for all. Appreciate all the help.Code: Select all
sudo sed -i 's/%I/%l/g' /usr/share/i18n/locales/en_US
Code: Select all
sudo locale-gen
Then tryCode: Select all
sudo update-locale
Next step would be to change defaultCode: Select all
LC_ALL=en_US.utf8 date
Code: Select all
LC_ALL=en_US.utf8 date
Code: Select all
cat /etc/default/locale
Ok standby gonna try those first commands first. appreciate your patiencerogerthn wrote: ↑Wed 17 Apr 2024 12:58 pm I "need" to see that you are happy withWhat you could do before the final step is to show me the contents of your /etc/default/locale i.e.Code: Select all
LC_ALL=en_US.utf8 date
Code: Select all
cat /etc/default/locale
For this command are there any spaces? It's all together?Adrianwx23 wrote: ↑Wed 17 Apr 2024 12:53 pmGonna try this now from work after I enter these commands what do I do? Please adviserogerthn wrote: ↑Wed 17 Apr 2024 11:20 amPlease tryAdrianwx23 wrote: ↑Wed 17 Apr 2024 11:02 am Can you please post the exact commands i would need to enter to get 12hr AM PM time here in florida it's 6:59am. I don't understand what you mean by "uncommon" . My apologies for all the questions juts trying to get this fixed once and for all. Appreciate all the help.Code: Select all
sudo sed -i 's/%I/%l/g' /usr/share/i18n/locales/en_US
Code: Select all
sudo locale-gen
Then tryCode: Select all
sudo update-locale
Next step would be to change defaultCode: Select all
LC_ALL=en_US.utf8 date
Really appreciate your help
Adrianwx23 wrote: ↑Wed 17 Apr 2024 12:53 pmGonna try this now from work after I enter these commands what do I do? Please adviserogerthn wrote: ↑Wed 17 Apr 2024 11:20 amPlease tryAdrianwx23 wrote: ↑Wed 17 Apr 2024 11:02 am Can you please post the exact commands i would need to enter to get 12hr AM PM time here in florida it's 6:59am. I don't understand what you mean by "uncommon" . My apologies for all the questions juts trying to get this fixed once and for all. Appreciate all the help.Code: Select all
sudo sed -i 's/%I/%l/g' /usr/share/i18n/locales/en_US
Code: Select all
sudo locale-gen
Then tryCode: Select all
sudo update-locale
Next step would be to change defaultCode: Select all
LC_ALL=en_US.utf8 date
Really appreciate your help
Code: Select all
sudo sed -i 's/%I/%l/g' /usr/share/i18n/locales/en_US
Code: Select all
cat /etc/os-release
Code: Select all
ls -l /usr/share/i18n/locales/en*
I never said "uncommon"Adrianwx23 wrote: ↑Wed 17 Apr 2024 11:02 am Can you please post the exact commands i would need to enter to get 12hr AM PM time here in florida it's 6:59am. I don't understand what you mean by "uncommon" . My apologies for all the questions juts trying to get this fixed once and for all. Appreciate all the help.
Code: Select all
en_GB.UTF-8 UTF-8
# en_HK ISO-8859-1
# en_HK.UTF-8 UTF-8
# en_IE ISO-8859-1
# en_IE.UTF-8 UTF-8
# en_IE@euro ISO-8859-15
# en_IL UTF-8
# en_IN UTF-8
# en_NG UTF-8
# en_NZ ISO-8859-1
# en_NZ.UTF-8 UTF-8
# en_PH ISO-8859-1
# en_PH.UTF-8 UTF-8
# en_SC.UTF-8 UTF-8
# en_SG ISO-8859-1
# en_SG.UTF-8 UTF-8
# en_US ISO-8859-1
# en_US.ISO-8859-15 ISO-8859-15
# en_US.UTF-8 UTF-8
Code: Select all
# en_US.UTF-8 UTF-8
Code: Select all
en_US.UTF-8 UTF-8
rogerthn wrote: ↑Wed 17 Apr 2024 2:48 pm Whoops, your first try did have user and not usr
Screenshot 2024-04-17 164103.png
Ifis failing please show me output from the commands below?Code: Select all
sudo sed -i 's/%I/%l/g' /usr/share/i18n/locales/en_US
andCode: Select all
cat /etc/os-release
Code: Select all
ls -l /usr/share/i18n/locales/en*