[Open-source] A lightweight IoT platform developed in Golang, accelerating IoT development and delivery

Open SourceIoT
2026-06-28 00:53 1 次浏览 • 0 次下载 0KB
[Open-source] A lightweight IoT platform developed in Golang, accelerating IoT development and delivery

1. Project Overview

Sagoo IOT

SagooIOT is a lightweight IoT platform developed with golang. It supports cross-platform IoT access and management schemes, and implements basic functions for IoT development. Based on these functions, a complete IoT-related business system can be quickly built.

2. Open Source License

Licensed under Apache-2.0

3. Screenshots

Demonstration Picture

Demonstration Picture

4. Feature Overview

- SagooIOT System Advantages -

SagooIOT provides support for private deployment or containerization, allowing users to easily deploy it on a single machine, cluster, or container service environment, and supports horizontal expansion to meet different business needs. Using SagooIOT can achieve excellent performance and provide excellent IoT service capabilities.

Millions

Data Concurrency

Distributed system deployment, supporting millions of concurrent data.

Tens of millions

Device access

Device Gateway Horizontal Expansion, Supporting Tens of Millions of Device Access.

Billions

Data Collection

TDengine Time Series Database, Supporting Billions of Data Collection Points

Low Latency

Data Communication

High-performance network components, non-blocking network programming, with extremely low communication latency.

Features

  • High Productivity: A backend management system can be built in a few minutes
  • Modularity: Single application, multiple system mode, a complete application is split into multiple systems, making it easier to extend and increase code reuse.
  • Authentication Mechanism: Using gtoken for user state authentication and casbin for permission authentication
  • Routing Mode: Benefiting from goframe2.0, it provides a standardized routing registration way, without annotation, API documents can be automatically generated
  • Interface Development
  • Supporting Thing Models, Multiple Products, and Multiple Device Access Management
  • Shielding Network Protocol Complexity, Adapting to Multiple Access Protocols (TCP, MQTT, UDP, CoAP, HTTP, GRPC, RPC, etc.), Flexible Access to Different Devices from Different Manufacturers
  • Supporting Cross-Platform Running, Quickly Implementing Edge Computing Functions, Implementing Offline Automatic Warning, Automatic Execution, etc.
  • Supporting Cross-Terminal Display, Device Status Monitoring and Data Display can be performed through PC, Mobile, Tablet, etc.
  • Unique Plugin System, Supporting Cross-Language Access, Quickly Accessing through C/C++, Python-written Plugins
  • Plugin System Supports Hot Swapping, Supporting Modbus TCP, Modbus RTU, Modbus ASCII, IEC61850, OPC, etc. Data Collection Protocols

Built-in functions

  1. User Management: Users are system operators, this function mainly completes system user configuration.
  2. Department Management: Configuring system organizational structures (companies, departments, teams), tree structure presentation supports data permissions.
  3. Position Management: Configure system users' positions.
  4. Menu Management: Configure system menus, operation permissions, button permissions, etc.
  5. Role Management: Role menu permission distribution, set role data range permissions by organization.
  6. Dictionary Management: Maintain some fixed data frequently used in the system.
  7. Parameter Management: Dynamically configure common parameters in the system.
  8. Operation Log: Record and query system normal operation logs; record and query system abnormal information logs.
  9. Login Log: Record and query system login logs, including login exceptions.
  10. Online Users: Monitor the status of active users in the system.
  11. Scheduled Tasks: Online (add, modify, delete) task scheduling, including execution result logs.
  12. Code Generation: Generate front-end and back-end code.
  13. Service Monitoring: Monitor current system CPU, memory, disk, stack, etc. related information.
  14. File Upload, Cache Tags, etc.
  15. Product Management: Unified management of device-type products.
  16. Device Management: Device access and data configuration management.
  17. Data Center: Data modeling management of third-party APIs or databases and internal data, supporting rule definitions.

5. Tech Stack

System architecture

SagooIOT is an open-source enterprise-level IoT development platform based on GoLang. It is responsible for device management and protocol data management, supporting cross-platform IoT access and management schemes. The platform has implemented basic functions related to IoT development, and based on these functions, a complete IoT-related business system can be quickly built. The goal is to reduce development work through reusable components, simplify, and accelerate IoT development delivery. It supports multiple access protocols (TCP, MQTT, UDP, CoAP, HTTP, GRPC, RPC, etc.).

  • Based on the new Go Frame 2.0 + Vue3 + Element Plus, a full-stack front-end and back-end separated management system is developed.
  • Front-end uses vue-next-admin, Vue, Element UI.


