Skip to content

Commit b0ffa8d

Browse files
committed
add README.md
1 parent a0c4fc5 commit b0ffa8d

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

README.md

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# cslt-tool
2+
3+
cslt-tool is a convenient wrapper of [arduino-cli](https://github.com/arduino/arduino-cli), it compiles Arduino sketches outputting object files and a json file in a `build/` directory
4+
The json contains information regarding libraries and core to use in order to build the sketch. The result is achieved by parsing the verbose output of `arduino-cli`.
5+
6+
## Requisites
7+
In order to run this tool you have to install first the [arduino-cli](https://github.com/arduino/arduino-cli) and have `arduino-cli` binary in your path, otherwise `cslt-tool` won't work.
8+
9+
## Build it
10+
In order to build it just use `go build`
11+
12+
## Usage
13+
`./cslt-tool compile -b <fqbn> <sketch_path>`
14+
15+
This is an example execution:
16+
``` bash
17+
$ ./cslt-tool compile -b arduino:samd:mkrwan1310 /home/umberto/getdeveui
18+
INFO[0001] arduino-cli version: 0.20.2
19+
INFO[0001] running: arduino-cli compile -b arduino:samd:mkrwan1310 /home/umberto/getdeveui -v --format json
20+
INFO[0002] copied file to /home/umberto/Nextcloud/8tb/Lavoro/cslt-tool/build/getdeveui.ino.cpp.o
21+
INFO[0002] created new file in: /home/umberto/Nextcloud/8tb/Lavoro/cslt-tool/build/result.json
22+
```
23+
The structure of the `build` forder is the following:
24+
```
25+
build/
26+
├── getdeveui.ino.cpp.o
27+
└── result.json
28+
```
29+
And the content of `build/result.json` is:
30+
```json
31+
{
32+
"coreInfo": {
33+
"packager": "arduino",
34+
"name": "samd",
35+
"version": "1.8.12"
36+
},
37+
"libsInfo": [
38+
{
39+
"name": "MKRWAN",
40+
"version": "1.1.0"
41+
}
42+
]
43+
}
44+
```

0 commit comments

Comments
 (0)