# homebridge-mailbox

> A Homebridge plugin with GPIO support

Latest version **1.0.5** (published 2018-07-21) · ISC license · 0 weekly downloads

## Install

```sh
npm install homebridge-mailbox
pnpm add homebridge-mailbox
yarn add homebridge-mailbox
bun add homebridge-mailbox
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.5 |
| Published | 2018-07-21 |
| First published | 2018-06-07 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=0.12.0 |
| Dependencies | 1 |
| Unpacked size | 8.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | us09alex |
| Maintainers | us09alex |
| Keywords | homebridge-plugin, homebridge, homebridge-mailbox, gipo, raspberry, raspberry-pi |

## Links

- npm: https://www.npmjs.com/package/homebridge-mailbox
- Repository: https://github.com/us09alex/homebridge-mailbox
- Homepage: https://github.com/us09alex/homebridge-mailbox#readme
- Issues: https://github.com/us09alex/homebridge-mailbox/issues
- npm.io page: https://npm.io/package/homebridge-mailbox

## Dependencies (1)

- [onoff](https://npm.io/package/onoff.md) ^3.1.0

## Alternatives

- [@expo/fingerprint](https://npm.io/package/@expo/fingerprint.md) — 6.2M weekly downloads
- [@azure/monitor-opentelemetry-exporter](https://npm.io/package/@azure/monitor-opentelemetry-exporter.md) — 850.0K weekly downloads
- [@azure/monitor-opentelemetry](https://npm.io/package/@azure/monitor-opentelemetry.md) — 624.0K weekly downloads
- [@posthog/ai](https://npm.io/package/@posthog/ai.md) — 423.3K weekly downloads
- [fakefilter](https://npm.io/package/fakefilter.md) — 63.9K weekly downloads

## Recent versions

- 1.0.5 (latest) — 2018-07-21
- 1.0.4 — 2018-07-14
- 1.0.3 — 2018-06-15
- 1.0.2 — 2018-06-15
- 1.0.1 — 2018-06-15
- 1.0.0 — 2018-06-12
- 0.0.3 — 2018-06-09
- 0.0.2 — 2018-06-07
- 0.0.1 — 2018-06-07

## README

# homebridge-mailbox
A plugin with GPIO support for Homebridge: https://github.com/nfarina/homebridge 

## Why this name?
I initially started this project to use it as notification system with my mailbox. In order to do that I used a wireless battery powered doorbell. I put the transmitter in my mailbox and connected it with button which noticed if someone open the lid. If this happens the transmitter sends a signal to the receiver which is connected to my raspberry pi.

## Installation

Install the plugin via npm:

```bash
npm install homebridge-mailbox -g
```

## My Installation

### Hardware
1x Wireless doorbell **with a battery powered receiver** (You can also use a AC powered receiver but its much more dangerous than a battery powered one)
1x Micro lever with three pins (http://a.co/23TeIz4)

### Steps:
#### Receiver:
Screw the doorbell receiver apart and look on the logicboard for the speaker "+" soldered point. Solder a cable on it and connect this cable with a GPIO port (eg. GPIO 4).
Screw together the receiver and insert some batteries.

### Sender:
Screw the sender apart and locate the "GND" and "+" pins of the button. Solder one cable on each pin. Now we want to have a closed power circuit if the lever is opend. So try out which to pins of lever achieve this behaviour. After that fix the level behind your mailbox lid. You can use for example adhesive. You need to pay attention if the button behind the lever is pressed when the mailbox lid is closed. If not the sender will send continuously a signal to the receiver.


## Configuration
Example config.json:

    {
        "platforms": [
            {
                "platform": "MailboxPlatform",
                "name": "mailbox",
                "mailboxName" : "Mailbox",
                "gpioPort": 4,
                "timeBetween": 5000,
                "minimumSignals": 10,
                "maximumAmountBetweenSignals": 2000,
                "debug": false
            }
        ]
    }

### mailboxName
The name of the mailbox in the Home app

### gpioPort
The port of the Raspberry PI to listen

### timeBetween
The minimum time between to triggers of the motion sensor. (Minimum is set to 5 seconds)

### minimumSignals
The minimum of signals with is required to trigger the motion sensor. You can set the maximum amount between two signals with "maximumAmountBetweenSignals". After that period of time the counter starts again at zero.

### maximumAmountBetweenSignals
The maximum amount between two signals.

### debug
If set to true you will see if the plugin detects a signal from the specified GPIO port.

---
_Source: https://npm.io/package/homebridge-mailbox · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