Tech Stack

  • GoFrame
  • Vue3
  • Swagger
  • Jwt
  • Element plus
  • MySql
  • Redis
  • TDengine

Basic Environment Installation

  1. Redis 7.0.4
  2. TDengine 3.0.1.5
  3. EMQX 5.0.9-el8
  4. Nginx 1.22.0
  5. rule-engine
For detailed installation process, please refer to the open-source project official documentation.

Deployment Instructions

This program can be independently deployed and executed directly, or used with nginx or apache.

Hardware Requirements

Minimum Configuration

CPU

1 core

Memory

1GB

Hard disk

40G

Recommended Configuration


CPU

2-core+

Memory

4GB+

Hard disk

40GB+

Supported Platforms

SagooIOT uses Golang for development and has good cross-platform characteristics. The following platforms are supported:

aix/ppc64
android/386
android/amd64
android/arm
android/arm64
darwin/amd64
darwin/arm64
dragonfly/amd64
freebsd/386
freebsd/amd64
freebsd/arm
freebsd/arm64
illumos/amd64
js/wasm
linux/386
linux/amd64
linux/arm
linux/arm64
linux/mips
linux/mips64
linux/mips64le
linux/mipsle
linux/ppc64
linux/ppc64le
linux/riscv64
linux/s390x
netbsd/386
netbsd/amd64
netbsd/arm
netbsd/arm64
openbsd/386
openbsd/amd64
openbsd/arm
openbsd/arm64
plan9/386
plan9/amd64
plan9/arm
solaris/amd64
windows/386
windows/amd64
windows/arm

Device Access Protocol

After the device is successfully connected to the network, a specific protocol needs to be used to interact with the cloud platform. The following is a brief introduction to several commonly used device access protocols and the notes to be considered when selecting them.

MQTT

MQTT is a lightweight publish-subscribe message protocol that works on the TCP protocol. It requires devices to establish a persistent TCP connection with the cloud platform and complete authentication before data communication can be performed.

MQTT Protocol has the following significant advantages:

Supports Real-time Control

MQTT can achieve real-time command issuance and control through its long connection with the cloud platform. Devices can immediately receive control instructions and achieve real-time control in scenarios such as smart homes and agricultural monitoring.

Easy to Monitor Device Status

The long connection also makes it easy to monitor the online status of devices. Although the device connection may be disconnected due to network problems, the MQTT heartbeat mechanism can effectively detect the status.

Flexible Security Level

MQTT supports different security authentication mechanisms. For resource-constrained devices, simple username and password encryption can be used. For high-security scenarios, TLS certificate mechanisms can be used to ensure data security.

Small Data Traffic

MQTT uses binary format, which can significantly reduce unnecessary payload compared to text protocols. This is particularly beneficial for low-bandwidth networks such as NB-IoT. MQTT is a high-efficiency, flexible, and secure IoT message protocol. It is very suitable for scenarios that require real-time control and monitoring, and is the preferred access protocol for IoT.

HTTP

HTTP protocol runs on top of TCP and is very friendly to developers. Devices can send data to the cloud platform through HTTP.

HTTP is simple and practical, and if the device resources allow, HTTPS can be used for secure transmission. However, HTTP is not as real-time as MQTT and cannot perform command control. For simple data collection scenarios, HTTP can be chosen.

CoAP

CoAP is a lightweight REST-style protocol that runs on UDP and is more suitable for low-power devices.

CoAP is not only lightweight but also has a usage method similar to HTTP. If the device resources are limited, CoAP can be considered.

TCP

SagooIOT also supports custom protocol access based on TCP. For example, many DTU devices use TCP transparent transmission.

TCP can be highly customized, but it requires self-developed communication format parsing. It can also be converted to a different format on the cloud platform to adapt to different devices.

Devices can choose MQTT, HTTP, CoAP, or TCP access protocols based on their resource situation, real-time requirements, security requirements, etc.

Regardless of the protocol adopted, format parsing, authentication, and other processing are required. SagooIOT provides different protocol access methods and backend data processing and conversion functions.

Source: SagooIOT Official Website Documentation

#1
资源直链https://gitee.com/sagoo-cloud/sagooiot
去下载
星河码客

发现和分享优质开源项目,传承互联网精神,为开发者服务。

关于本站

联系我们

微信/广告合作:ITcloub (备注星河码客)

免责声明:本站资源版权归原作者所有,仅供学习与交流。如有侵权,请通过「关于我们 - 侵权投诉」联系删除。

Powered by Nuxt · Deployed on Cloudflare