Конвертор кода: Go -> C++ и Python (форк https://github.com/andygeiss/esp32-transpiler)
Найти файл
2019-01-09 11:11:02 +01:00
api refactoring 2018-04-03 08:45:48 +02:00
impl modules added 2018-12-19 19:28:33 +01:00
.travis.yml go version 1.11.x added 2018-12-19 19:32:55 +01:00
go.mod modules added 2018-12-19 19:28:33 +01:00
go.sum modules added 2018-12-19 19:28:33 +01:00
LICENSE license changed to MIT 2019-01-09 11:11:02 +01:00
main.go log package replaced 2018-04-10 13:15:44 +02:00
Makefile spaces removed 2018-04-10 15:16:27 +02:00
README.md issue #1 solved 2018-11-05 17:51:05 +01:00

ESP32 Transpiler

Go Report Card Build Status

Purpose

The Arduino IDE is easy to use. But I faced problems like maintainability and testability at more complicated IoT projects. I needed to compile and flash the ESP32 before testing my code functionality by doing it 100% manually.

This solution transpiles Golang into Arduino code, which can be compiled to an image by using the ESP32 toolchain. Now I am able to use a fully automated testing approach instead of doing it 100% manually.

Important:

The Transpiler only supports a small subset of the Golang Language Specification. Look at the mapping and the tests to get the current functionality. It is also not possible to trigger the C/C++ Garbage Collection, because Golang handles it automatically "under the hood". Go strings will be transpiled to C constant char arrays, which could be handled on the stack.

Installation

go get -u github.com/andygeiss/esp32-transpiler

Usage

Usage of esp32-transpiler:
  -source string
        Golang source file
  -target string
        Arduino sketch file