Commit Graph
5 Commits
Author SHA1 Message Date
Andre Neto a5851470b1 README: linha de copyright com os dois nomes completos, igual ao LICENSE 2026-10-08 16:16:36 +01:00
Andre Neto 5d4b62c40b Build the two sketches with PlatformIO, add offline checks and rewrite the README
Sumbrella had no build definition: it was two .ino files to open in the Arduino
IDE. This adds one PlatformIO project per sketch (PlatformIO only converts a
*.ino sitting at the top of its own src_dir) and there is now a real, repeated
compile for the boards the project actually used:

  Projeto.ino       -> Arduino Nano        206 B RAM, 3508 B flash of 30720
  Fetch_rain.ino    -> ESP8266 ESP-01     28972 B RAM, 280119 B of 434160 flash

The boards come from the course poster kept in the repository (Sumbrella.pdf,
"Listagem de material": Arduino Nano and ESP8226 ESP-01), not from the code:
neither sketch names its board. The ESP-01 flash size is not given anywhere, so
the 512 KB variant is targeted.

Dependencies are now reproducible. LiquidCrystal_I2C comes from the PlatformIO
registry by name and version. DS3231 1.01 cannot: all 87 registry hits were
checked and none exposes class Time / getTimeStr() / DS3231(data, sclk), so it is
pinned to tag v1.01 of a mirror whose files were verified byte-for-byte equal to
the libs/DS3231 removed in 009066d. A clean clone compiles as it is.

The unused LCD stays unused and no sensor is invented: the only thing this commit
does to the sketches is compile them.

tests/ holds the checks that need no board, each with a negative selftest that
proves the check bites: secrets hygiene (secrets.h not tracked and ignored, the
example complete and placeholder-only, no credential literal in any tracked file)
and pin validity against the Nano and ESP-01 pin maps. run.sh builds both targets
and then runs them, exiting non-zero on any failure. .gitignore now covers the
PlatformIO artefacts (.pio/, *.bin, *.elf and friends).

README.md is rewritten in the common format, with the real build and test output.
Two things it no longer says, because they are not true of this repository: no
revision reachable from main ever contained a credential literal (the deleted
ESP8266_Fetching_Data.ino carried the string "<REDACTED>"), and the DS3231
dependency is not installable from the PlatformIO registry.

Known, left unfixed on purpose: the LCD is constructed and never written to; the
rain values are printed and discarded; loop() calls setup() on failure; and
libs/DS3231 is still reachable in the history before 009066d.
2026-10-08 16:11:49 +01:00
Andre Neto 009066d182 Remove the third-party DS3231 library and license the project MIT
A libs/DS3231/ era CC BY-NC-SA 3.0 (non-commercial, share-alike), incompativel
com MIT; saiu do repo e ficou declarada como dependencia externa com versao e
origem (DEPENDENCIAS.md + README). So depois disso o repo pode ser MIT. Ano =
primeiro commit (2020). Nao se apagou nada do disco do autor.
2026-10-08 14:54:23 +01:00
Andre Neto 972e97ae89 Sumbrella: move WiFi and ThingHTTP secrets out of the sketch into secrets.h
Fetch_rain.ino carried the WiFi password and three ThingHTTP API keys as
plaintext literals. The sketch now includes the non-versioned secrets.h,
which defines WIFI_SSID, WIFI_PASSWORD and the three THINGHTTP_KEY_* symbols
(one per scheduled channel: today, tmrw, aftmrw). secrets.h.example lists all
five placeholders and .gitignore keeps secrets.h out of the repository.

Why: credentials must not live in version control. The old values are still in
the history and in clones, so they must be rotated and the API keys reissued.
2026-10-08 14:03:53 +01:00
grandsons b06ad0e074 Create README.md 2025-04-10 02:28:02 +01:00