# SurvyKit
**Repository Path**: xiaoke799/SurvyKit
## Basic Information
- **Project Name**: SurvyKit
- **Description**: 测量常用小工具 - 专业的工程测量计算工具
- **Primary Language**: Unknown
- **License**: Apache-2.0
- **Default Branch**: main
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2026-05-30
- **Last Updated**: 2026-09-14
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# SurvyKit - Survey Measurement Toolkit | 测量常用小工具
[English](#english) | [中文](#中文)
---
## Features
### 18+ Measurement Tools
#### Basic Calculations
- **Angle Conversion** - DMS to/from decimal degrees
- **Trigonometry** - sin/cos/tan and inverse functions
- **Distance Calculation** - Two-point distance and azimuth
- **Area Calculation** - Polygon area (shoelace formula)
#### Coordinate Transformation
- **Coordinate Conversion** - WGS84 / GCJ02 / BD09 interconversion
- **Forward Calculation** - Azimuth and distance to coordinates
- **Inverse Calculation** - Coordinates to distance and azimuth
- **Gauss Projection** - Gauss-Kruger forward and inverse (CGCS2000 / WGS84 / Beijing54 / Xian80)
#### Curve Calculations
- **Spiral Curve** - Main point elements and station calculation
- **Vertical Curve** - Parabolic elevation calculation
- **Circular Curve** - Curve elements (L/T/E/D) and coordinate calculation
- **Arch Calculation** - Circular arch parameter calculation
#### Engineering Survey
- **Traverse Survey** - Attached / closed / branch traverse adjustment with two-point edge input
- **Level Survey** - Attached / closed / open level adjustment
- **Resection** - Free station positioning (Cassini HJ2 method)
- **Forward Intersection** - Angle-based intersection
- **Layout Offset** - Chainage and perpendicular offset from base line
- **Unit Conversion** - Length / area / angle
- **Survey Log** - Calendar-view measurement records
### Additional Features
- **Excel Export** - Calculation results to CSV
- **Word Export** - Calculation results to RTF
- **Calendar View** - Browse survey logs by date
- **Search Function** - Search through survey logs
- **Privacy Policy** - Complete privacy documentation
- **User Agreement** - Terms and disclaimers
- **Settings** - App configuration and version info
## 🚀 Getting Started
### Prerequisites
- WeChat Developer Tools (latest version)
- WeChat account (for testing)
### Installation
1. Clone or download this repository
2. Open WeChat Developer Tools
3. Click "Import Project"
4. Select the `miniprogram` folder
5. Use "touristappid" as the AppID (or your own AppID)
6. Click "Import"
### Project Structure
```
SurvyKit/
├── miniprogram/
│ ├── pages/
│ │ ├── index/ # Home page
│ │ ├── math/ # Math tools category
│ │ ├── professional/ # Professional tools category
│ │ ├── log/ # Survey log
│ │ ├── settings/ # Settings
│ │ ├── privacy/ # Privacy policy
│ │ ├── agreement/ # User agreement
│ │ ├── help/ # Help documentation
│ │ ├── angle/ # Angle conversion
│ │ ├── trigonometry/ # Trigonometry
│ │ ├── distance/ # Distance calculation
│ │ ├── area/ # Area calculation
│ │ ├── unit/ # Unit conversion
│ │ ├── transform/ # Coordinate transformation
│ │ ├── forward/ # Forward calculation
│ │ ├── reverse/ # Inverse calculation
│ │ ├── gauss/ # Gauss projection
│ │ ├── intersection/ # Forward intersection
│ │ ├── resection/ # Resection (free station)
│ │ ├── layout/ # Layout offset
│ │ ├── spiral/ # Spiral curve
│ │ ├── vertical/ # Vertical curve
│ │ ├── circular/ # Circular curve
│ │ ├── arch/ # Arch calculation
│ │ ├── traverse/ # Traverse survey
│ │ └── level/ # Level survey
│ ├── utils/
│ │ └── calculation.js # Core calculation library (20+ functions)
│ ├── images/
│ │ └── tab/ # Tab bar vector icons
│ ├── app.js
│ ├── app.json
│ ├── app.wxss
│ └── sitemap.json
├── project.config.json
├── DEVELOPER.md
├── DEVELOPER_INFO.md
├── .gitignore
├── LICENSE
├── package.json
├── README.md
└── images/
└── README.md # Tab icon reference
```
## 🛠️ Technology Stack
- **Framework**: WeChat Mini Program (Native)
- **Language**: JavaScript, WXML, WXSS
- **Storage**: Local Storage (wx.setStorageSync)
- **Cloud**: Cloud Development (optional)
## 📖 Usage
### For Users
1. Open the mini program in WeChat
2. Navigate through the tab bar to find tools
3. Select a calculation tool
4. Enter the required parameters
5. Tap "Calculate" to get results
6. Use "Export" to save results to Excel/Word
### For Developers
#### Adding New Tools
1. Create a new folder under `pages/`
2. Create `index.wxml`, `index.wxss`, `index.js`, `index.json`
3. Add the page to `app.json` pages array
4. Implement your calculation logic
#### Export Feature
The project includes built-in export functionality:
```javascript
const fs = wx.getFileSystemManager();
fs.writeFile({
filePath: filePath,
data: csvContent,
encoding: 'utf8',
success: () => {
wx.openDocument({
filePath: filePath,
fileType: 'csv'
});
}
});
```
## 🎨 UI Design
- **Color Theme**: Purple gradient (#667eea → #764ba2)
- **Layout**: Card-based design
- **Navigation**: Bottom tab bar
- **Icons**: Emoji icons for tool representation
- **Style**: Modern, clean, professional
## 📋 Data Storage
All survey logs are stored locally using:
- Key: `surveyLogs`
- Format: JSON array
- Location: User device storage
## 🔒 Privacy & Compliance
- Complete Privacy Policy page
- User Agreement with disclaimer
- Local data storage only
- No unauthorized data collection
## 📱 Compatibility
- Supports WeChat version 7.0+
- Optimized for all screen sizes
- Works on iOS and Android
- Minimum libVersion: 2.19.4
## 🐛 Troubleshooting
**Q: Icons not displaying?**
A: Ensure emoji icons are supported by the device. Fallback to emoji set if needed.
**Q: Export not working?**
A: Check if file system access is granted. Try again on a real device.
**Q: Calculation results seem wrong?**
A: Verify input units. Check if coordinates are in the correct format.
## License
This project is proprietary software. All rights reserved by xiaoke799.
## 👨💻 Developer
**xiaoke799**
**Contact Email:** celiang-xiang@foxmail.com
**GitHub:** https://github.com/xiaoke799/SurvyKit
## 🙏 Acknowledgments
- WeChat Mini Program Documentation
- Surveying and Mapping Industry Standards
- Engineering Survey Calculation Methods
- Open source coordinate transformation algorithms
## 📞 Contact
For issues or suggestions:
- Submit feedback through the app
- Contact developer: celiang-xiang@foxmail.com
- Submit issues on GitHub: https://github.com/xiaoke799/SurvyKit
## Version History
- **V0.0.1** (2024-2026) - Initial development release
- 18+ measurement tools with professional calculation engine
- Angle conversion, trigonometry, distance, area, unit conversion
- WGS84 / GCJ02 / BD09 coordinate interconversion
- Gauss-Kruger projection (forward and inverse, 4 ellipsoids)
- Spiral / vertical / circular curve and arch calculation
- Traverse survey with attached / closed / branch adjustment
- Level survey adjustment
- Resection (Cassini HJ2 free station positioning)
- Forward intersection and layout offset calculation
- Survey log with calendar view and search
- Excel (CSV) and Word (RTF) export
- Privacy policy and user agreement
- Custom vector tab bar icons
- Lazy code loading and subPackages support
- Code package optimized to ~247KB
## 📌 Notes
- This is a native WeChat Mini Program
- No third-party dependencies required
- All calculations are performed locally
- Data stays on user's device
- Designed for professional surveyors and engineers
---
## 功能特性
### 18+ 测量计算工具
#### 基础计算
- **角度转换** - 度分秒与小数度互转
- **三角函数** - sin/cos/tan 及反函数
- **距离计算** - 两点间距离与方位角
- **面积计算** - 多边形面积(鞋带公式)
#### 坐标转换
- **坐标转换** - WGS84/GCJ02/BD09 互转
- **坐标正算** - 方位角与距离求坐标
- **坐标反算** - 两点坐标求距离方位角
- **高斯投影** - 高斯-克吕格正反算(CGCS2000/WGS84/北京54/西安80)
#### 曲线计算
- **缓和曲线** - 主点要素与桩号计算
- **竖曲线** - 抛物线高程计算
- **圆曲线** - 曲线要素 (L/T/E/D) 与坐标计算
- **拱架计算** - 圆弧拱参数计算
#### 工程测量
- **导线测量** - 附合/闭合/支导线平差,支持双点起始边和终点边
- **水准测量** - 附合/闭合/支水准平差
- **后方交会** - Cassini HJ2 自由设站
- **前方交会** - 角度交会法
- **线路偏距** - 中桩链距与垂距计算
- **单位换算** - 长度/面积/角度
- **测量日志** - 日历视图记录
### 附加功能
- **Excel 导出** - CSV 格式
- **Word 导出** - RTF 格式
- **日历视图** - 按日期查看
- **搜索功能** - 搜索日志记录
- **隐私政策** - 完整文档
- **用户协议** - 条款与免责
- **设置** - 应用配置与版本信息
## 🚀 快速开始
### 前置条件
- 微信开发者工具(最新版本)
- 微信账号(用于测试)
### 安装步骤
1. 克隆或下载本仓库
2. 打开微信开发者工具
3. 点击"导入项目"
4. 选择 `miniprogram` 文件夹
5. AppID 使用 "touristappid"(或填写你自己的 AppID)
6. 点击"导入"
### 项目结构
```
SurvyKit/
├── miniprogram/
│ ├── pages/
│ │ ├── index/ # 首页
│ │ ├── math/ # 数学工具分类
│ │ ├── professional/ # 专业工具分类
│ │ ├── log/ # 测量日志
│ │ ├── settings/ # 设置
│ │ ├── privacy/ # 隐私政策
│ │ ├── agreement/ # 用户协议
│ │ ├── help/ # 帮助文档
│ │ ├── angle/ # 角度转换
│ │ ├── trigonometry/ # 三角函数
│ │ ├── distance/ # 距离计算
│ │ ├── area/ # 面积计算
│ │ ├── unit/ # 单位换算
│ │ ├── transform/ # 坐标转换
│ │ ├── forward/ # 坐标正算
│ │ ├── reverse/ # 坐标反算
│ │ ├── gauss/ # 高斯投影
│ │ ├── intersection/ # 前方交会
│ │ ├── resection/ # 后方交会
│ │ ├── layout/ # 线路偏距
│ │ ├── spiral/ # 缓和曲线
│ │ ├── vertical/ # 竖曲线
│ │ ├── circular/ # 圆曲线
│ │ ├── arch/ # 拱架计算
│ │ ├── traverse/ # 导线测量
│ │ └── level/ # 水准测量
│ ├── utils/
│ │ └── calculation.js # 核心计算库 (20+ 函数)
│ ├── images/
│ │ └── tab/ # TabBar 矢量图标
│ ├── app.js
│ ├── app.json
│ ├── app.wxss
│ └── sitemap.json
├── project.config.json
├── DEVELOPER.md
├── DEVELOPER_INFO.md
├── .gitignore
├── LICENSE
├── package.json
├── README.md
└── images/
└── README.md # 图标说明
```
## 🛠️ 技术栈
- **框架**:微信小程序原生开发
- **语言**:JavaScript、WXML、WXSS
- **存储**:本地存储(wx.setStorageSync)
- **云开发**:可选
## 📖 使用说明
### 用户使用
1. 在微信中打开小程序
2. 通过底部导航栏浏览工具分类
3. 选择需要的计算工具
4. 输入所需参数
5. 点击"计算"获取结果
6. 使用"导出"功能保存为 Excel/Word
### 开发者指南
#### 新增工具
1. 在 `pages/` 目录下创建新页面文件夹
2. 创建 `index.wxml`、`index.wxss`、`index.js`、`index.json` 四个文件
3. 在 `app.json` 的 pages 数组中添加页面路径
4. 实现计算逻辑
#### 导出功能
项目内置了导出功能:
```javascript
const fs = wx.getFileSystemManager();
fs.writeFile({
filePath: filePath,
data: csvContent,
encoding: 'utf8',
success: () => {
wx.openDocument({
filePath: filePath,
fileType: 'csv'
});
}
});
```
## 🎨 界面设计
- **配色方案**:紫色渐变 (#667eea → #764ba2)
- **布局**:卡片式设计
- **导航**:底部 TabBar
- **图标**:Emoji 图标
- **风格**:现代、简洁、专业
## 📋 数据存储
所有测量日志使用本地存储:
- 键名:`surveyLogs`
- 格式:JSON 数组
- 位置:用户设备本地
## 🔒 隐私与合规
- 完整的隐私政策页面
- 用户协议与免责声明
- 仅本地数据存储
- 无未授权数据采集
## 📱 兼容性
- 支持微信 7.0+ 版本
- 适配所有屏幕尺寸
- 支持 iOS 和 Android
- 最低基础库版本:2.19.4
## 🐛 常见问题
**Q:图标不显示?**
A:请确认设备支持 Emoji 图标,必要时可切换图标方案。
**Q:导出功能不工作?**
A:请检查文件系统权限是否已授予,建议在真机上测试。
**Q:计算结果有误?**
A:请检查输入单位是否正确,坐标格式是否符合要求。
## 许可证
本项目为专有软件,所有权利归 xiaoke799 所有。
## 作者
**xiaoke799** - celiang-xiang@foxmail.com
## 🙏 致谢
- 微信小程序官方文档
- 测绘行业标准
- 工程测量计算方法
## 📞 联系方式
如有问题或建议,请通过小程序内反馈功能或联系开发者。
## 版本历史
- **V0.0.1** (2024-2026) - 初始开发版本
- 18+ 测量工具,专业计算引擎
- 角度转换、三角函数、距离、面积、单位换算
- WGS84 / GCJ02 / BD09 坐标互转
- 高斯-克吕格投影正反算(4种椭球)
- 缓和曲线、竖曲线、圆曲线、拱架计算
- 导线测量(附合/闭合/支导线平差)
- 水准测量平差
- 后方交会(Cassini HJ2 自由设站)
- 前方交会、线路偏距计算
- 测量日志(日历视图+搜索)
- Excel (CSV) 和 Word (RTF) 导出
- 隐私政策与用户协议
- 自定义矢量 TabBar 图标
- 按需注入和分包支持
- 代码包优化至约 247KB
## 📌 备注
- 本项目为微信小程序原生开发
- 无第三方依赖
- 所有计算均在本地完成
- 数据保存在用户设备
- 面向专业测绘工程师设计