Title: Boat Position
Author: Niels Olsen
Published: <strong>2026 年 5 月 31 日</strong>
Last modified: 2026 年 5 月 31 日

---

搜索插件

![](https://ps.w.org/boat-position/assets/banner-772x250.png?rev=3555344)

![](https://ps.w.org/boat-position/assets/icon-256x256.png?rev=3555344)

# Boat Position

 作者：[Niels Olsen](https://profiles.wordpress.org/pcio/)

[下载](https://downloads.wordpress.org/plugin/boat-position.zip)

 * [详情](https://cn.wordpress.org/plugins/boat-position/#description)
 * [评价](https://cn.wordpress.org/plugins/boat-position/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/boat-position/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/boat-position/#developers)

 [支持](https://wordpress.org/support/plugin/boat-position/)

## 描述

Boat Position turns your WordPress site into a live tracking and logbook service
for your boat.

The plugin is designed around the Teltonika RUTX50 router (*), a compact Linux-based
5G router with built-in GPS.
 A shell script on the router sends a position to your
site every minute. The plugin stores each position, runs a state machine to group
positions into trips and legs, and serves two public pages:

 * **Live map** (`/boat-position/map`) — shows the current position on an OpenStreetMap/
   OpenSeaMap map with a rotating arrow icon when underway and an idle indicator
   when stopped.
 * **Logbook** (`/boat-position/history`) — calendar sidebar with trip history. 
   Click any day to see the full route on the map. Logged-in editors can label harbour
   names and merge incorrectly split trips.

Over 150 Danish harbours are included as seed data so harbour names are detected
automatically from GPS coordinates.

No third-party services or API keys are required beyond your own WordPress site.
Maps are rendered using the free Leaflet.js library with OpenStreetMap and OpenSeaMap
tiles.

(*) There are other alternatives to using the RTUTX50 router, any device that has
access to a GPS and the internet can be configured as the source of position data.

E.g. a linux machine like Rasberry PI connected to either its own GPS or the boat
NMEA data.

## 屏幕截图

 * [[
 * Live map — current boat position with directional arrow on OpenSeaMap.
 * [[
 * Logbook — calendar sidebar, trip list, and route drawn on the map.

## 安装

 1. Upload the `boat-position` directory to `/wp-content/plugins/`.
 2. Activate the plugin in **Plugins** in the WordPress admin.
 3. Go to **Settings  Boat Position** to set a secret API key and find the router configuration
    instructions.
 4. Follow the router setup guide in **Plugins  Boat Position  About** to configure
    your router’s `sendgps.sh` script and cron job.
 5. Send a test position from a command prompt to verify the endpoint is working before
    installing on the boat.

After activation, if `/boat-position/map` returns a 404, go to **Settings  Permalinks**
and click **Save Changes** to flush the rewrite rules.

## 常见问题

### How do I use this plugin?

Install and activate the plugin, then go to **Settings  Boat Position**. Set a secret
API key, then follow the router configuration guide in the About page to set up 
your router’s cron job.

### Does it only work with the RUTX50 router?

No. Any device that can send an HTTP POST request with `lat`, `lon`, `speed`, `course`,
and `gps_time` fields to the REST endpoint will work. The About page documents the
exact format.

### Where are the public pages?

The plugin registers two pages automatically — no WordPress pages or shortcodes 
are needed:

 * Live map: `https://yoursite.com/boat-position/map`
 * Logbook: `https://yoursite.com/boat-position/history`

### Can I avoid storing the secret key in the database?

Yes. Define the key as a constant in `wp-config.php`:

define( ‘PCIO_BOAT_POSITION_API_KEY’, ‘your-secret-key-here’ );

When this constant is present, the database option is ignored and the settings field
is shown as read-only.

### The logbook is empty — no trips appear.

Check that the router is sending data by looking at your database’s `wp_boat_positions`
table. If rows are present but no trips appear, the trip engine may not have processed
them yet — visit the ingest endpoint directly or check the About page for the manual
trigger curl command.

## 评价

此插件暂无评价。

## 贡献者及开发者

「Boat Position」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ Niels Olsen ](https://profiles.wordpress.org/pcio/)

[帮助将「Boat Position」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/boat-position)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/boat-position/)，查看
[SVN仓库](https://plugins.svn.wordpress.org/boat-position/)，或通过[RSS](https://plugins.trac.wordpress.org/log/boat-position/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/boat-position/)。

## 更新日志

#### 1.0

 * Initial release.

## 额外信息

 *  版本 **1.0.0**
 *  最后更新：**1 周前**
 *  活跃安装数量 **不到10**
 *  WordPress 版本 ** 6.2 或更高版本 **
 *  已测试的最高版本为 **7.0**
 *  PHP 版本 ** 8.1 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/boat-position/)
 * 标签
 * [Boat](https://cn.wordpress.org/plugins/tags/boat/)[gps](https://cn.wordpress.org/plugins/tags/gps/)
   [logbook](https://cn.wordpress.org/plugins/tags/logbook/)[map](https://cn.wordpress.org/plugins/tags/map/)
   [tracking](https://cn.wordpress.org/plugins/tags/tracking/)
 *  [高级视图](https://cn.wordpress.org/plugins/boat-position/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/boat-position/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/boat-position/reviews/)

## 贡献者

 *   [ Niels Olsen ](https://profiles.wordpress.org/pcio/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/boat-position/)

## 捐助

您愿意支持这个插件的发展吗?

 [ 捐助此插件 ](https://www.paypal.com/donate/?hosted_button_id=DFM2JV8JKTTM6)