# Como alterar Data e Hora no Raspberry?

{% hint style="danger" %}

#### **Pré-requisitos**

* Estar na **mesma rede local** do Raspberry Pi.
* Conhecer o **endereço IP** do dispositivo (ex.: `192.168.15.115`).
* Usuário e senha padrão do Raspberry (`pi` / `raspberry`) ou outras credenciais se tiverem sido alteradas.
* Um computador com **Windows** (usaremos Conexão de Área de Trabalho Remota).
  {% endhint %}

### Passo a Passo para alterar data e hora no Raspberry <a href="#passoapasso" id="passoapasso"></a>

{% stepper %}
{% step %}

#### Conectar ao Raspberry via Área de Trabalho Remota <a href="#id-1conectaraoraspberryviareadetrabalhoremota" id="id-1conectaraoraspberryviareadetrabalhoremota"></a>

* No Windows, pressione `Win` e digite **Conexão de Área de Trabalho Remota**; abra o aplicativo.
* No campo **Computador**, informe o IP do Raspberry Pi.
* Clique em **Conectar** → surgirá a interface gráfica do Raspberry.
* Faça login com **Usuário: pi** e **Senha: raspberry** (ou as credenciais definidas).

{% hint style="info" %}
Observação: se o serviço RDP não estiver instalado no Raspberry, instale via SSH com

`sudo apt install xrdp` e reinicie.
{% endhint %}
{% endstep %}

{% step %}

#### Ajustar Data e Hora pelo Terminal (comando direto) <a href="#id-2" id="id-2"></a>

* Abra o **Terminal** ou **CMD** dentro da sessão remota.
* Execute o comando abaixo, substituindo data e hora pelos valores corretos:

```bash
sudo date --set "08 Oct 2024 16:35:00"
```

* Pressione **Enter** e digite a senha se solicitado.
  {% endstep %}

{% step %}

#### Ajustar Data e Hora via Menu `raspi-config` (interface textual) <a href="#undefined" id="undefined"></a>

> Use este método se preferir uma interface guiada; nem sempre está disponível em todas as imagens.

1. No Terminal, rode:

```bash
sudo raspi-config
```

* Navegue com as setas até **4 Localization Options** → **12 Change Timezone**.
* Selecione **America** → **São Paulo**.
* Pressione **Tab** para escolher **Finish** e confirme.
  {% endstep %}
  {% endstepper %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://ajuda.pdvlegal.com.br/equipamentos/raspberry-o-que-preciso-saber/como-alterar-data-e-hora-no-raspberry.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
