ambientweather2sqlite


Nameambientweather2sqlite JSON
Version 0.7.0 PyPI version JSON
download
home_pageNone
SummaryA project to record weather observations from an AmbientWeather station over the local network - no API needed!
upload_time2025-07-19 22:27:09
maintainerNone
docs_urlNone
authorNone
requires_python>=3.11
licenseNone
keywords ambientweather ambient sqlite tweather
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # AmbientWeather to SQLite

[![PyPI](https://img.shields.io/pypi/v/ambientweather2sqlite.svg)](https://pypi.org/project/ambientweather2sqlite/)
[![Lint](https://github.com/hbmartin/ambientweather2sqlite/actions/workflows/lint.yml/badge.svg)](https://github.com/hbmartin/ambientweather2sqlite/actions/workflows/lint.yml)
[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
[![Code style: black](https://img.shields.io/badge/🐧️-black-000000.svg)](https://github.com/psf/black)
[![Checked with pyrefly](https://img.shields.io/badge/🪲-pyrefly-fe8801.svg)](https://pyrefly.org/)
[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/hbmartin/ambientweather2sqlite)

A project to record minute-by-minute weather observations from an AmbientWeather station over the local network - no API needed!

## Key Features

* Local Network Operation: Direct connection to weather stations without external API dependencies
* Continuous Data Collection: Automated daemon process collecting data at 60-second intervals
* Dynamic Schema Management: Automatic database schema evolution as new sensors are detected
* HTTP JSON API: Optional web server providing live data access, Includes hourly and daily aggregation endpoints.
* Interactive Configuration: Command-line setup wizard for initial configuration
* Zero Dependencies: Pure Python with no (potentially) untrusted 3rd parties.

## Installation

* macOS: `brew install pipx && pipx install ambientweather2sqlite`
* Ubuntu / Debian: `sudo apt update && sudo apt install pipx && pipx install ambientweather2sqlite`
* Fedora: `sudo dnf install pipx && pipx install ambientweather2sqlite`

## Setup

On the first run of `ambientweather2sqlite` you will be asked to provide the station's LiveData URL and the database path.

This config file is saved to your current directory by default but may be stored anywhere.

On subsequent runs, you can pass the file name as a command line argument or it will be automatically detected in your current directory or at `~/.aw2sqlite.toml`

## HTTP JSON API

The optional web server provides live data access and aggregation endpoints:

### Endpoints

- **`/`** - Live weather data
- **`/daily`** - Daily aggregated data  
- **`/hourly`** - Hourly aggregated data for a specific date

### Daily Aggregation

Query parameters:
- `q` - Aggregation fields (e.g., `avg_outHumi`, `max_gustspeed`)
- `days` - Number of prior days (default: 7)
- `tz` - Timezone for timestamp conversion (required)

Examples:
```
/daily?tz=America/New_York&q=avg_outHumi&days=7
/daily?tz=Europe/London&q=min_outTemp&q=sum_eventrain
```

### Hourly Aggregation

Query parameters:
- `date` - Date in YYYY-MM-DD format (required)
- `q` - Aggregation fields
- `tz` - Timezone for timestamp conversion (required)

Examples:
```
/hourly?date=2025-06-27&tz=America/Chicago&q=avg_outHumi
/hourly?date=2025-06-27&tz=%2B05%3A30&q=max_gustspeed
```

### Timezone Support

Timezone strings can be:
- IANA timezone names: `America/New_York`, `Europe/London`, `Asia/Tokyo`
- UTC offsets: `+05:30`, `-08:00`
- URL-encoded when necessary: `%2B05%3A30` for `+05:30`

## Development

Pull requests and issue reports are welcome. For major changes, please open an issue first to discuss what you would like to change.

### Core Architecture
<img src="media/arch.svg" />

### Control Flow
<img src="media/flow.svg" />

## Legal

© [Harold Martin](https://www.linkedin.com/in/harold-martin-98526971/) - released under [GPLv3](LICENSE.md)

AmbientWeather is a trademark of Ambient, LLC.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "ambientweather2sqlite",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.11",
    "maintainer_email": null,
    "keywords": "ambientweather, ambient, sqlite, tweather",
    "author": null,
    "author_email": "Harold Martin <Harold.Martin@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/f6/c0/accfa782d466bc0cfca863882f9b17946e2ddfa46102b17c2b12280b9b48/ambientweather2sqlite-0.7.0.tar.gz",
    "platform": null,
    "description": "# AmbientWeather to SQLite\n\n[![PyPI](https://img.shields.io/pypi/v/ambientweather2sqlite.svg)](https://pypi.org/project/ambientweather2sqlite/)\n[![Lint](https://github.com/hbmartin/ambientweather2sqlite/actions/workflows/lint.yml/badge.svg)](https://github.com/hbmartin/ambientweather2sqlite/actions/workflows/lint.yml)\n[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)\n[![Code style: black](https://img.shields.io/badge/\ud83d\udc27\ufe0f-black-000000.svg)](https://github.com/psf/black)\n[![Checked with pyrefly](https://img.shields.io/badge/\ud83e\udeb2-pyrefly-fe8801.svg)](https://pyrefly.org/)\n[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/hbmartin/ambientweather2sqlite)\n\nA project to record minute-by-minute weather observations from an AmbientWeather station over the local network - no API needed!\n\n## Key Features\n\n* Local Network Operation: Direct connection to weather stations without external API dependencies\n* Continuous Data Collection: Automated daemon process collecting data at 60-second intervals\n* Dynamic Schema Management: Automatic database schema evolution as new sensors are detected\n* HTTP JSON API: Optional web server providing live data access, Includes hourly and daily aggregation endpoints.\n* Interactive Configuration: Command-line setup wizard for initial configuration\n* Zero Dependencies: Pure Python with no (potentially) untrusted 3rd parties.\n\n## Installation\n\n* macOS: `brew install pipx && pipx install ambientweather2sqlite`\n* Ubuntu / Debian: `sudo apt update && sudo apt install pipx && pipx install ambientweather2sqlite`\n* Fedora: `sudo dnf install pipx && pipx install ambientweather2sqlite`\n\n## Setup\n\nOn the first run of `ambientweather2sqlite` you will be asked to provide the station's LiveData URL and the database path.\n\nThis config file is saved to your current directory by default but may be stored anywhere.\n\nOn subsequent runs, you can pass the file name as a command line argument or it will be automatically detected in your current directory or at `~/.aw2sqlite.toml`\n\n## HTTP JSON API\n\nThe optional web server provides live data access and aggregation endpoints:\n\n### Endpoints\n\n- **`/`** - Live weather data\n- **`/daily`** - Daily aggregated data  \n- **`/hourly`** - Hourly aggregated data for a specific date\n\n### Daily Aggregation\n\nQuery parameters:\n- `q` - Aggregation fields (e.g., `avg_outHumi`, `max_gustspeed`)\n- `days` - Number of prior days (default: 7)\n- `tz` - Timezone for timestamp conversion (required)\n\nExamples:\n```\n/daily?tz=America/New_York&q=avg_outHumi&days=7\n/daily?tz=Europe/London&q=min_outTemp&q=sum_eventrain\n```\n\n### Hourly Aggregation\n\nQuery parameters:\n- `date` - Date in YYYY-MM-DD format (required)\n- `q` - Aggregation fields\n- `tz` - Timezone for timestamp conversion (required)\n\nExamples:\n```\n/hourly?date=2025-06-27&tz=America/Chicago&q=avg_outHumi\n/hourly?date=2025-06-27&tz=%2B05%3A30&q=max_gustspeed\n```\n\n### Timezone Support\n\nTimezone strings can be:\n- IANA timezone names: `America/New_York`, `Europe/London`, `Asia/Tokyo`\n- UTC offsets: `+05:30`, `-08:00`\n- URL-encoded when necessary: `%2B05%3A30` for `+05:30`\n\n## Development\n\nPull requests and issue reports are welcome. For major changes, please open an issue first to discuss what you would like to change.\n\n### Core Architecture\n<img src=\"media/arch.svg\" />\n\n### Control Flow\n<img src=\"media/flow.svg\" />\n\n## Legal\n\n\u00a9 [Harold Martin](https://www.linkedin.com/in/harold-martin-98526971/) - released under [GPLv3](LICENSE.md)\n\nAmbientWeather is a trademark of Ambient, LLC.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A project to record weather observations from an AmbientWeather station over the local network - no API needed!",
    "version": "0.7.0",
    "project_urls": null,
    "split_keywords": [
        "ambientweather",
        " ambient",
        " sqlite",
        " tweather"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "85f0ffdaa63ed292b3d6e96f7a34410bd90ed267132c7b572c69111333101442",
                "md5": "88ce2e7f8f5d4a9b0d63f63cb0003089",
                "sha256": "ffbf8601b355a24b44f7eb61d28a4a3d1c48eb44699bd7632da26c90f0dd729d"
            },
            "downloads": -1,
            "filename": "ambientweather2sqlite-0.7.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "88ce2e7f8f5d4a9b0d63f63cb0003089",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.11",
            "size": 33819,
            "upload_time": "2025-07-19T22:27:08",
            "upload_time_iso_8601": "2025-07-19T22:27:08.532798Z",
            "url": "https://files.pythonhosted.org/packages/85/f0/ffdaa63ed292b3d6e96f7a34410bd90ed267132c7b572c69111333101442/ambientweather2sqlite-0.7.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "f6c0accfa782d466bc0cfca863882f9b17946e2ddfa46102b17c2b12280b9b48",
                "md5": "0b4a46fa86930582f1be77c51283f74e",
                "sha256": "07a5056be3725cc403ecb7c8e0080a2be074446df39260024f9e33850e1efe64"
            },
            "downloads": -1,
            "filename": "ambientweather2sqlite-0.7.0.tar.gz",
            "has_sig": false,
            "md5_digest": "0b4a46fa86930582f1be77c51283f74e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.11",
            "size": 35453,
            "upload_time": "2025-07-19T22:27:09",
            "upload_time_iso_8601": "2025-07-19T22:27:09.937851Z",
            "url": "https://files.pythonhosted.org/packages/f6/c0/accfa782d466bc0cfca863882f9b17946e2ddfa46102b17c2b12280b9b48/ambientweather2sqlite-0.7.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-19 22:27:09",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "ambientweather2sqlite"
}
        
Elapsed time: 0.83432s