138 Commits

Author SHA1 Message Date
760a6e6988 [common] Log at warning level mDNS services or TXT records cannot be added
Some checks failed
Push (dev), Pull Request / Run Clang lint (push) Has been cancelled
Push (dev), Pull Request / Run Python lint (push) Has been cancelled
2026-01-02 01:17:31 -07:00
4d0c0833e9 x
Some checks failed
Push (dev), Pull Request / Run Clang lint (push) Has been cancelled
Push (dev), Pull Request / Run Python lint (push) Has been cancelled
2026-01-01 17:28:39 -07:00
b703d173e2 (XXX) use scratch lwip
Some checks failed
Push (dev), Pull Request / Run Clang lint (push) Has been cancelled
Push (dev), Pull Request / Run Python lint (push) Has been cancelled
2026-01-01 17:24:08 -07:00
Kuba Szczodrzyński
29303f7ec9 [boards] Add generic-rtl8720cf-2mb-896k board
Some checks failed
Push (dev), Pull Request / Run Clang lint (push) Has been cancelled
Push (dev), Pull Request / Run Python lint (push) Has been cancelled
Push (master) / Deploy docs (push) Has been cancelled
2025-11-17 20:32:54 +01:00
Kuba Szczodrzyński
c6b06d4be6 [release] v1.9.2
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2025-09-19 22:44:44 +02:00
Kuba Szczodrzyński
c9b2f9dd23 [boards] Fix syntax error in WB02A 2025-09-19 22:44:44 +02:00
Kuba Szczodrzyński
40590d174f [core] Update ltchiptool to v4.12.2 2025-09-19 22:39:47 +02:00
Rishab Mehta
780fb72bba [docs] Update README.md (#323) 2025-09-19 22:37:02 +02:00
Henri Chain
e9977a26e4 [boards] Add WB02A board (#332) 2025-09-19 22:36:51 +02:00
Piotr Szulc
1d97f0ce84 [core] Avoid re-defining C++ round() method (#321) 2025-09-19 22:36:35 +02:00
Luca Olivetti
895b6e89c5 [lightning-ln882h] Fix GPIO interrupt support (#326)
* fix interrupt handling for the ln882h

- all GPIOS can generate interrupts
- added calls to NVIC_SetPriority/NVIC_EnableIRQ/NVIC_DisableIRQ

* fix clang formatting error

* only call NVIC_DisableIRQ if no other gpio is using an interrupt

* fix (again) clang-format errors

* add IRQ capability on all pins

* don't bother with NVIC_DisableIRQ

* use pin->gpio instead of interruptNumber, use macro GPIO_GET_PORT for clarity

* Mark interrupts as supported for the LN882H

---------

Co-authored-by: lamauny <pub.elc@free.fr>
2025-09-19 22:25:03 +02:00
Kuba Szczodrzyński
9114bc4c49 [release] v1.9.1
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2025-06-01 19:38:36 +02:00
Kuba Szczodrzyński
9eae0cd253 [common] Add Arduino emptyString declaration 2025-06-01 19:38:11 +02:00
Kuba Szczodrzyński
37f096d3b5 [release] v1.9.0
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2025-05-28 15:51:09 +02:00
Kuba Szczodrzyński
6bf549b104 [misc] Update .clang-format style 2025-05-28 15:50:18 +02:00
lamauny
3054db9d9b [lightning-ln882h] Fix analog read, add Wi-Fi calibration, add generic board (#319)
* [ln882x] fix analog read

* [ln882h] add wifi temp calibration task

* [ln882h] add generic-ln882hki board

* [ln882h] fix wifi null pointer crash
2025-05-28 15:45:10 +02:00
lamauny
69e7e2debe [lightning-ln882h] Add support for Lightning LN882H family (#312)
* fix mbedtls bad pointer in function call (prototype mismatch)

* fix issue with weak families functions implemented in static library, it will never be linked. fixed by redefining prototypes inside families

* [ln882x] add support for lightning ln882x & ln882h families

* add i2c (wire) support

* add analog (adc) support

* add watchdog support

* [ln882x] changed default uart 0/1 pins; added board wl2s

* [ln882x] fix IRQ & ADC pins

* [ln882x] boards cosmetic

* [ln882x] wifi sta use otp mac addr by default; re-enabled wifi powersave mode

* [ln882x] clang-format clean code

* [ln882x] clang-format clean code

* Update families.json

* Apply suggestions from code review

* [ln882x] reformat json board files

* [ln882x] os_queue cleanup

* [ln882x] removed Beken auto-download command

* [ln882x] removed personal script file

* [ln882x] removed unusefull pi section in debugging.md

* [ln882x] removed Arduino.h and changed private I2C definition

* [ln882x] updated README.md

* [ln882x] changed pin naming scheme to PA/PB

* [ln882x] clean code

* [ln882x] clean code

* [ln882x] add ota image verification

* Update push-dev.yml

* [ln882x] fix boards ADC missing inputs]

* [ln882x] removed reg_xxx fixup files and use include guards instead

* [ln882x] cleanup code

* [ln882x] cleanup code

* [ln882x] fix lt_init weak functions linking

* [ln882x] revert lt_api.h modification, fixed with previous commit

* [ln882x] setup UF2 firmware for flasher with partitions

* [ln882x] update README.md

* [ln882x] include ln_wifi.h and ln_serial.h to avoid including bad headers on case insensitive systems

* [ln882x] Replace RingBuffer by SerialRingBuffer

* [ln882x] clang-format

* [ln882x] update README.md

* Apply suggestions from code review

* Reformat board JSON files

* Add mkdocs link redirect

* Update ltchiptool to v4.12.0

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2025-03-25 17:26:53 +01:00
Kuba Szczodrzyński
6083cca72e [misc] Update style to clang-format 19, black 25 and isort 6 2025-01-30 18:50:55 +01:00
Kuba Szczodrzyński
d17ea4da0f [release] v1.8.0
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2025-01-14 22:13:16 +01:00
Hajo Noerenberg
2ea0066536 [common] Make Serial RX buffer size configurable, increase default to 256 bytes (#313)
* Make Serial RX buffer configurable and set default to 256 bytes

* Replace RingBuffer by SerialRingBuffer
2025-01-13 12:14:41 +01:00
Martin Prokopič
3d23211c1e [realtek-ambz2] Fix partition table & bootloader flashing via UART (#307) 2024-12-17 17:13:04 +01:00
shilga
1769680d9e [realtek-ambz2] Fix C linkage for sys_now() in lwipopts (#286) 2024-12-17 11:50:44 +01:00
kuwoyuki
92351c0b92 [boards] Add RTL8710BX AFW121T board (#305)
* feat: afw121t board

* Update layout, regenerate with boardgen

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-12-16 15:46:36 +01:00
Kuba Szczodrzyński
0f6c31386b [release] v1.7.0
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2024-09-05 16:41:10 +02:00
Kuba Szczodrzyński
a9009a8cee [misc] Update .clang-format style 2024-09-05 16:36:55 +02:00
Piotr Szulc
31e1d51dbd [common] Cleanup mDNS code, cache service records (#263)
* Handle possible failure of mdns_resp_add_service

* One more place where mdns_resp_add_service may fail

* addServiceImpl should always store services

* Register in services when new netif is added

* Refactored handling of cached services.

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-09-05 15:54:04 +02:00
Luca Olivetti
41819f2fd6 [beken-72xx] Fix CHANGE interrupt logic (#290)
* fix CHANGE interrupt for beken-72xx

* Update cores/beken-72xx/arduino/src/wiring_irq.c

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-09-05 14:46:42 +02:00
David Woodhouse
17043f634f [beken-72xx] Add IPv6 and lwIP 2.2.0 support (#292)
* mDNS: Fix build against LwIP 2.2.0

* Stop defining ip_addr_t when !CONFIG_IPV6

The only reason we had to do this is because we forgot to define LWIP_IPV4,
which is fixed in our LwIP port now, but keep it around for !CONFIG_IPV6
for now for builds against older LwIP.

* Allow returning IPv6 results from WiFiClass::hostByName()

* Add ipv6 and extra mDNS files for LwIP 2.2.0

* Add IPv6 support to BK72xx WifiSTA

Add an allLocalIPv6() method to return a *vector* of addresses, rather
than just one. It's not clear where the enableIpV6() and localIPv6()
methods came from; they don't seem to be part of the standard Arduino
class.

Eventually at least for ESPHome, I'd like to stop using these classes
and just let the ESPHome wifi component talk directly to LwIP. Or maybe
LibreTiny should offer an API compatible with the esp-idf one which is
a light wrapper around LwIP.

But short of a major refactor, this seems like a reasonable option.

* Update LwIP default to 2.2.0

* Apply suggestions from code review

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-09-05 14:46:13 +02:00
devgs
e1c5761df9 [beken-72xx] Allow setting deep sleep wake-up pins as floating (#275)
According to guide `gpio_stay_*_map` are specifically there to prevent
pulling pins to a specific level and let them float during deep sleep.

https://docs.bekencorp.com/sdk_3.0.x/bk7238/build/en/latest/developer-guide/power_save/sleep_test.html

This allows any external low-power circuitry to change a pin level, as
required, to trigger the wake up

This requires changes in BDK and was implemented via fixup. Also, exposed
`gpio_stay_lo_map` parameter via `lt_deep_sleep_keep_floating_gpio` to
manage this configuration for pins in range P0-P31.
2024-09-05 14:45:48 +02:00
Kuba Szczodrzyński
fbaae21011 [release] v1.6.0
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2024-05-31 15:01:17 +02:00
Jaco Malan
fa2064b957 [realtek-ambz] Temporarily workaround CHANGE interrupts not supported (#282)
* fix change interruptsnot supported on rtl8710b

* Update cores/realtek-amb/arduino/src/wiring_irq.c

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-05-31 14:59:46 +02:00
Kuba Szczodrzyński
21a194f43d [core] Fix lwIP debugging support 2024-05-31 14:58:38 +02:00
devgs
b255402659 [beken-72xx] Fix race condition when checking Wi-Fi SSID (#274)
* Fix for a race condition in WiFi connection loop

There seems to be the race between the event RW_EVT_STA_CONNECTED
and an actual valid SSID value returned by BDK. If even a small delay
is injected immediately after the event reception the valid value
becomes available. Without this fix, due to a polling nature of ESPHome
WiFiComponent::check_connecting_finished function may observe the
WiFiSTAConnectStatus::CONNECTED status but with an empty SSID value,
leading to `Incomplete connection.` warning and immediate attempt to
start another connection, while the current one was actually established.

* Fixed clang format conformance

* Apply suggestions from code review

* Update cores/beken-72xx/arduino/libraries/WiFi/WiFiEvents.cpp

Co-authored-by: Cossid <83468485+Cossid@users.noreply.github.com>

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
Co-authored-by: Cossid <83468485+Cossid@users.noreply.github.com>
2024-05-31 14:54:41 +02:00
Kuba Szczodrzyński
dfabfbb921 [beken-72xx] Increase MBEDTLS_ENTROPY_MAX_SOURCES 2024-05-18 13:50:25 +02:00
Kuba Szczodrzyński
3b36a70c9a [core] Fix ESP_LOG#() macro syntax 2024-05-18 13:50:10 +02:00
Piotr Szulc
d1386a8e9d [libs] Fix mDNS string memory corruption, print error on record add failure (#260)
* Fixed unsafe conversion to underscore string

* Fixed formatting

* Save one byte if underscore not needed

* Don't allocate new string if already underscored

* Fix missing first character while copying

* Renamed function and made it inline

* Don't use signed index variable when searching for service

* Add proper cleanup of LwIPmDNS

- Free allocated memory both on end() and in the destructor
- Unregister callback from netif

* Don't free const pointer

* Removed unneeded casting

* Don't break the loop if failed to add txt record

* Fixed code formatting
2024-03-08 12:21:14 +01:00
Kuba Szczodrzyński
67b92b7f56 [release] v1.5.1
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2024-02-29 14:14:01 +01:00
Hajo Noerenberg
a1f8516e60 [realtek-ambz] Fix crash after WiFi scan (#258) 2024-02-26 21:35:35 +01:00
cap9qd
cf52021d38 [core] Split reboot reasons due to wakeup (#254)
* Updates to break out wakeup reasons.

Per https://github.com/libretiny-eu/libretiny/issues/234

* Update cores/common/base/api/lt_device.h

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>

* fix clang-format

* Fix formatting of python files.

* Update lt_device.h

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-02-25 18:45:22 +01:00
cap9qd
b78c9387a6 [beken-72xx] Fix duration rollover in deep sleep (#253) 2024-02-22 20:24:40 +01:00
Kuba Szczodrzyński
b748d99437 [release] v1.5.0
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2024-02-20 17:16:15 +01:00
Anna
9a33fc0a69 [docs] Improve getting started guide (#252)
* Update Readme & improve md layout

- ESPHome now supports LibreTiny natively
- Added extra PIO docs references
- Reworded some sections slightly, to accomodate proper grammar
- PIO deprecated the `platformio platform install` command, replaced this with the official recommendation/replacement

* Use backslash for line break, revert changing indent

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-02-20 17:14:12 +01:00
Hajo Noerenberg
4cddc01f22 [libs] Fix MD5 calculation during OTA update (#240) 2024-01-17 22:49:33 +01:00
Piotr Szulc
1d80b5fff7 [beken-72xx] Free list returned by wlan_sta_scan_result() (#226)
* Free list returned by wlan_sta_scan_result()

* scanAlloc improvements

There were a few things I didn't like about this function:
1) realloc() was called a bit too often.
2) if realloc() failed, the previous memory was not freed.
3) scanAlloc returned previous count or 255 on error. But there was no real check for error and 255 could've been used as index to null. I think it's better to simple return boolean.
4) scanAlloc was clearing memory only up to (and excluding) the new entries.

* Corrected clearing new entries in scanAlloc

* scanAlloc() now returns number of allocated items

* Fixed compilation issues related to goto.
2024-01-06 19:41:01 +01:00
Cossid
140cf07173 [docs] Use official ESPHome version, add LT dev version guide (#223)
* Update ESPHome documentation

* Update note format

* Switch to https github format, give manual PR checkout instructions until a better method is found.

* Fix yaml sample spacing

* Fix indent

* Add addon migration info

* Replace spaces with tabs

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-01-06 19:40:44 +01:00
Piotr Szulc
1e3a82f439 [beken-72xx] Improve ddev ADC support (#220) 2024-01-06 19:40:33 +01:00
Cossid
c90794e9f5 [beken-72xx] Allow connecting to specific BSSID if provided (#209)
* Switch to bk_wlan_start_sta_adv for specific bssid control.

* Allow split sta/adv_sta configs.

* Add wifi_mode back for regular STA mode.

* Fix apparent bug of setting null/empty wifi key.
Reset STA_ADV_CFG.dhcp_mode in reconnect, as it seems to not survive for some reason.
Do les _CFG setting in reconnect()

* Move all _CFG setting to begin()

* Fix dhcp_mode in STA_ADV_CFG.

* Remove no longer necessary dhcp_mode re-set.

* Formatting cleanups.

* Formatting.

* Update cores/beken-72xx/arduino/libraries/WiFi/WiFiSTA.cpp

* Apply suggestions from code review

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2024-01-06 19:40:08 +01:00
Kuba Szczodrzyński
03c723c73d [docs] Add draft Beken key extraction docs 2024-01-06 19:20:03 +01:00
Gerard Du Pre
bad2ffdd07 [docs] Update docker compose image name (#225)
The docs about using docker  compose for libre tuya had an error.
When setting what image to use in compose you dont have to put docker pull, just the image you are going to use
2023-12-25 19:42:53 +01:00
Piotr Szulc
eed39c9cfb [beken-72xx] Pause PWM instead of stopping, track PWM state (#222)
* Pause PWM instead of stopping on duty cycle 0.

* Merged paused and stopped conditions
2023-12-16 13:57:47 +01:00
Piotr Szulc
7bd6d1d815 [beken-72xx] Fix stopping PWM, use pin-scoped PWM struct (#215)
* Fixed stopping PWM

* Clang-formatted as required

* Use separate memory block for each pwm pin
2023-12-08 19:20:41 +01:00
Piotr Szulc
bb7fcd5c4d [docs] Add more UPK key descriptions (#219)
* Added description of some UPK keys

* More keys described.

This time by experimenting on my PIR-enabled lamp.
Motion is reported correctly via GPIO defined as pirin_pin.
I am also trying to set the PIR sensitivity by applying PWM to the pirsense_pin, and I _think_ it works. More experiments are needed.

* Add UPK2ESPHome link, reformat table

* Add descriptions from BK7231N SDK

* Update docs/resources/tuya-pin-config.md

* Corrected description of cwmaxp

* Description of ambient light sensor values

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2023-12-08 19:13:15 +01:00
Kuba Szczodrzyński
9b8e00c7fa [boards] Support and validate MCU name aliases 2023-11-14 22:38:22 +01:00
Kuba Szczodrzyński
b97825d552 [boards] Add T112_V1.1 board, change scaling of small boards 2023-11-14 22:30:13 +01:00
Kuba Szczodrzyński
085b5aed16 [boards] Update boardgen to v0.10.1 2023-10-28 14:58:52 +02:00
protectivedad
7f43624824 [builder] Fix printing flash layout in env.py (#191)
Pointed to the proper item.
2023-10-27 13:34:09 +02:00
Kuba Szczodrzyński
1ed0000819 [release] v1.4.1
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2023-09-22 17:54:18 +02:00
Mike La Spina
3b79636d00 [libs] Fix SerialClass available() return value (#173)
Co-authored-by: descipher <120155735+GelidusResearch@users.noreply.github.com>
2023-09-21 17:19:51 +02:00
Kuba Szczodrzyński
5a4b932a37 [release] v1.4.0
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2023-09-10 19:37:52 +02:00
Kuba Szczodrzyński
dd2ae149ad [github] Move repository to libretiny-eu organization 2023-09-10 19:31:57 +02:00
Kuba Szczodrzyński
0f5d0a8889 [platform] Install ltchiptool in separate virtual environment (#166)
* [platform] Install ltchiptool in separate virtual environment

* [platform] Fix f-string syntax, set LibreTiny path in ltchiptool

* [platform] Fix venv site-packages path

* [platform] Fix installing pip without ensurepip

* [platform] Install binary dependencies only
2023-09-10 19:23:27 +02:00
Kuba Szczodrzyński
3750ae6953 [docs] Fix flashing redirect links 2023-09-02 15:20:08 +02:00
Kuba Szczodrzyński
5be993f9eb [docs] Add various redirect links for ESPHome docs 2023-09-02 15:12:12 +02:00
Kuba Szczodrzyński
57c43ce515 [libs] Fix possible MD5 memory leak in Update 2023-08-30 11:35:11 +02:00
Kuba Szczodrzyński
159ffa76fd [release] v1.3.0
Some checks failed
Release / Run Clang lint (push) Has been cancelled
Release / Publish PlatformIO platform (push) Has been cancelled
Release / Publish GitHub release (push) Has been cancelled
2023-08-29 19:21:09 +02:00
Kuba Szczodrzyński
1ac3d30d84 [libs] Implement Update MD5 2023-08-29 19:19:28 +02:00
Kuba Szczodrzyński
631ef6ba59 [github] Reuse GitHub workflows 2023-08-29 14:39:39 +02:00
Kuba Szczodrzyński
27393e47c3 [beken-72xx] Initialize UART to fix deep sleep 2023-08-23 16:08:03 +02:00
Péter Sárközi
bd47772c04 [beken-72xx] Fix GPIO deep sleep wakeup edge (#159)
Manufacturer docs: https://docs-bekencorp-com.translate.goog/sdk_3.0.x/bk7238/html/developer-guide/power_save/sleep_test.html?_x_tr_sl=auto&_x_tr_tl=en&_x_tr_hl=hu&_x_tr_pto=wapp

Discussion: https://github.com/libretiny-eu/libretiny-esphome/pull/11
2023-08-23 16:06:55 +02:00
Kuba Szczodrzyński
f3871388ce [docs] Restore feature support table 2023-08-18 13:47:06 +02:00
Ivan Kravets
62874bebf4 [misc] Fix PlatformIO repository URL (#157) 2023-08-17 19:23:10 +02:00
Kuba Szczodrzyński
2ca368305c [release] v1.2.1
Some checks failed
Lint check / Lint with clang-format (push) Has been cancelled
Lint check / Lint with black (push) Has been cancelled
PlatformIO Publish / publish (push) Has been cancelled
2023-08-17 19:04:50 +02:00
Kuba Szczodrzyński
f697ae6f11 [docs] Add migration to OpenBeken guide 2023-08-17 18:38:04 +02:00
Kuba Szczodrzyński
ef6dd35977 [docs] Rewrite flashing guides 2023-08-17 17:17:10 +02:00
Hajo Noerenberg
ccf21b4eab [realtek-ambz] Enable Mbed-TLS for MD5 hashing, remove Polar SSL (#156)
* Enable Mbed-TLS, remove Polar SSL

* Reformat lt_defs.h

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2023-08-17 15:20:02 +02:00
Kuba Szczodrzyński
e99c6124e7 [docs] Add video guide link, use ready Docker images 2023-07-13 21:19:04 +02:00
Kuba Szczodrzyński
5721bd74d7 [docs] Update LibreTiny ESPHome component naming 2023-07-13 20:41:21 +02:00
Kuba Szczodrzyński
ff443ca488 [release] v1.2.0
Some checks failed
Lint check / Lint with clang-format (push) Has been cancelled
Lint check / Lint with black (push) Has been cancelled
PlatformIO Publish / publish (push) Has been cancelled
2023-07-13 18:02:58 +02:00
Péter Sárközi
93e0a5d066 [beken-72xx] Implement deep sleep (#140)
* Initial support code for Deep Sleep

* Global functions

* Remove unnecessary override

* clang-format

* Support for multiple pins

* Fix math

* Add a way to unset GPIOs

* Clang format

* Update brief

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2023-07-13 18:00:14 +02:00
Kuba Szczodrzyński
150c2ef26d Merge branch 'family/ambz2' 2023-07-13 17:31:52 +02:00
Kuba Szczodrzyński
4d81fcac26 [realtek-ambz2] Flash bootloader & partition table in UF2 2023-07-13 17:00:42 +02:00
Kuba Szczodrzyński
a3bbdf1c16 [core] Migrate to uf2ota v5.0.0, refactor OTA API 2023-07-13 12:15:48 +02:00
Kuba Szczodrzyński
39df2e7b54 [core] Move C types to API units 2023-07-13 12:06:37 +02:00
Sonic-Amiga
6169f68119 [realtek-ambz] Improve flashing guide, add test pads for WR2 board (#147)
* platform/realtek-ambz: Improve flashing guide

Known USB adapter compatibility issues. Emphasize, so that the paragraph is
easier to notice.

Signed-off-by: Pavel Fedin <pavel_fedin@mail.ru>

* base/wr2: Add UART2 test pads to the WR2 diagram

The module has UART2, necessary for flashing, only on test pads. Document this.

Signed-off-by: Pavel Fedin <pavel_fedin@mail.ru>

* Move test pads to separate files, update variants

* Update wiring guide

---------

Signed-off-by: Pavel Fedin <pavel_fedin@mail.ru>
Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2023-07-11 11:46:36 +02:00
Kuba Szczodrzyński
e38e53bac0 [core] Split lt_api.c into separate units 2023-06-22 18:30:14 +02:00
Kuba Szczodrzyński
b38a4d5d46 [core] Add hardware peripheral availability defines 2023-06-21 17:02:48 +02:00
Kuba Szczodrzyński
96412624d9 Merge branch 'master' into family/ambz2 2023-06-21 13:35:52 +02:00
Kuba Szczodrzyński
f8876bba87 [release] v1.1.0
Some checks failed
Lint check / Lint with clang-format (push) Has been cancelled
Lint check / Lint with black (push) Has been cancelled
PlatformIO Publish / publish (push) Has been cancelled
2023-06-20 19:37:25 +02:00
Kuba Szczodrzyński
68b5773827 [core] Remove boardgen submodule, again 2023-06-20 19:28:12 +02:00
Kuba Szczodrzyński
74659901c0 [boards] Fix BW15 PCB template name 2023-06-20 19:09:46 +02:00
Kuba Szczodrzyński
73ede2838c Merge branch 'master' into family/ambz2 2023-06-20 18:53:46 +02:00
Kuba Szczodrzyński
273a86532b [beken-72xx] Add initial BK7231Q support, add WA2 board 2023-06-20 17:22:12 +02:00
Kuba Szczodrzyński
05e13dafed [beken-72xx] Rename BK7231U to BK7231T, add BK7231Q family 2023-06-20 17:19:21 +02:00
Kuba Szczodrzyński
6af97d2691 [boards] Add Tuya series 1 boards 2023-06-18 20:19:05 +02:00
Kuba Szczodrzyński
f9fb78feed [boards] Add T102 and T103 boards 2023-06-18 16:48:49 +02:00
Kuba Szczodrzyński
96dbbe0919 [boards] Move custom templates from boardgen, add WB2L_M1 board 2023-06-18 16:11:55 +02:00
Kuba Szczodrzyński
0ef66af342 [boards] Embed shielding in PCB template 2023-06-18 11:34:24 +02:00
Kuba Szczodrzyński
7ed48bf9fc [boards] Add Tuya WBLC5 and CBLC5 boards 2023-06-18 00:13:05 +02:00
Adrián Panella
1335b84391 [boards] Add Tuya CBU board (#106)
* add CBU module

* boardgen templates

These should go in boardgen package.
Included here for reference

* boardgen output

* [boards] Update for latest version of boardgen

* [boards] Change CBU silkscreen, add variant file

---------

Co-authored-by: Kuba Szczodrzyński <kuba@szczodrzynski.pl>
2023-06-17 21:25:17 +02:00
Kuba Szczodrzyński
e2794d5f84 [builder] Fix running ltchiptool with no baudrate 2023-05-31 12:38:15 +02:00
Kuba Szczodrzyński
e7f35c584b [realtek-ambz2] Reuse Log UART for Serial 2023-05-31 12:37:34 +02:00
Kuba Szczodrzyński
1e49c3ff6f [realtek-ambz2] Fix missing flash API resource lock unit 2023-05-31 12:36:46 +02:00
Kuba Szczodrzyński
e256ac8e46 [builder] Fix ltchiptool empty quotes on Windows 2023-05-30 18:49:58 +02:00
Kuba Szczodrzyński
9c6e9d1525 [realtek-ambz2] Disable SoftwareSerial and Wire 2023-05-30 18:15:44 +02:00
Kuba Szczodrzyński
41985e5743 [core] Move common flags to base.py 2023-05-29 22:26:33 +02:00
Kuba Szczodrzyński
f1e41f7cc1 [realtek-ambz2] Add GDB init command 2023-05-29 22:25:23 +02:00
Kuba Szczodrzyński
6135e4f7b0 [boards] Update flash layouts, add W302 chip 2023-05-29 16:16:58 +02:00
Kuba Szczodrzyński
af8c7417b3 [realtek-ambz2] Keep LOG UART enabled, wipe OTA2 in UF2 2023-05-28 19:18:54 +02:00
Kuba Szczodrzyński
babdb1287f [realtek-ambz2] Replace lwIP with external port 2023-05-27 20:54:40 +02:00
Kuba Szczodrzyński
4532c88873 [core] Add lt_set_debug_mode() function, update core types 2023-05-27 16:03:46 +02:00
Kuba Szczodrzyński
bc1b83d931 Merge branch 'master' into family/ambz2 2023-05-27 15:43:35 +02:00
Kuba Szczodrzyński
87ad0798e4 [realtek-ambz2] Adapt WiFi library to ambz2_sdk 2023-05-27 15:41:07 +02:00
Kuba Szczodrzyński
a80032d46c [core] Move Wiring common core to wiring/, reset watchdog in yield() 2023-05-26 15:29:33 +02:00
Kuba Szczodrzyński
4dae304f51 [core] Add lt_get_device_mac() function 2023-05-25 20:43:00 +02:00
Kuba Szczodrzyński
9b7d34fa65 [realtek-ambz2] Fix C++ support, implement SerialClass 2023-05-25 14:35:41 +02:00
Kuba Szczodrzyński
c0cc602c9a [core] Add configure() for SerialClass 2023-05-25 14:29:35 +02:00
Kuba Szczodrzyński
e5f98ff41f [core] Refactor Wiring, use PinData for parameters 2023-05-24 22:01:05 +02:00
Kuba Szczodrzyński
bc74c21599 [realtek-ambz2] Enable compilation of Arduino core 2023-05-24 13:02:33 +02:00
Kuba Szczodrzyński
3836ad20b7 [core] Refactor SerialClass as API library 2023-05-24 11:55:07 +02:00
Kuba Szczodrzyński
b073290989 [realtek-ambz2] Implement base C API 2023-05-23 19:54:00 +02:00
Kuba Szczodrzyński
43c9d0db10 [docs] Add Porting new families guide 2023-05-23 15:58:11 +02:00
Kuba Szczodrzyński
c40bdd68af [realtek-ambz2] Use external FreeRTOS port 2023-05-23 15:14:59 +02:00
Kuba Szczodrzyński
620e457eb6 [realtek-ambz2] Fix C++ linker support 2023-05-23 12:56:42 +02:00
Kuba Szczodrzyński
5c4da6e82b [core] Fix ltchiptool installation in PlatformIO 2023-05-23 12:12:42 +02:00
Kuba Szczodrzyński
8c636e44f7 [realtek-ambz2] Add initial SDK fixups and API layer 2023-05-23 12:11:17 +02:00
Kuba Szczodrzyński
07e9aa1ded [realtek-ambz2] Make compiling base core possible 2023-05-19 10:42:59 +02:00
Kuba Szczodrzyński
27a7faaab7 [core] Remove boardgen submodule 2023-05-18 22:14:58 +02:00
Kuba Szczodrzyński
752768b1e2 [docs] Update supported chip list, remove AmebaZ2 boards for now 2023-05-18 21:03:08 +02:00
Kuba Szczodrzyński
f7c28eeea4 [release] v1.0.2
Some checks failed
Lint check / Lint with clang-format (push) Has been cancelled
Lint check / Lint with black (push) Has been cancelled
PlatformIO Publish / publish (push) Has been cancelled
2023-05-11 16:20:26 +02:00
Albert Koczy
113b2fc31d [docs] Fix dead link to Boards & CPU list (#124) 2023-05-07 12:31:27 +02:00
Stroe Andrei Catalin
86924d8785 [beken-72xx] Fix delay, yet again (#116) 2023-05-01 23:28:01 +02:00
Stroe Andrei Catalin
219415174e [libs] Fix mDNS after a wifi disconnect / reconnect event (#112)
* [libs] Fix mDNS not responding when device disconnects / reconnects to wifi

* Minor bugfix

* Reworked mDNS fix

* Update LwIPmDNS.cpp
2023-05-01 21:44:03 +02:00
Stroe Andrei Catalin
8999cb9091 [beken-72xx] Fix delay macro (#114)
* [beken-72xx] Fix delay macro

* Better fix for delay
2023-05-01 21:08:01 +02:00
Kuba Szczodrzyński
8337ac121e [core] Fix reentrant malloc wrappers 2023-05-01 20:58:37 +02:00
Kuba Szczodrzyński
d332315e7a [beken-72xx] Fix WiFi compilation issue 2023-04-28 21:24:41 +02:00
Péter Sárközi
882f58bae4 [beken-72xx] Implement WiFi powersave (#111)
* Rebase

* Clang-format
2023-04-28 17:21:49 +02:00
Kuba Szczodrzyński
2c86a36fe0 [release] v1.0.1
Some checks failed
Lint check / Lint with clang-format (push) Has been cancelled
Lint check / Lint with black (push) Has been cancelled
PlatformIO Publish / publish (push) Has been cancelled
2023-04-28 14:19:21 +02:00
Kuba Szczodrzyński
b984519546 [core] Update ltchiptool to fix PlatformIO publishing 2023-04-28 14:18:51 +02:00
503 changed files with 18712 additions and 4106 deletions

View File

@@ -1,11 +1,14 @@
# 2025-02-12
Language: Cpp
BasedOnStyle: LLVM
AlignAfterOpenBracket: BlockIndent
AlignArrayOfStructures: Left
AlignConsecutiveAssignments: true
AlignConsecutiveMacros: AcrossComments
AlignEscapedNewlinesLeft: true
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: Empty
AllowShortFunctionsOnASingleLine: Empty
AlwaysBreakTemplateDeclarations: Yes
@@ -21,7 +24,7 @@ IndentCaseLabels: true
IndentWidth: 4
LambdaBodyIndentation: Signature
MaxEmptyLinesToKeep: 1
# PointerAlignment: Left # TODO enable this and reformat project
PenaltyReturnTypeOnItsOwnLine: 1000
QualifierAlignment: Left
ReflowComments: true
SeparateDefinitionBlocks: Always

View File

@@ -1,35 +0,0 @@
name: Lint check
on: [push, pull_request]
jobs:
lint-clang-format:
name: Lint with clang-format
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Check code with clang-format
uses: jidicula/clang-format-action@v4.5.0
with:
clang-format-version: "14"
lint-black:
name: Lint with black
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.9"
- name: Install test dependencies
uses: BSFishy/pip-action@v1
with:
packages: |
black
isort
- name: Check code with black
run: black --check .
- name: Check code with isort
run: isort --profile black . --check-only

View File

@@ -1,46 +0,0 @@
name: PlatformIO Publish
on:
push:
tags:
- v*.*.*
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Cache pip
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Cache PlatformIO
uses: actions/cache@v2
with:
path: ~/.platformio
key: ${{ runner.os }}-${{ hashFiles('**/lockfiles') }}
- name: Set up Python
uses: actions/setup-python@v2
- name: Install PlatformIO
run: |
python -m pip install --upgrade pip
pip install --upgrade platformio
- name: Publish PlatformIO package
run: pio package publish --non-interactive
env:
CI: true
PLATFORMIO_AUTH_TOKEN: ${{ secrets.PLATFORMIO_AUTH_TOKEN }}
- name: Get latest version
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//}
- name: Release on GitHub
uses: softprops/action-gh-release@v1
with:
name: ${{ steps.get_version.outputs.VERSION }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

13
.github/workflows/push-dev.yml vendored Normal file
View File

@@ -0,0 +1,13 @@
name: Push (dev), Pull Request
on:
push:
branches: ["**"]
pull_request:
workflow_dispatch:
jobs:
lint-clang:
name: Run Clang lint
uses: kuba2k2/kuba2k2/.github/workflows/lint-clang.yml@master
lint-python:
name: Run Python lint
uses: kuba2k2/kuba2k2/.github/workflows/lint-python.yml@master

View File

@@ -1,10 +1,8 @@
name: Deploy docs on GitHub Pages
name: Push (master)
on:
push:
branches:
- master
branches: ["master"]
workflow_dispatch:
jobs:
docs:
name: Deploy docs
@@ -19,13 +17,14 @@ jobs:
python-version: '3.10'
- name: Install docs dependencies
run: pip install -U ltchiptool boardgen
run: pip install -U ltchiptool "boardgen>=0.11.0"
- name: Generate docs and static JSON files
run: |
mkdir -p site/
boardgen ltci
python docs/scripts/update_docs.py
python docs/scripts/write_boards.py
python docs/scripts/write_apis.py
python docs/scripts/prepare_doxygen.py
python docs/scripts/build_json.py
cp *.json site/

22
.github/workflows/release.yml vendored Normal file
View File

@@ -0,0 +1,22 @@
name: Release
on:
push:
tags: ["v*.*.*"]
jobs:
lint-clang:
name: Run Clang lint
uses: kuba2k2/kuba2k2/.github/workflows/lint-clang.yml@master
publish-pio-platform:
name: Publish PlatformIO platform
needs:
- lint-clang
uses: kuba2k2/kuba2k2/.github/workflows/publish-pio-platform.yml@master
secrets:
PLATFORMIO_AUTH_TOKEN: ${{ secrets.PLATFORMIO_AUTH_TOKEN }}
gh-release:
name: Publish GitHub release
needs:
- publish-pio-platform
uses: kuba2k2/kuba2k2/.github/workflows/gh-release.yml@master
permissions:
contents: write

2
.gitignore vendored
View File

@@ -264,3 +264,5 @@ docs/status/supported_*.md
docs/status/unsupported_boards_*.md
boards/**/*.svg
boards/**/*.md
# other generated files
docs/contrib/lt-api-functions.md

View File

@@ -1,9 +1,11 @@
# LibreTiny
<small>(formerly LibreTuya)</small>
<div align="center" markdown>
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/kuba2k2/libretiny/Deploy%20docs%20on%20GitHub%20Pages?label=docs&logo=markdown)](https://kuba2k2.github.io/libretiny/)
![GitHub last commit](https://img.shields.io/github/last-commit/kuba2k2/libretiny?logo=github)
[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/libretiny-eu/libretiny/push-master.yml?label=docs&logo=markdown)](https://docs.libretiny.eu/)
![GitHub last commit](https://img.shields.io/github/last-commit/libretiny-eu/libretiny?logo=github)
[![Code style: clang-format](https://img.shields.io/badge/code%20style-clang--format-purple.svg)](.clang-format)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
@@ -13,16 +15,11 @@
![RTL8710BN](https://img.shields.io/badge/-rtl8710bn-blue)
![BK7231](https://img.shields.io/badge/-bk7231-blue)
![LN882H](https://img.shields.io/badge/-ln882h-blue)
</div>
## LibreTuya is now LibreTiny! 🎉
We have [renamed the project](https://github.com/kuba2k2/libretiny/issues/92) to LibreTiny, also marking the very first v1.0.0 release, along with a huge structure refactor. While some care has been taken to ensure that things don't break, you may still need to update some references in your code to use the new name.
---
PlatformIO development platform for IoT modules manufactured by Tuya Inc.
PlatformIO development platform for BK7231, RTL8710 and LN882H IoT chips.
The main goal of this project is to provide a usable build environment for IoT developers. While also providing vendor SDKs as PlatformIO cores,
the project focuses on developing working Arduino-compatible cores for supported families. The cores are inspired by Espressif's official core for ESP32,
@@ -32,62 +29,11 @@ which should make it easier to port/run existing ESP apps on less-common, unsupp
**Note:** this project is work-in-progress.
## Usage
<div align="center" markdown>
1. [Install PlatformIO](https://platformio.org/platformio-ide)
2. `platformio platform install -f https://github.com/kuba2k2/libretiny`
3. Create a project, build it and upload!
4. See the [docs](https://docs.libretiny.eu/) for any questions/problems.
## [⭐ Getting started ⭐](https://docs.libretiny.eu/docs/getting-started/)
<!--
## Arduino Core support status
Note: this list will probably change with each functionality update.
&nbsp; | `realtek-ambz` | `beken-72xx`
--------------------|----------------|-------------
Core functions | ✔️ | ✔️
GPIO/PWM/IRQ | ✔️/✔️/✔️ | ✔️/✔️/✔️
Analog input (ADC) | ✔️ | ✔️
Serial | ✔️ | ✔️
Serial (extra) | 0, 1, 2 | 1, 2
Flash I/O | ✔️ | ✔️
**CORE LIBRARIES** | |
SoftwareSerial | ✔️ | ❌
SPI | ❌ | ❌
Wire | ❗ | ❌
**OTHER LIBRARIES** | |
Wi-Fi STA/AP/Mixed | ✔️ | ✔️
Wi-Fi Events | ✔️ | ✔️
TCP Client (SSL) | ✔️ (✔️) | ✔️ (❗)
TCP Server | ✔️ | ✔️
IPv6 | ❌ | ❌
HTTP Client (SSL) | ✔️ (✔️) | ❓
HTTP Server | ✔️ | ✔️
NVS / Preferences | ✔️ | ✔️
SPIFFS | ❌ | ❌
BLE | - | ❌
NTP | ✔️ | ✔️
OTA | ✔️ | ✔️
MDNS | ✔️ | ✔️
MQTT | ✅ | ❌
SD | ❌ | ❌
Symbols:
- ✔️ working
- ✅ tested, external library
- ❓ untested
- ❗ broken
- ❌ not implemented (yet?)
- \- not applicable
Names:
- Core functions - stuff like delay(), millis(), yield(), etc.
- **CORE LIBRARIES** - included normally in all Arduino cores
- **OTHER LIBRARIES** - included in ESP32 core or downloadable
-->
</div>
## License

View File

@@ -1,19 +1,25 @@
* [Home](README.md)
* [](SUMMARY.md)
* [😊 Getting started](docs/getting-started/README.md)
* [➡️ Info on accessing GPIOs](docs/getting-started/gpio.md)
* [](SUMMARY.md)
* [📺 Cloudcutter & ESPHome video guide](https://www.youtube.com/watch?v=sSj8f-HCHQ0)
* [💡 ESPHome setup guide](docs/projects/esphome.md)
* [🛖 ESPHome Hassio Add-On](https://github.com/libretiny-eu/esphome-hass-addon/pkgs/container/libretiny-esphome-hassio)
* [](SUMMARY.md)
* [📲 Flashing/dumping guide](docs/flashing/)
* [🔌 How to connect the chip in download mode?](docs/flashing/chip-connection/)
* [💻 Supported chips](docs/status/supported.md)
* [🔌 How to flash/enter download mode?](docs/platform/)
* [](SUMMARY.md)
* [💻 Chips, boards, features](docs/status/supported.md)
* [All boards](boards/)
* [](SUMMARY.md)
* 🍪 Chip family docs & info
* [Beken BK72xx](docs/platform/beken-72xx/README.md)
* [Finding encryption keys](docs/platform/beken-72xx/keys.md)
* [Realtek Ameba - info](docs/platform/realtek-amb/README.md)
* [Realtek AmebaZ](docs/platform/realtek-ambz/README.md)
* [Debugging](docs/platform/realtek-ambz/debugging.md)
* [Exception decoder](docs/platform/realtek-ambz/exception-decoder.md)
* [Lightning LN882x](docs/platform/lightning-ln882x/README.md)
* [🔧 LT Configuration](docs/dev/config.md)
* 🧑 Programmer's manual
* [⚠️ Migration guide](docs/dev/migration_v1.0.0.md)
@@ -47,10 +53,13 @@
* [Macros](ltapi/macros.md)
* [File list](ltapi/files.md)
* 👷 Contributor's manual (WIP)
* [📁 Project structure](docs/dev/project-structure.md)
* [✈️ OTA format](docs/dev/ota/README.md)
* [uf2ota.py tool](docs/dev/ota/uf2ota.md)
* [uf2ota.h library](docs/dev/ota/library.md)
* [Porting new families](docs/contrib/porting.md)
* [API functions guide](docs/contrib/lt-api.md)
* [C standard library](docs/contrib/stdlib.md)
* [📁 Project structure](docs/contrib/project-structure.md)
* [✈️ OTA format](docs/contrib/ota/README.md)
* [uf2ota.py tool](docs/contrib/ota/uf2ota.md)
* [uf2ota.h library](docs/contrib/ota/library.md)
* [📓 TODO](docs/TODO.md)
* [](SUMMARY.md)
* [🔗 Resources](docs/resources/)

View File

@@ -0,0 +1,8 @@
{
"build": {
"bkcrypt_coeffs": "510fb093a3cbeadc5993a17ec7adeb03"
},
"flash": {
"tuya": "0x1ED000+0x13000"
}
}

View File

@@ -0,0 +1,10 @@
{
"build": {
"ldscript": "bk7231_bsp.ld",
"bkoffset_app": "0x10000",
"bkrbl_size_app": "0x108700"
},
"upload": {
"maximum_size": 1083136
}
}

View File

@@ -1,6 +0,0 @@
{
"build": {
"bkcrypt_coeffs": "510fb093a3cbeadc5993a17ec7adeb03",
"bkboot_version": "1.0.1-bk7231n"
}
}

View File

@@ -0,0 +1,19 @@
{
"build": {
"family": "BK7231Q",
"bkboot_version": "bk7231q"
},
"flash": {
"bootloader": "0x000000+0x11000",
"app": "0x011000+0x121000",
"download": "0x132000+0xA6000",
"kvs": "0x1D8000+0x8000",
"calibration": "0x1E0000+0x1000",
"tlv": "0x1E1000+0x1000",
"net": "0x1E2000+0x1000",
"userdata": "0x1E3000+0x1D000"
},
"upload": {
"speed": 460800
}
}

View File

@@ -1,6 +0,0 @@
{
"build": {
"bkcrypt_coeffs": "510fb093a3cbeadc5993a17ec7adeb03",
"bkboot_version": "1.0.5-bk7231s"
}
}

View File

@@ -1,10 +1,7 @@
{
"build": {
"family": "BK7231U",
"ldscript": "bk7231_bsp.ld",
"bkboot_version": "1.0.8-bk7231u",
"bkoffset_app": "0x10000",
"bkrbl_size_app": "0x108700"
"family": "BK7231T",
"bkboot_version": "1.0.5-bk7231s"
},
"flash": {
"bootloader": "0x000000+0x11000",
@@ -17,7 +14,6 @@
"userdata": "0x1E3000+0x1D000"
},
"upload": {
"maximum_size": 1083136,
"speed": 921600
},
"connectivity": [

View File

@@ -41,8 +41,7 @@
}
},
"links": {
"General info": "../../docs/platform/beken-72xx/README.md",
"Flashing guide": "../../docs/platform/beken-72xx/flashing.md"
"Info & flashing guide": "../../docs/platform/beken-72xx/README.md"
},
"extra": [
"Bootloader and app partitions contain CRC16 sums every 32 bytes. That results in the actual flash offsets/sizes not aligned to sector boundaries. To simplify calculations, the values shown in the table (extracted from bootloader's partition table) were aligned to 4096 bytes."

View File

@@ -0,0 +1,170 @@
{
"pcb": {
"ic": {
"11": {
"C_NAME": "GPIO30",
"GPIO": "P30",
"IRQ": null,
"USB": "DN"
},
"12": {
"C_NAME": "GPIO29",
"GPIO": "P29",
"IRQ": null,
"USB": "DP"
},
"14": {
"C_NAME": "GPIO6",
"GPIO": "P6",
"IRQ": null,
"PWM": 0
},
"15": {
"C_NAME": "GPIO7",
"GPIO": "P7",
"IRQ": null,
"PWM": 1
},
"16": {
"C_NAME": "GPIO8",
"GPIO": "P8",
"IRQ": null,
"PWM": 2
},
"17": {
"C_NAME": "GPIO17",
"GPIO": "P17",
"IRQ": null,
"SD": "D1",
"SPI": "MISO"
},
"18": {
"C_NAME": "GPIO16",
"GPIO": "P16",
"IRQ": null,
"SD": "D0",
"SPI": "MOSI"
},
"19": {
"C_NAME": "GPIO14",
"GPIO": "P14",
"IRQ": null,
"SD": "CLK",
"SPI": "SCK"
},
"20": {
"C_NAME": "GPIO15",
"GPIO": "P15",
"IRQ": null,
"SD": "CMD",
"SPI": "CS"
},
"21": {
"C_NAME": "GPIO19",
"GPIO": "P19",
"IRQ": null,
"SD": "D3",
"PWM": 5
},
"22": {
"C_NAME": "GPIO18",
"GPIO": "P18",
"IRQ": null,
"SD": "D2",
"PWM": 4
},
"23": {
"IO": "I",
"CTRL": "TEST"
},
"24": {
"C_NAME": "GPIO9",
"GPIO": "P9",
"IRQ": null,
"PWM": 3
},
"25": {
"C_NAME": "GPIO10",
"GPIO": "P10",
"IRQ": null,
"UART": "1_RX"
},
"26": {
"C_NAME": "GPIO11",
"GPIO": "P11",
"IRQ": null,
"UART": "1_TX"
},
"27": {
"C_NAME": "GPIO1",
"GPIO": "P1",
"IRQ": null,
"UART": "2_RX",
"I2C": "2_SDA"
},
"28": {
"C_NAME": "GPIO0",
"GPIO": "P0",
"IRQ": null,
"UART": "2_TX",
"I2C": "2_SCL"
},
"29": {
"C_NAME": "GPIO20",
"GPIO": "P20",
"IRQ": null,
"I2C": "1_SCL",
"JTAG": "TCK",
"FLASH": "FSCK"
},
"30": {
"C_NAME": "GPIO21",
"GPIO": "P21",
"IRQ": null,
"I2C": "1_SDA",
"JTAG": "TMS",
"FLASH": "^FCS"
},
"31": {
"C_NAME": "GPIO22",
"GPIO": "P22",
"IRQ": null,
"JTAG": "TDI",
"FLASH": "FSI"
},
"32": {
"C_NAME": "GPIO23",
"GPIO": "P23",
"IRQ": null,
"ADC": 3,
"JTAG": "TDO",
"FLASH": "FSO"
},
"33": {
"C_NAME": "GPIO25",
"GPIO": "P25",
"IRQ": null
},
"34": {
"C_NAME": "GPIO28",
"GPIO": "P28",
"IRQ": null
},
"35": {
"C_NAME": "GPIO4",
"GPIO": "P4",
"IRQ": null,
"ADC": 1,
"I2S": "DIN"
},
"36": {
"IO": "I",
"CTRL": "CODE"
},
"37": {
"IO": "I",
"CTRL": "CEN"
}
}
}
}

View File

@@ -103,7 +103,7 @@
"C_NAME": "GPIO19",
"GPIO": "P19",
"IRQ": null,
"SD": "D1"
"SD": "D3"
},
"31": {
"C_NAME": "GPIO17",

View File

@@ -0,0 +1,221 @@
{
"pcb": {
"ic": {
"7": {
"IO": "I",
"CTRL": "CEN"
},
"8": {
"C_NAME": "PA_0",
"GPIO": "PA00",
"IRQ": null,
"ADC": 2,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"9": {
"C_NAME": "PA_1",
"GPIO": "PA01",
"IRQ": null,
"ADC": 3,
"SWD": "DIO",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"10": {
"C_NAME": "PA_2",
"GPIO": "PA02",
"IRQ": null,
"UART": "0_TX",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"11": {
"C_NAME": "PA_3",
"GPIO": "PA03",
"IRQ": null,
"UART": "0_RX",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"12": {
"C_NAME": "PA_4",
"GPIO": "PA04",
"IRQ": null,
"ADC": 4,
"SWD": "CLK",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"13": {
"C_NAME": "PA_5",
"GPIO": "PA05",
"IRQ": null,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"14": {
"C_NAME": "PA_6",
"GPIO": "PA06",
"IRQ": null,
"SD": "D2",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"15": {
"C_NAME": "PA_7",
"GPIO": "PA07",
"IRQ": null,
"SD": "D3",
"I2S": "0_RX",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"16": {
"C_NAME": "PA_8",
"GPIO": "PA08",
"IRQ": null,
"CTRL": "BOOT0",
"SD": "CMD",
"I2S": "0_WS",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"17": {
"C_NAME": "PA_9",
"GPIO": "PA09",
"IRQ": null,
"CTRL": "BOOT1",
"SD": "CLK",
"I2S": "0_SCLK",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"21": {
"C_NAME": "PA_10",
"GPIO": "PA10",
"IRQ": null,
"SD": "D0",
"I2S": "0_TX",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"22": {
"C_NAME": "PA_11",
"GPIO": "PA11",
"IRQ": null,
"SD": "D1",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"23": {
"C_NAME": "PA_12",
"GPIO": "PA12",
"IRQ": null,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"24": {
"C_NAME": "PB_3",
"GPIO": "PB03",
"GPIONUM": 19,
"IRQ": null,
"ADC": 5,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"25": {
"C_NAME": "PB_4",
"GPIO": "PB04",
"GPIONUM": 20,
"IRQ": null,
"ADC": 6,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"26": {
"C_NAME": "PB_5",
"GPIO": "PB05",
"GPIONUM": 21,
"IRQ": null,
"ADC": 7,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"27": {
"C_NAME": "PB_6",
"GPIO": "PB06",
"GPIONUM": 22,
"IRQ": null,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"28": {
"C_NAME": "PB_7",
"GPIO": "PB07",
"GPIONUM": 23,
"IRQ": null,
"I2C": [
"0_SCL",
"0_SDA"
]
},
"29": {
"C_NAME": "PB_8",
"GPIO": "PB08",
"GPIONUM": 24,
"IRQ": null,
"UART": "1_RX",
"I2C": [
"0_SCL",
"0_SDA"
]
},
"30": {
"C_NAME": "PB_9",
"GPIO": "PB09",
"GPIONUM": 25,
"IRQ": null,
"UART": "1_TX",
"I2C": [
"0_SCL",
"0_SDA"
]
}
}
}
}

View File

@@ -0,0 +1,31 @@
{
"build": {
"family": "LN882H",
"ldscript": "ln882hki_bsp.ld",
"bootfile": "boot_ln882h.bin"
},
"flash": {
"boot": "0x000000+0x06000",
"part_tab": "0x006000+0x01000",
"app": "0x007000+0x12C000",
"ota": "0x133000+0xAA000",
"nvds": "0x1DD000+0x03000",
"kv": "0x1E0000+0x04000",
"kvs": "0x1E4000+0x08000",
"user": "0x1EC000+0x14000"
},
"upload": {
"flash_size": 2097152,
"maximum_size": 1228800
},
"connectivity": [
"ble"
],
"doc": {
"params": {
"extra": {
"Bluetooth": "BLE v5.1"
}
}
}
}

View File

@@ -0,0 +1,43 @@
{
"build": {
"f_cpu": "160000000L",
"prefix": "arm-none-eabi-"
},
"flash": {},
"connectivity": [
"wifi"
],
"debug": {
"protocol": "openocd",
"protocols": [
"openocd"
],
"openocd_config": "ln882x.cfg",
"gdb_init": [
"mem 0x00000000 0x10000000 ro"
]
},
"upload": {
"maximum_ram_size": 302080,
"require_upload_port": true,
"speed": 115200,
"protocol": "uart",
"protocols": [
"uart"
]
},
"doc": {
"params": {
"manufacturer": "Lightning",
"series": "LN882X",
"voltage": "3.0V - 3.6V",
"extra": {
"Wi-Fi": "802.11 b/g/n"
}
},
"links": {
"Info & flashing guide": "../../docs/platform/lightning-ln882x/README.md",
"Debugging": "../../docs/platform/lightning-ln882x/debugging.md"
}
}
}

View File

@@ -0,0 +1,90 @@
{
"pcb": {
"templates": [
"99iot-21p",
"pcb-blue-light",
"rf-type1"
],
"scale": 16,
"vars": {
"TRACE_COLOR": "#FAFD9D"
},
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {
"GND": null
},
"2": {
"CTRL": "RF_O"
},
"3": {
"GND": null
},
"4": {
"NC": null
},
"5": {
"CTRL": "CEN"
},
"6": {
"IC": 13,
"ARD": "D0"
},
"7": {
"IC": 14,
"ARD": "D1"
},
"8": {
"IC": 16,
"ARD": "D2"
},
"9": {
"IC": 17,
"ARD": "D3"
},
"10": {
"GND": null
},
"11": {
"PWR": 3.3
},
"12": {
"GND": null
},
"13": {
"NC": null
},
"14": {
"IC": 28,
"ARD": "D5"
},
"15": {
"IC": 29,
"ARD": "D6"
},
"16": {
"IC": 30,
"ARD": "D7"
},
"17": {
"IC": 31,
"ARD": "D8"
},
"18": {
"IC": 32,
"ARD": "D9"
},
"19": {
"IC": 1,
"ARD": "D10"
},
"20": {
"IC": 2,
"ARD": "D4"
},
"21": {
"GND": null
}
}
}
}

View File

@@ -2,14 +2,11 @@
"pcb": {
"templates": [
"esp12s",
"esp12s-shield",
"rf-16mm-type1"
"pcb-black",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_black",
"TRACE_COLOR": "#FAFD9D",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole"
"TRACE_COLOR": "#FAFD9D"
},
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {

View File

@@ -2,15 +2,9 @@
"pcb": {
"templates": [
"esp12s",
"esp12s-shield",
"rf-16mm-type1"
"pcb-black",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_black",
"TRACE_COLOR": "#FAFD9D",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole"
},
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {

View File

@@ -0,0 +1,69 @@
{
"pcb": {
"scale": 14,
"test_pads": {
"TSCK": "cb1s.back.sck.anchor",
"TCSN": "cb1s.back.csn.anchor",
"TSI": "cb1s.back.si.anchor",
"TSO": "cb1s.back.so.anchor"
},
"back": [
{
"name": "test_pad_1mm",
"pos": "2.66,14.4"
},
{
"name": "test_pad_1mm",
"pos": "2.66,15.9"
},
{
"name": "test_pad_1mm",
"pos": "2.66,17.4"
},
{
"name": "test_pad_1mm",
"pos": "2.66,18.9"
},
{
"id": "sck",
"name": "label_line_down",
"pos": "3.5,14.3",
"vars": {
"DIR": "right",
"W": 1.0,
"H": 0
}
},
{
"id": "csn",
"name": "label_line_down",
"pos": "3.5,15.8",
"vars": {
"DIR": "right",
"W": 1.0,
"H": 0
}
},
{
"id": "si",
"name": "label_line_down",
"pos": "3.5,17.3",
"vars": {
"DIR": "right",
"W": 1.0,
"H": 0
}
},
{
"id": "so",
"name": "label_line_down",
"pos": "3.5,18.8",
"vars": {
"DIR": "right",
"W": 1.0,
"H": 0
}
}
]
}
}

101
boards/_base/pcb/cb1s.json Normal file
View File

@@ -0,0 +1,101 @@
{
"pcb": {
"templates": [
"tuya1",
"pcb-blue-light",
"tuya-16x24",
"rf-type1"
],
"scale": 15,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {
"PWR": "VCC5"
},
"2": {
"IC": 27,
"ARD": "D0"
},
"3": {
"IC": 26,
"ARD": "D1"
},
"4": {
"PWR": 3.3
},
"5": {
"GND": null
},
"6": {
"IC": 22,
"ARD": "D2"
},
"7": {
"IC": 23,
"ARD": "D3"
},
"8": {
"IC": 29,
"ARD": "D4"
},
"9": {
"IC": 25,
"ARD": "D5"
},
"10": {
"IC": 24,
"ARD": "D6"
},
"11": {
"IC": 28,
"ARD": "D7"
},
"12": {
"IC": 16,
"ARD": "D8"
},
"13": {
"IC": 15,
"ARD": "D9"
},
"14": {
"GND": null
},
"15": {
"GND": null
},
"16": {
"IC": 21
},
"17": {
"IC": 17,
"ARD": [
"D10",
"A0"
]
},
"18": {
"GND": null
},
"TSCK": {
"IC": 20,
"ARD": "D11"
},
"TCSN": {
"IC": 19,
"ARD": "D12"
},
"TSO": {
"IC": 17,
"ARD": [
"D10",
"A0"
]
},
"TSI": {
"IC": 18,
"ARD": "D13"
}
}
}
}

View File

@@ -1,6 +1,5 @@
{
"pcb": {
"scale": 11,
"test_pads": {
"TRST": "cb2l.back.rst.anchor",
"TRX1": "cb2l.back.u1_rxd.anchor",
@@ -10,26 +9,12 @@
"TCSN": "cb2l.back.f_csn.anchor"
},
"back": [
{
"type": "rect",
"pos": "0,0",
"size": "15,17.3",
"preset": "${MASK_PRESET}"
},
{
"name": "pins_horz7_2mm_0.7mm",
"pos": "1.15,17.3",
"vars": {
"PINTYPE": "${PINTYPE_HORZ}",
"PINDIR": "down"
}
},
{
"name": "test_pad_1mm",
"pos": "1.5,7.5"
},
{
"name": "label_line_2mm_down",
"name": "label_line_down",
"pos": "0.4,4.7",
"vars": {
"DIR": "right",
@@ -51,7 +36,7 @@
},
{
"id": "u2_txd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "2.2,5.1",
"vars": {
"DIR": "left",
@@ -65,7 +50,7 @@
},
{
"id": "u1_txd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "4.0,5.1",
"vars": {
"DIR": "left",
@@ -79,7 +64,7 @@
},
{
"id": "gnd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "9.2,5.1",
"vars": {
"DIR": "left",
@@ -93,7 +78,7 @@
},
{
"id": "rst",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "2.2,9.9",
"vars": {
"DIR": "left",
@@ -107,7 +92,7 @@
},
{
"id": "f_csn",
"name": "label_line_2mm_down",
"name": "label_line_down",
"pos": "2.2,12.8",
"vars": {
"DIR": "left",

View File

@@ -2,15 +2,9 @@
"pcb": {
"templates": [
"tuya2l",
"rf-15mm-type1",
"tuya2l-shield"
"pcb-white",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_white",
"TRACE_COLOR": "#E0E0E0",
"SILK_COLOR": "black",
"PINTYPE_HORZ": "pin_horz_2mm_cast_hole"
},
"pinout_hidden": "I2S,I2C,JTAG,FLASH",
"pinout": {
"1": {

View File

@@ -1,6 +1,5 @@
{
"pcb": {
"scale": 11,
"test_pads": {
"TTX2": "cb2s.back.u2_txd.anchor",
"TRX2": "cb2s.back.u2_rxd.anchor",
@@ -15,7 +14,7 @@
},
{
"id": "u2_txd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "6.7,6.1",
"vars": {
"DIR": "left",
@@ -29,7 +28,7 @@
},
{
"id": "u2_rxd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "6.2,8.1",
"vars": {
"DIR": "left",
@@ -43,7 +42,7 @@
},
{
"id": "csn",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "4.2,11.1",
"vars": {
"DIR": "left",

View File

@@ -2,14 +2,9 @@
"pcb": {
"templates": [
"tuya2",
"rf-15mm-type1",
"tuya2-shield"
"pcb-blue-light",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white"
},
"pinout_hidden": "I2S,JTAG,FLASH",
"pinout": {
"1": {

View File

@@ -2,16 +2,12 @@
"pcb": {
"templates": [
"esp12s",
"esp12e-shield",
"pcb-white",
"tuya-16x24",
"rf-16mm-type1"
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_hole",
"PINTYPE_HORZ": "pin_horz_2mm_cast_hole"
"PINHOLE": 1
},
"pinout_hidden": "I2S,SD,SPI,I2C,JTAG,FLASH",
"pinout": {

View File

@@ -2,16 +2,12 @@
"pcb": {
"templates": [
"esp12e-22",
"esp12e-shield-nohole",
"pcb-blue-light",
"tuya-16x24",
"rf-16mm-type1"
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole",
"PINTYPE_HORZ": "pin_horz_2mm_cast_nohole"
"PINHOLE": 0
},
"pinout_hidden": "I2S,SD,SPI,SCL2",
"pinout": {

View File

@@ -2,16 +2,12 @@
"pcb": {
"templates": [
"esp12e-22",
"esp12e-shield-nohole",
"pcb-blue-light",
"tuya-16x24",
"rf-16mm-type1"
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole",
"PINTYPE_HORZ": "pin_horz_2mm_cast_nohole"
"PINHOLE": 0
},
"pinout_hidden": "I2S,SD,JTAG,FLASH,SCL1",
"pinout": {

View File

@@ -0,0 +1,104 @@
{
"pcb": {
"test_pads": {
"TRST": "cblc5.back.rst.anchor",
"TRX1": "cblc5.back.r1.anchor",
"TTX1": "cblc5.back.t1.anchor",
"TRX2": "cblc5.back.r2.anchor",
"TTX2": "cblc5.back.t2.anchor",
"TCSN": "cblc5.back.csn.anchor"
},
"back": [
{
"name": "test_pad_1mm",
"pos": "1.1,1.1"
},
{
"id": "t1",
"name": "label_line_up",
"pos": "1.1,0.6",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 3.8,
"H": 1.4
}
},
{
"name": "test_pad_1mm",
"pos": "0.8,3.3"
},
{
"id": "r1",
"name": "label_line_up",
"pos": "0.8,2.8",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 4.1,
"H": 1.6
}
},
{
"name": "test_pad_1mm",
"pos": "2.4,4.1"
},
{
"id": "r2",
"name": "label_line_up",
"pos": "2.4,3.6",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 2.5,
"H": 0.4
}
},
{
"name": "test_pad_1mm",
"pos": "3.9,4.1"
},
{
"id": "t2",
"name": "label_line_down",
"pos": "3.9,4.6",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 1,
"H": 0.4
}
},
{
"name": "test_pad_1mm",
"pos": "1.2,4.9"
},
{
"name": "test_pad_1mm",
"pos": "1.7,7.0"
},
{
"id": "rst",
"name": "label_line_down",
"pos": "1.2,5.4",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 3.7,
"H": 1.6
}
},
{
"id": "csn",
"name": "label_line_down",
"pos": "1.7,7.5",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 3.2,
"H": 1.5
}
}
]
}
}

View File

@@ -0,0 +1,78 @@
{
"pcb": {
"templates": [
"tuyalc5",
"pcb-white"
],
"pinout_hidden": "I2S,JTAG,FLASH,SDA1",
"pinout": {
"1": {
"CTRL": "ANT"
},
"2": {
"GND": null
},
"3": {
"IC": 16,
"ARD": "D0"
},
"4": {
"IC": 15,
"ARD": "D2"
},
"5": {
"IC": 22,
"ARD": "D1"
},
"6": {
"PWR": 3.3
},
"TRST": {
"IC": 21
},
"TRX1": {
"IC": 26,
"ARD": "D4"
},
"TTX1": {
"IC": 27,
"ARD": "D3"
},
"TRX2": {
"IC": 28,
"ARD": "D5"
},
"TTX2": {
"IC": 29,
"ARD": "D6"
},
"TCSN": {
"IC": 19,
"ARD": "D7"
}
},
"front": [
{
"name": "chip",
"pos": "2.7,3.8",
"vars": {
"W": 5,
"POS": 1
}
},
{
"name": "osc",
"pos": "2.5,0.5"
},
{
"type": "text",
"pos": "0.7,4.2",
"text": "${SYMBOL}",
"font_size": 1.2,
"fill": {
"color": "${SILK_COLOR}"
}
}
]
}
}

View File

@@ -0,0 +1,30 @@
{
"pcb": {
"test_pads": {
"TCSN": "cbu.back.csn.anchor"
},
"back": [
{
"type": "rect",
"pos": "6.3,11.6",
"size": "2.9,2.9",
"preset": "copper1"
},
{
"id": "csn",
"name": "label_line_up",
"pos": "3.7,13.5",
"vars": {
"DIR": "left",
"RASTER": 2,
"W": 0,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "4.4,13.4"
}
]
}
}

100
boards/_base/pcb/cbu.json Normal file
View File

@@ -0,0 +1,100 @@
{
"pcb": {
"templates": [
"tuyau",
"pcb-white",
"rf-type1"
],
"pinout_hidden": "I2S,USB,SD,FLASH",
"pinout": {
"1": {
"IC": 11,
"ARD": "D0"
},
"2": {
"IC": 12,
"ARD": "D1"
},
"3": {
"IC": 20,
"ARD": "D2"
},
"4": {
"IC": 18,
"ARD": "D3"
},
"5": {
"IC": 17,
"ARD": [
"D4",
"A0"
]
},
"6": {
"IC": 28,
"ARD": "D5"
},
"7": {
"IC": 29,
"ARD": "D6"
},
"8": {
"IC": 24,
"ARD": "D7"
},
"9": {
"IC": 23,
"ARD": "D8"
},
"10": {
"IC": 22,
"ARD": "D9"
},
"11": {
"IC": 15,
"ARD": "D10"
},
"12": {
"IC": 16,
"ARD": "D11"
},
"13": {
"GND": null
},
"14": {
"PWR": 3.3
},
"15": {
"IC": 27,
"ARD": "D12"
},
"16": {
"IC": 26,
"ARD": "D13"
},
"17": {
"IC": 10,
"ARD": "D14"
},
"18": {
"IC": 21
},
"19": {
"IC": 25,
"ARD": "D15"
},
"20": {
"IC": 14,
"ARD": "D16"
},
"21": {
"IC": 13,
"ARD": "D17"
},
"TCSN": {
"IC": 19,
"ARD": "D18"
}
}
}
}

View File

@@ -0,0 +1,23 @@
{
"pcb": {
"test_pads": {
"TBOOT": "ln-02.back.boot.anchor"
},
"back": [
{
"id": "boot",
"name": "label_line_up",
"pos": "12,12.1",
"vars": {
"DIR": "right",
"W": 2.5,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "11,12"
}
]
}
}

View File

@@ -0,0 +1,67 @@
{
"pcb": {
"templates": [
"tuya2",
"pcb-black",
"rf-type1"
],
"scale": 10.5,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD,SPI,I2C",
"pinout": {
"1": {
"PWR": 3.3
},
"2": {
"IC": 22,
"ARD": "D0"
},
"3": {
"GND": null
},
"4": {
"IC": 24,
"ARD": [
"D1",
"A0"
]
},
"5": {
"IC": 11,
"ARD": "D2"
},
"6": {
"IC": 29,
"ARD": "D3"
},
"7": {
"IC": 10,
"ARD": "D4"
},
"8": {
"IC": 30,
"ARD": "D5"
},
"9": {
"IC": 9,
"ARD": [
"D6",
"A1"
]
},
"10": {
"IC": 7
},
"11": {
"IC": 8,
"ARD": [
"D7",
"A2"
]
},
"TBOOT": {
"IC": 17,
"ARD": "D8"
}
}
}
}

View File

@@ -2,15 +2,9 @@
"pcb": {
"templates": [
"custom-20x24-22",
"rf-20mm-type1"
"pcb-blue-light",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole",
"PINTYPE_HORZ": "pin_horz_2mm_cast_nohole"
},
"pinout_hidden": "I2S,JTAG,FLASH,SD,SPI,SDA1",
"pinout": {
"1": {

View File

@@ -0,0 +1,56 @@
{
"pcb": {
"templates": [
"tuya2",
"pcb-black",
"rf-type1"
],
"scale": 10.5,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"drawing_hidden": "SPI",
"pinout": {
"1": {
"PWR": 3.3
},
"2": {
"IC": 17,
"ARD": "D0"
},
"3": {
"GND": null
},
"4": {
"IC": 16,
"ARD": "D1"
},
"5": {
"IC": 29,
"ARD": "D5"
},
"6": {
"IC": 28,
"ARD": "D2"
},
"7": {
"IC": 32,
"ARD": "D6"
},
"8": {
"IC": 1,
"ARD": "D3"
},
"9": {
"IC": 13,
"ARD": "D7"
},
"10": {
"IC": 2,
"ARD": "D4"
},
"11": {
"IC": 14,
"ARD": "D8"
}
}
}
}

View File

@@ -0,0 +1,79 @@
{
"pcb": {
"templates": [
"esp12s",
"pcb-white",
"tuya-16x24",
"rf-type1"
],
"vars": {
"PINHOLE": 1
},
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {
"NC": null
},
"2": {
"IC": 27,
"ARD": "A1"
},
"3": {
"IC": 12
},
"4": {
"IC": 30,
"ARD": [
"D0",
"A0"
]
},
"5": {
"IC": 13,
"ARD": "D1"
},
"6": {
"IC": 14,
"ARD": "D2"
},
"7": {
"IC": 16,
"ARD": "D3"
},
"8": {
"PWR": 3.3
},
"9": {
"GND": null
},
"10": {
"IC": 31,
"ARD": "D4"
},
"11": {
"IC": 2,
"ARD": "D5"
},
"12": {
"IC": 1,
"ARD": "D6"
},
"13": {
"IC": 28,
"ARD": "D7"
},
"14": {
"IC": 17,
"ARD": "D8"
},
"15": {
"IC": 29,
"ARD": "D9"
},
"16": {
"IC": 32,
"ARD": "D10"
}
}
}
}

View File

@@ -0,0 +1,70 @@
{
"pcb": {
"templates": [
"esp01m-14",
"pcb-blue-light",
"rf-type1"
],
"scale": 10.5,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"drawing_hidden": "I2C,SPI",
"pinout": {
"1": {
"PWR": 3.3
},
"2": {
"IC": 2,
"ARD": "D0"
},
"3": {
"IC": 30,
"ARD": [
"D1",
"A0"
]
},
"4": {
"IC": 14,
"ARD": "D2"
},
"5": {
"IC": 13,
"ARD": "D3"
},
"6": {
"IC": 16,
"ARD": "D4"
},
"7": {
"NC": null
},
"8": {
"IC": 28,
"ARD": "D5"
},
"9": {
"IC": 29,
"ARD": "D6"
},
"10": {
"IC": 17,
"ARD": "D7"
},
"11": {
"IC": 32,
"ARD": "D8"
},
"12": {
"IC": 31,
"ARD": "D9"
},
"13": {
"IC": 1,
"ARD": "D10"
},
"14": {
"GND": null
}
}
}
}

View File

@@ -0,0 +1,143 @@
{
"pcb": {
"test_pads": {
"TTEST": "wa2.back.test.anchor",
"TTX2": "wa2.back.2tx.anchor",
"TGND": "wa2.back.gnd.anchor",
"TSCK": "wa2.back.sck.anchor",
"TCSN": "wa2.back.csn.anchor",
"TSI": "wa2.back.si.anchor",
"TSO": "wa2.back.so.anchor",
"TP4": "wa2.back.p4.anchor",
"TVCC": "wa2.back.vbat.anchor"
},
"back": [
{
"name": "test_pad_1mm",
"pos": "2.6,6.2"
},
{
"id": "sck",
"name": "label_line_up",
"pos": "2.6,5.4",
"vars": {
"DIR": "left",
"W": 1.3,
"H": 2
}
},
{
"name": "test_pad_1mm",
"pos": "4.6,6.2"
},
{
"id": "so",
"name": "label_line_up",
"pos": "4.6,5.4",
"vars": {
"DIR": "left",
"W": 3.3,
"H": 4
}
},
{
"name": "test_pad_1mm",
"pos": "7.0,6.2"
},
{
"id": "p4",
"name": "label_line_up",
"pos": "7.0,5.4",
"vars": {
"DIR": "right",
"W": 0,
"H": 4
}
},
{
"name": "test_pad_1mm",
"pos": "3.0,8.3"
},
{
"id": "csn",
"name": "label_line_up",
"pos": "2.2,8.4",
"vars": {
"DIR": "left",
"W": 0.9,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "5.2,8.8"
},
{
"id": "si",
"name": "label_line_up",
"pos": "6.0,8.9",
"vars": {
"DIR": "right",
"W": 1,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "2.1,11.6"
},
{
"id": "2tx",
"name": "label_line_up",
"pos": "1.3,11.7",
"vars": {
"DIR": "left",
"W": 0,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "4.3,11.6"
},
{
"id": "test",
"name": "label_line_up",
"pos": "5.1,11.7",
"vars": {
"DIR": "right",
"W": 1.9,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "2.5,14.5"
},
{
"id": "vbat",
"name": "label_line_up",
"pos": "1.7,14.6",
"vars": {
"DIR": "left",
"W": 0.4,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "4.8,14.5"
},
{
"id": "gnd",
"name": "label_line_up",
"pos": "5.6,14.6",
"vars": {
"DIR": "right",
"W": 1.4,
"H": 0
}
}
]
}
}

93
boards/_base/pcb/wa2.json Normal file
View File

@@ -0,0 +1,93 @@
{
"pcb": {
"scale": 11,
"templates": [
"tuya2",
"pcb-blue-light",
"rf-type1"
],
"pinout_hidden": "I2S,SD",
"pinout": {
"1": {
"PWR": 3.3
},
"2": {
"IC": 16,
"ARD": "D0"
},
"3": {
"GND": null
},
"4": {
"IC": 15,
"ARD": "D1"
},
"5": {
"IC": 25,
"ARD": "D4"
},
"6": {
"IC": 14,
"ARD": "D2"
},
"7": {
"IC": 26,
"ARD": "D5"
},
"8": {
"IC": 32,
"ARD": [
"D3",
"A0"
]
},
"9": {
"IC": 22,
"ARD": "D6"
},
"10": {
"IC": 37
},
"11": {
"IC": 21,
"ARD": "D7"
},
"TSCK": {
"IC": 29,
"ARD": "D8"
},
"TP4": {
"IC": 35,
"ARD": "D9"
},
"TTEST": {
"IC": 23
},
"TTX2": {
"IC": 28,
"ARD": "D10"
},
"TCSN": {
"IC": 30,
"ARD": "D11"
},
"TSI": {
"IC": 31,
"ARD": "D12"
},
"TSO": {
"IC": 32,
"ARD": [
"D3",
"A0"
]
},
"TVCC": {
"PWR": 3.3
},
"TGND": {
"GND": null
}
}
}
}

View File

@@ -0,0 +1,93 @@
{
"pcb": {
"test_pads": {
"TA9": "wb02a.back.a9.anchor",
"TGND": "wb02a.back.gnd.anchor",
"TRX1": "wb02a.back.rx1.anchor",
"TTX1": "wb02a.back.tx1.anchor"
},
"back": [
{
"type": "text",
"pos": "0.5,2.3",
"text": "WB02A-0882H-1518D1",
"font_size": 1.4,
"fill": {
"color": "${SILK_COLOR}"
}
},
{
"type": "circle",
"pos": "11.6,6.4",
"d": 4.5,
"preset": "copper1"
},
{
"type": "rect",
"pos": "3.5,8.5",
"size": "4.2,3.7",
"preset": "copper1"
},
{
"id": "a9",
"name": "label_line_up",
"pos": "1.9,12.3",
"vars": {
"DIR": "left",
"W": 1.3,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "2.5,12.3"
},
{
"id": "gnd",
"name": "label_line_up",
"pos": ".6,6.6",
"vars": {
"DIR": "left",
"W": 0,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "1.2,6.6"
},
{
"id": "rx1",
"name": "label_line_up",
"pos": "3.2,6",
"vars": {
"DIR": "left",
"W": 2.6,
"H": 1.4
}
},
{
"name": "test_pad_1mm",
"pos": "3.2,6.6"
},
{
"id": "tx1",
"name": "label_line_up",
"pos": "5.2,6",
"vars": {
"DIR": "left",
"W": 4.6,
"H": 3.4
}
},
{
"name": "test_pad_1mm",
"pos": "5.2,6.6"
},
{
"name": "test_pad_1mm",
"pos": "8.5,12.3"
}
]
}
}

View File

@@ -0,0 +1,75 @@
{
"pcb": {
"templates": [
"tuya2",
"pcb-blue-light",
"rf-type1"
],
"scale": 10.5,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD,SPI,I2C",
"pinout": {
"1": {
"PWR": 3.3
},
"2": {
"IC": 15,
"ARD": "D0"
},
"3": {
"GND": null
},
"4": {
"IC": 13,
"ARD": "D1"
},
"5": {
"IC": 11,
"ARD": "D2"
},
"6": {
"IC": 21,
"ARD": "D3"
},
"7": {
"IC": 10,
"ARD": "D4"
},
"8": {
"IC": 9,
"ARD": [
"D5",
"A0"
]
},
"9": {
"IC": 12,
"ARD": [
"D6",
"A1"
]
},
"10": {
"IC": 7
},
"11": {
"IC": 13,
"ARD": "D1"
},
"TA9": {
"IC": 17,
"ARD": "D7"
},
"TGND": {
"GND": null
},
"TRX1": {
"IC": 29,
"ARD": "D8"
},
"TTX1": {
"IC": 30,
"ARD": "D9"
}
}
}
}

View File

@@ -0,0 +1,99 @@
{
"pcb": {
"templates": [
"tuya1",
"tuya1s",
"pcb-blue-light",
"tuya-16x24",
"rf-type1"
],
"scale": 15,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {
"PWR": "VCC5"
},
"2": {
"IC": 27,
"ARD": "D0"
},
"3": {
"IC": 26,
"ARD": "D1"
},
"4": {
"PWR": 3.3
},
"5": {
"GND": null
},
"6": {
"IC": 15,
"ARD": "D2"
},
"7": {
"IC": 16,
"ARD": "D3"
},
"8": {
"IC": 29,
"ARD": "D4"
},
"9": {
"IC": 24,
"ARD": "D5"
},
"10": {
"IC": 23,
"ARD": "D6"
},
"11": {
"IC": 28,
"ARD": "D7"
},
"12": {
"IC": 25,
"ARD": "D8"
},
"13": {
"IC": 22,
"ARD": "D9"
},
"14": {
"GND": null
},
"15": {
"GND": null
},
"16": {
"IC": 21
},
"17": {
"IC": 17,
"ARD": [
"D10",
"A0"
]
},
"18": {
"GND": null
},
"19": {
"IC": 17,
"ARD": [
"D10",
"A0"
]
},
"20": {
"IC": 18
},
"21": {
"IC": 19
},
"22": {
"IC": 20
}
}
}
}

View File

@@ -0,0 +1,16 @@
{
"pcb": {
"test_pads": {
"TRST": "wb2l-m1.back.rst.anchor",
"TRX1": "wb2l-m1.back.u1_rxd.anchor",
"TTX1": "wb2l-m1.back.u1_txd.anchor",
"TRX2": "wb2l-m1.back.u2_rxd.anchor",
"TTX2": "wb2l-m1.back.u2_txd.anchor",
"TGND": "wb2l-m1.back.gnd.anchor",
"TSCK": "wb2l-m1.back.f_sck.anchor",
"TCSN": "wb2l-m1.back.f_csn.anchor",
"TSI": "wb2l-m1.back.f_si.anchor",
"TSO": "wb2l-m1.back.f_so.anchor"
}
}
}

View File

@@ -1,6 +1,5 @@
{
"pcb": {
"scale": 11,
"test_pads": {
"TRST": "wb2l.back.rst.anchor",
"TRX1": "wb2l.back.u1_rxd.anchor",
@@ -14,26 +13,12 @@
"TSO": "wb2l.back.f_so.anchor"
},
"back": [
{
"type": "rect",
"pos": "0,0",
"size": "15,17.3",
"preset": "${MASK_PRESET}"
},
{
"name": "pins_horz7_2mm_0.7mm",
"pos": "1.15,17.3",
"vars": {
"PINTYPE": "${PINTYPE_HORZ}",
"PINDIR": "down"
}
},
{
"name": "test_pad_1mm",
"pos": "1.5,7.5"
},
{
"name": "label_line_2mm_down",
"name": "label_line_down",
"pos": "0.4,4.7",
"vars": {
"DIR": "right",
@@ -55,7 +40,7 @@
},
{
"id": "u1_rxd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "2.2,5.1",
"vars": {
"DIR": "left",
@@ -69,7 +54,7 @@
},
{
"id": "u1_txd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "4.0,5.1",
"vars": {
"DIR": "left",
@@ -83,7 +68,7 @@
},
{
"id": "u2_rxd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "5.7,5.1",
"vars": {
"DIR": "left",
@@ -97,7 +82,7 @@
},
{
"id": "u2_txd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "7.3,5.1",
"vars": {
"DIR": "left",
@@ -111,7 +96,7 @@
},
{
"id": "gnd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "9.2,5.1",
"vars": {
"DIR": "left",
@@ -125,7 +110,7 @@
},
{
"id": "f_sck",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "2.2,9.9",
"vars": {
"DIR": "left",
@@ -139,7 +124,7 @@
},
{
"id": "f_csn",
"name": "label_line_2mm_down",
"name": "label_line_down",
"pos": "2.2,12.8",
"vars": {
"DIR": "left",
@@ -153,7 +138,7 @@
},
{
"id": "f_so",
"name": "label_line_2mm_down",
"name": "label_line_down",
"pos": "3.5,14.3",
"vars": {
"DIR": "left",
@@ -167,7 +152,7 @@
},
{
"id": "f_si",
"name": "label_line_2mm_down",
"name": "label_line_down",
"pos": "5.2,14.3",
"vars": {
"DIR": "left",

View File

@@ -2,15 +2,9 @@
"pcb": {
"templates": [
"tuya2l",
"rf-15mm-type1",
"tuya2l-shield"
"pcb-white",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_white",
"TRACE_COLOR": "#E0E0E0",
"SILK_COLOR": "black",
"PINTYPE_HORZ": "pin_horz_2mm_cast_hole"
},
"pinout_hidden": "I2S",
"pinout": {
"1": {
@@ -43,7 +37,7 @@
"GND": null
},
"TRST": {
"CTRL": "^RST"
"IC": 21
},
"TRX1": {
"IC": 26,

View File

@@ -19,7 +19,7 @@
},
{
"id": "sck",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "2.6,5.4",
"vars": {
"DIR": "left",
@@ -33,7 +33,7 @@
},
{
"id": "pwm3",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "4.6,5.4",
"vars": {
"DIR": "left",
@@ -47,7 +47,7 @@
},
{
"id": "2rx",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "7.0,5.4",
"vars": {
"DIR": "right",
@@ -61,7 +61,7 @@
},
{
"id": "2tx",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "9.0,5.4",
"vars": {
"DIR": "right",
@@ -75,7 +75,7 @@
},
{
"id": "csn",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "2.2,8.4",
"vars": {
"DIR": "left",
@@ -89,7 +89,7 @@
},
{
"id": "si",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "6.0,8.9",
"vars": {
"DIR": "right",
@@ -103,7 +103,7 @@
},
{
"id": "adc_so",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "1.3,11.7",
"vars": {
"DIR": "left",
@@ -117,7 +117,7 @@
},
{
"id": "cen",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "5.1,11.7",
"vars": {
"DIR": "right",
@@ -131,7 +131,7 @@
},
{
"id": "vbat",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "1.7,14.6",
"vars": {
"DIR": "left",
@@ -145,7 +145,7 @@
},
{
"id": "gnd",
"name": "label_line_2mm_up",
"name": "label_line_up",
"pos": "5.6,14.6",
"vars": {
"DIR": "right",

View File

@@ -1,16 +1,10 @@
{
"pcb": {
"scale": 10.5,
"templates": [
"tuya2",
"rf-15mm-type1",
"tuya2-shield"
"pcb-blue-light",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white"
},
"pinout_hidden": "I2S,FLASH",
"pinout": {
"1": {

View File

@@ -2,18 +2,14 @@
"pcb": {
"templates": [
"esp12e-21",
"esp12e-shield-nohole",
"pcb-white",
"tuya-16x24",
"rf-16mm-type1"
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_white",
"TRACE_COLOR": "#E0E0E0",
"SILK_COLOR": "black",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole",
"PINTYPE_HORZ": "pin_horz_2mm_cast_nohole"
"PINHOLE": 0
},
"pinout_hidden": "I2S,SD,SPI",
"pinout_hidden": "I2S,SD",
"pinout": {
"1": {
"NC": null

View File

@@ -2,16 +2,12 @@
"pcb": {
"templates": [
"esp12e-22",
"esp12e-shield-nohole",
"pcb-blue-light",
"tuya-16x24",
"rf-16mm-type1"
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole",
"PINTYPE_HORZ": "pin_horz_2mm_cast_nohole"
"PINHOLE": 0
},
"pinout_hidden": "I2S,SD,SPI",
"pinout": {

View File

@@ -0,0 +1,152 @@
{
"pcb": {
"test_pads": {
"TRST": "wblc5.back.cen.anchor",
"TRX1": "wblc5.back.r1.anchor",
"TTX1": "wblc5.back.t1.anchor",
"TRX2": "wblc5.back.r2.anchor",
"TTX2": "wblc5.back.t2.anchor",
"TSCK": "wblc5.back.tck.anchor",
"TCSN": "wblc5.back.tms.anchor",
"TSI": "wblc5.back.tdi.anchor",
"TSO": "wblc5.back.tdo.anchor"
},
"back": [
{
"name": "test_pad_1mm",
"pos": "0.7,1.1"
},
{
"id": "r1",
"name": "label_line_up",
"pos": "0.7,0.6",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 7.2,
"H": 5.1
}
},
{
"name": "test_pad_1mm",
"pos": "1.9,0.9"
},
{
"id": "t1",
"name": "label_line_up",
"pos": "1.9,0.4",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 5.9,
"H": 2.9
}
},
{
"name": "test_pad_1mm",
"pos": "7.8,0.8"
},
{
"id": "r2",
"name": "label_line_up",
"pos": "7.8,0.3",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 0,
"H": 0.8
}
},
{
"name": "test_pad_1mm",
"pos": "7.8,2.4"
},
{
"id": "t2",
"name": "label_line_up",
"pos": "7.8,1.9",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 0,
"H": 0.4
}
},
{
"name": "test_pad_1mm",
"pos": "1.3,4.2"
},
{
"id": "cen",
"name": "label_line_up",
"pos": "2.1,4.3",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 5.7,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "1.6,5.3"
},
{
"name": "test_pad_1mm",
"pos": "1.3,6.3"
},
{
"name": "test_pad_1mm",
"pos": "4.5,7.6"
},
{
"name": "test_pad_1mm",
"pos": "3.8,8.7"
},
{
"id": "tck",
"name": "label_line_down",
"pos": "1.6,5.8",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 6.2,
"H": 0.3
}
},
{
"id": "tms",
"name": "label_line_down",
"pos": "1.3,6.8",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 6.5,
"H": 1.3
}
},
{
"id": "tdi",
"name": "label_line_down",
"pos": "4.5,8.1",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 3.3,
"H": 2.0
}
},
{
"id": "tdo",
"name": "label_line_down",
"pos": "3.8,9.2",
"vars": {
"DIR": "right",
"RASTER": 2,
"W": 4,
"H": 2.9
}
}
]
}
}

View File

@@ -0,0 +1,95 @@
{
"pcb": {
"templates": [
"tuyalc5",
"pcb-white"
],
"pinout_hidden": "I2S",
"pinout": {
"1": {
"CTRL": "ANT"
},
"2": {
"GND": null
},
"3": {
"IC": 16,
"ARD": "D0"
},
"4": {
"IC": 15,
"ARD": "D2"
},
"5": {
"IC": 22,
"ARD": "D1"
},
"6": {
"PWR": 3.3
},
"TRST": {
"IC": 21
},
"TRX1": {
"IC": 26,
"ARD": "D3"
},
"TTX1": {
"IC": 27,
"ARD": "D4"
},
"TRX2": {
"IC": 28,
"ARD": "D5"
},
"TTX2": {
"IC": 29,
"ARD": "D6"
},
"TSCK": {
"IC": 20,
"ARD": "D7"
},
"TCSN": {
"IC": 19,
"ARD": "D8"
},
"TSO": {
"IC": 17,
"ARD": [
"D10",
"A0"
]
},
"TSI": {
"IC": 18,
"ARD": "D9"
}
},
"front": [
{
"name": "chip",
"pos": "2.3,3.5",
"vars": {
"W": 5,
"POS": 1
}
},
{
"type": "text",
"pos": "3.5,2.2",
"text": "${SYMBOL}",
"font_size": 1.2,
"fill": {
"color": "${SILK_COLOR}"
}
}
],
"back": [
{
"name": "osc",
"pos": "2.6,1.3"
}
]
}
}

View File

@@ -0,0 +1,98 @@
{
"pcb": {
"test_pads": {
"TA9": "wl2s.back.a9.anchor",
"TGND": "wl2s.back.gnd.anchor",
"TRX1": "wl2s.back.rx1.anchor",
"TTX1": "wl2s.back.tx1.anchor",
"TSCLK": "wl2s.back.sclk.anchor",
"TSWD": "wl2s.back.swd.anchor"
},
"back": [
{
"id": "a9",
"name": "label_line_up",
"pos": "2.8,11.8",
"vars": {
"DIR": "left",
"W": 2.5,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "3,12"
},
{
"id": "gnd",
"name": "label_line_up",
"pos": "0.8,8.3",
"vars": {
"DIR": "left",
"W": 0.5,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "1,8.5"
},
{
"id": "rx1",
"name": "label_line_up",
"pos": "3,5.8",
"vars": {
"DIR": "left",
"W": 2.6,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "3.2,6"
},
{
"id": "tx1",
"name": "label_line_up",
"pos": "5,5.8",
"vars": {
"DIR": "left",
"W": 4.5,
"H": 2
}
},
{
"name": "test_pad_1mm",
"pos": "5.2,6"
},
{
"id": "swd",
"name": "label_line_up",
"pos": "10.2,11.1",
"vars": {
"DIR": "right",
"W": 3.0,
"H": 1
}
},
{
"name": "test_pad_1mm",
"pos": "10,11"
},
{
"id": "sclk",
"name": "label_line_up",
"pos": "5.2,12.2",
"vars": {
"DIR": "right",
"W": 8.0,
"H": 0
}
},
{
"name": "test_pad_1mm",
"pos": "5,12"
}
]
}
}

View File

@@ -0,0 +1,86 @@
{
"pcb": {
"templates": [
"tuya2",
"pcb-blue-light",
"rf-type1"
],
"scale": 10.5,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD,SPI,I2C",
"pinout": {
"1": {
"PWR": 3.3
},
"2": {
"IC": 15,
"ARD": "D0"
},
"3": {
"GND": null
},
"4": {
"IC": 23,
"ARD": "D1"
},
"5": {
"IC": 11,
"ARD": "D2"
},
"6": {
"IC": 21,
"ARD": "D3"
},
"7": {
"IC": 10,
"ARD": "D4"
},
"8": {
"IC": 8,
"ARD": [
"D5",
"A0"
]
},
"9": {
"IC": 24,
"ARD": [
"D6",
"A1"
]
},
"10": {
"IC": 7
},
"11": {
"IC": 22,
"ARD": "D7"
},
"TA9": {
"IC": 17,
"ARD": "D8"
},
"TGND": {
"GND": null
},
"TRX1": {
"IC": 29,
"ARD": "D9"
},
"TTX1": {
"IC": 30,
"ARD": "D10"
},
"TSCLK": {
"IC": 13,
"ARD": "D11"
},
"TSWD": {
"IC": 9,
"ARD": [
"D12",
"A2"
]
}
}
}
}

82
boards/_base/pcb/wr1.json Normal file
View File

@@ -0,0 +1,82 @@
{
"pcb": {
"templates": [
"tuya1",
"pcb-black",
"tuya-16x24",
"rf-type1"
],
"scale": 15,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {
"PWR": "VCC5"
},
"2": {
"IC": 32,
"ARD": "D0"
},
"3": {
"IC": 29,
"ARD": "D1"
},
"4": {
"PWR": 3.3
},
"5": {
"GND": null
},
"6": {
"IC": 13,
"ARD": "D2"
},
"7": {
"IC": 14,
"ARD": "D3"
},
"8": {
"IC": 1,
"ARD": "D4"
},
"9": {
"IC": 16,
"ARD": "D5"
},
"10": {
"IC": 28,
"ARD": "D6"
},
"11": {
"IC": 2,
"ARD": "D7"
},
"12": {
"IC": 30,
"ARD": [
"D8",
"A0"
]
},
"13": {
"IC": 31,
"ARD": "D9"
},
"14": {
"GND": null
},
"15": {
"GND": null
},
"16": {
"IC": 12
},
"17": {
"IC": 27,
"ARD": "A1"
},
"18": {
"GND": null
}
}
}
}

View File

@@ -0,0 +1,82 @@
{
"pcb": {
"templates": [
"tuya1",
"pcb-blue-light",
"tuya-16x24",
"rf-type1"
],
"scale": 15,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {
"PWR": "VCC5"
},
"2": {
"IC": 32,
"ARD": "D0"
},
"3": {
"IC": 29,
"ARD": "D1"
},
"4": {
"PWR": 3.3
},
"5": {
"GND": null
},
"6": {
"IC": 13,
"ARD": "D2"
},
"7": {
"IC": 14,
"ARD": "D3"
},
"8": {
"IC": 1,
"ARD": "D4"
},
"9": {
"IC": 17,
"ARD": "D5"
},
"10": {
"IC": 28,
"ARD": "D6"
},
"11": {
"IC": 2,
"ARD": "D7"
},
"12": {
"IC": 30,
"ARD": [
"D8",
"A0"
]
},
"13": {
"IC": 31,
"ARD": "D9"
},
"14": {
"GND": null
},
"15": {
"GND": null
},
"16": {
"IC": 12
},
"17": {
"IC": 27,
"ARD": "A1"
},
"18": {
"GND": null
}
}
}
}

View File

@@ -2,13 +2,8 @@
"pcb": {
"templates": [
"tuya2",
"rf-15mm-type1",
"tuya2-shield"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white"
}
"pcb-blue-light",
"rf-type1"
]
}
}

View File

@@ -0,0 +1,44 @@
{
"pcb": {
"back": [
{
"comment": "RXD Pad",
"name": "test_pad_1mm",
"pos": "5.4,14.5"
},
{
"comment": "TXD Pad",
"name": "test_pad_1mm",
"pos": "5.4,13.2"
},
{
"comment": "RXD Pad label",
"id": "rxd",
"name": "label_line_up",
"pos": "4.6,14.6",
"vars": {
"DIR": "left",
"RASTER": 2,
"W": 2.1,
"H": 0
}
},
{
"comment": "TXD Pad label",
"id": "txd",
"name": "label_line_up",
"pos": "5.4,12.4",
"vars": {
"DIR": "left",
"RASTER": 2,
"W": 2.7,
"H": 0.5
}
}
],
"test_pads": {
"TRX2": "wr2.back.rxd.anchor",
"TTX2": "wr2.back.txd.anchor"
}
}
}

View File

@@ -1,7 +1,7 @@
{
"pcb": {
"scale": 10.5,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD,SPI",
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"drawing_hidden": "SPI",
"pinout": {
"1": {
"PWR": 3.3
@@ -43,6 +43,14 @@
"11": {
"IC": 14,
"ARD": "D7"
},
"TTX2": {
"IC": 1,
"ARD": "D8"
},
"TRX2": {
"IC": 2,
"ARD": "D9"
}
}
}

View File

@@ -0,0 +1,44 @@
{
"pcb": {
"back": [
{
"comment": "RXD Pad",
"name": "test_pad_1mm",
"pos": "5.4,14.5"
},
{
"comment": "TXD Pad",
"name": "test_pad_1mm",
"pos": "5.4,13.2"
},
{
"comment": "RXD Pad label",
"id": "rxd",
"name": "label_line_up",
"pos": "4.6,14.6",
"vars": {
"DIR": "left",
"RASTER": 2,
"W": 2.1,
"H": 0
}
},
{
"comment": "TXD Pad label",
"id": "txd",
"name": "label_line_up",
"pos": "5.4,12.4",
"vars": {
"DIR": "left",
"RASTER": 2,
"W": 2.7,
"H": 0.5
}
}
],
"test_pads": {
"TRX2": "wr2e.back.rxd.anchor",
"TTX2": "wr2e.back.txd.anchor"
}
}
}

View File

@@ -1,7 +1,7 @@
{
"pcb": {
"scale": 10.5,
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD,SPI,SDA0",
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD,SDA0",
"drawing_hidden": "SPI",
"pinout": {
"1": {
"PWR": 3.3
@@ -46,6 +46,14 @@
"11": {
"IC": 14,
"ARD": "D6"
},
"TTX2": {
"IC": 1,
"ARD": "D7"
},
"TRX2": {
"IC": 2,
"ARD": "D8"
}
}
}

View File

@@ -2,14 +2,8 @@
"pcb": {
"templates": [
"tuya2l",
"rf-15mm-type1",
"tuya2l-shield"
],
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white",
"PINTYPE_HORZ": "pin_horz_2mm_cast_hole"
}
"pcb-blue-light",
"rf-type1"
]
}
}

View File

@@ -2,15 +2,8 @@
"pcb": {
"templates": [
"esp12s",
"esp12s-shield",
"tuya-16x24",
"rf-16mm-type1"
],
"vars": {
"MASK_PRESET": "mask_black",
"TRACE_COLOR": "#505050",
"SILK_COLOR": "white",
"PINTYPE_VERT": "pin_vert_2mm_cast_nohole"
}
"rf-type1"
]
}
}

View File

@@ -1,5 +1,8 @@
{
"pcb": {
"templates": [
"pcb-black"
],
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {

View File

@@ -1,10 +1,8 @@
{
"pcb": {
"vars": {
"MASK_PRESET": "mask_blue_light",
"TRACE_COLOR": "#58839B",
"SILK_COLOR": "white"
},
"templates": [
"pcb-blue-light"
],
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {

View File

@@ -2,15 +2,9 @@
"pcb": {
"templates": [
"esp12s",
"esp12e-shield",
"pcb-white",
"tuya-16x24",
"rf-16mm-type1"
],
"vars": {
"MASK_PRESET": "mask_white",
"TRACE_COLOR": "#E0E0E0",
"SILK_COLOR": "black",
"PINTYPE_VERT": "pin_vert_2mm_cast_hole"
}
"rf-type1"
]
}
}

View File

@@ -1,6 +1,9 @@
{
"pcb": {
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD,SPI",
"templates": [
"pcb-black"
],
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {
"NC": null

View File

@@ -0,0 +1,16 @@
{
"build": {
"amb_boot_all": "boot_all_77F7.bin"
},
"flash": {
"ota1": "0x00B000+0x75000",
"ota2": "0x080000+0x75000",
"kvs": "0x0F5000+0x4000",
"userdata": "0x0F9000+0x7000"
},
"upload": {
"flash_size": 1048576,
"maximum_size": 479232
}
}

View File

@@ -5,9 +5,8 @@
"flash": {
"ota1": "0x00B000+0x75000",
"ota2": "0x080000+0x75000",
"kvs": "0xF5000+0x6000",
"userdata": "0xFB000+0x104000",
"rdp": "0x1FF000+0x1000"
"kvs": "0x0F5000+0x8000",
"userdata": "0x0FD000+0x102000"
},
"upload": {
"flash_size": 2097152,

View File

@@ -5,9 +5,8 @@
"flash": {
"ota1": "0x00B000+0xC5000",
"ota2": "0x0D0000+0xC5000",
"kvs": "0x195000+0x6000",
"userdata": "0x19B000+0x64000",
"rdp": "0x1FF000+0x1000"
"kvs": "0x195000+0x8000",
"userdata": "0x19D000+0x62000"
},
"upload": {
"flash_size": 2097152,

View File

@@ -6,8 +6,7 @@
"ota1": "0x00B000+0xF5000",
"ota2": "0x100000+0xF5000",
"kvs": "0x1F5000+0x8000",
"userdata": "0x1FD000+0x202000",
"rdp": "0x3FF000+0x1000"
"userdata": "0x1FD000+0x202000"
},
"upload": {
"flash_size": 4194304,

View File

@@ -0,0 +1,5 @@
{
"flash": {
"tuya": "0x1EB000+0x15000"
}
}

View File

@@ -10,7 +10,8 @@
"boot_xip": "0x000000+0x4000",
"boot_ram": "0x004000+0x4000",
"system": "0x009000+0x1000",
"calibration": "0x00A000+0x1000"
"calibration": "0x00A000+0x1000",
"rdp": "0x1FF000+0x1000"
},
"connectivity": [
"wifi"
@@ -44,13 +45,8 @@
}
},
"links": {
"General info": "../../docs/platform/realtek-amb/README.md",
"Flashing guide": "../../docs/platform/realtek-ambz/flashing.md",
"Info & flashing guide": "../../docs/platform/realtek-ambz/README.md",
"Debugging": "../../docs/platform/realtek-ambz/debugging.md"
},
"extra": [
"RDP is most likely not used in Tuya firmwares, as the System Data partition contains an incorrect offset 0xFF000 for RDP, which is in the middle of OTA2 image.",
"Additionally, Tuya firmware uses an encrypted KV or file storage, which resides at the end of flash memory. This seems to overlap system RDP area."
]
}
}
}

View File

@@ -0,0 +1,11 @@
{
"flash": {
"ota1": "0x010000+0xE0000",
"ota2": "0x0F0000+0xE0000",
"kvs": "0x1F8000+0x8000"
},
"upload": {
"flash_size": 2097152,
"maximum_size": 917504
}
}

View File

@@ -2,8 +2,7 @@
"flash": {
"ota1": "0x00C000+0xF8000",
"ota2": "0x104000+0xF8000",
"kvs": "0x1FC000+0x2000",
"userdata": "0x1FE000+0x2000"
"kvs": "0x1FC000+0x4000"
},
"upload": {
"flash_size": 2097152,

View File

@@ -0,0 +1,96 @@
{
"image": {
"keys": {
"decryption": "a0d6dae7e062ca94cbb294bf896b9f68cf8438774256ac7403ca4fd9a1c9564f",
"keyblock": {
"part_table": "882aa16c8c44a7760aa8c9ab22e3568c6fa16c2afa4f0cea29a10abcdf60e44f",
"boot": "882aa16c8c44a7760aa8c9ab22e3568c6fa16c2afa4f0cea29a10abcdf60e44f"
},
"hash_keys": {
"part_table": "47e5661335a4c5e0a94d69f3c737d54f2383791332939753ef24279608f6d72b",
"boot": "ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",
"ota1": "000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e5f",
"ota2": "000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e5f"
},
"user_keys": {
"boot": "aa0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f",
"ota1": "bb0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f",
"ota2": "bb0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f"
},
"xip_sce_key": "a0d6dae7e062ca94cbb294bf896b9f68",
"xip_sce_iv": "94879487948794879487948794879487"
},
"ptable": {
"boot": "BOOT",
"ota1": "FW1",
"ota2": "FW2"
},
"boot": {
"name": "boot.sram",
"type": "SRAM",
"entry": "__ram_start_table_start__",
"elf": [
".ram.func.table",
".data",
".ram.code_text",
".ram.code_rodata"
],
"is_boot": true
},
"fw": [
{
"type": "FWHS_S",
"sections": [
{
"name": "fwhs.sram",
"type": "SRAM",
"entry": "__ram_start_table_start__",
"elf": [
".ram.img.signature",
".ram.func.table",
".data",
".ram.code_text",
".ram.code_rodata"
]
},
{
"name": "fwhs.psram",
"type": "PSRAM",
"entry": "__psram_start__",
"elf": [
".psram.data",
".psram.code_text",
".psram.code_rodata"
]
}
]
},
{
"type": "XIP",
"sections": [
{
"name": "fwhs.xip_c",
"entry": "XIP_RamImgSignature_s",
"type": "XIP",
"elf": [
".xip.code_c"
]
}
]
},
{
"type": "XIP",
"sections": [
{
"name": "fwhs.xip_p",
"entry": "__xip_code_rodata_start__",
"type": "XIP",
"elf": [
".xip.code_p"
]
}
]
}
]
}
}

View File

@@ -0,0 +1,5 @@
{
"flash": {
"tuya": "0x1D5000+0x10000"
}
}

View File

@@ -13,10 +13,20 @@
},
"debug": {
"protocol": "openocd",
"protocols": []
"protocols": [
"openocd"
],
"openocd_config": "amebaz2.cfg",
"gdb_init": [
"mem 0x9b000000 0x9c000000 ro"
]
},
"upload": {
"maximum_ram_size": 262144
"maximum_ram_size": 262144,
"protocol": "uart",
"protocols": [
"uart"
]
},
"doc": {
"params": {

24
boards/afw121t.json Normal file
View File

@@ -0,0 +1,24 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-1mb-468k",
"realtek-ambz-bx",
"ic/rtl8710bn",
"pcb/afw121t"
],
"build": {
"mcu": "rtl8710bx",
"variant": "afw121t"
},
"name": "AFW121T",
"url": "https://item.szlcsc.com/357903.html?fromZone=l_b__%2522brand%2522",
"vendor": "99iot(Shenzhen)co.,ltd",
"pcb": {
"symbol": "AFW121T"
},
"doc": {
"links": {
"Vendor datasheet": "https://item.szlcsc.com/datasheet/AFW121TI-AY1LED1/357903.html"
}
}
}

View File

@@ -2,6 +2,7 @@
"_base": [
"realtek-ambz2",
"realtek-ambz2-8720",
"realtek-ambz2-image",
"realtek-ambz2-2mb-992k",
"ic/rtl8720cf",
"pcb/bw15"

20
boards/cb1s.json Normal file
View File

@@ -0,0 +1,20 @@
{
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb1s",
"pcb/cb1s-test"
],
"build": {
"mcu": "bk7231n",
"variant": "cb1s"
},
"name": "CB1S Wi-Fi Module",
"url": "https://developer.tuya.com/en/docs/iot/cb1s-module-datasheet?id=Kaij1abmwyjq2",
"vendor": "Tuya Inc.",
"pcb": {
"symbol": "CB1S"
}
}

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231n-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb2l",
"pcb/cb2l-test"

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231n-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb2s",
"pcb/cb2s-test"

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231n-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb3l"
],

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231n-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb3s"
],

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231n-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb3se"
],

20
boards/cblc5.json Normal file
View File

@@ -0,0 +1,20 @@
{
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cblc5",
"pcb/cblc5-test"
],
"build": {
"mcu": "bk7231n",
"variant": "cblc5"
},
"name": "CBLC5 Wi-Fi Module",
"url": "https://developer.tuya.com/en/docs/iot/cblc5-module-datasheet?id=Ka07iqyusq1wm",
"vendor": "Tuya Inc.",
"pcb": {
"symbol": "CBLC5"
}
}

23
boards/cbu.json Normal file
View File

@@ -0,0 +1,23 @@
{
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cbu",
"pcb/cbu-test"
],
"build": {
"mcu": "bk7231n",
"variant": "cbu"
},
"name": "CBU Wi-Fi Module",
"url": "https://developer.tuya.com/en/docs/iot/cbu-module-datasheet?id=Ka07pykl5dk4u",
"vendor": "Tuya Inc.",
"doc": {
"fccid": "2ANDL-CBU"
},
"pcb": {
"symbol": "CBU"
}
}

View File

@@ -3,7 +3,7 @@
"generic",
"beken-72xx",
"beken-7231n",
"beken-7231n-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32"
],
"build": {

View File

@@ -2,8 +2,9 @@
"_base": [
"generic",
"beken-72xx",
"beken-7231u",
"beken-7231t-tuya",
"beken-7231",
"beken-7231t",
"beken-7231-tuya",
"ic/bk7231-qfn32"
],
"build": {

View File

@@ -0,0 +1,118 @@
{
"_base": [
"generic",
"lightning-ln882x",
"lightning-ln882hki",
"ic/ln882hk"
],
"build": {
"mcu": "ln882hk",
"variant": "generic-ln882hki"
},
"name": "Generic - LN882HKI",
"symbol": "LN882HKI",
"url": "https://docs.libretiny.eu/boards/generic-ln882hki/",
"vendor": "Generic",
"pcb": {
"pinout": {
"1": {
"IC": 8,
"ARD": [
"D0",
"A2"
]
},
"2": {
"IC": 9,
"ARD": [
"D1",
"A3"
]
},
"3": {
"IC": 10,
"ARD": "D2"
},
"4": {
"IC": 11,
"ARD": "D3"
},
"5": {
"IC": 12,
"ARD": [
"D4",
"A4"
]
},
"6": {
"IC": 13,
"ARD": "D5"
},
"7": {
"IC": 14,
"ARD": "D6"
},
"8": {
"IC": 15,
"ARD": "D7"
},
"9": {
"IC": 16,
"ARD": "D8"
},
"10": {
"IC": 17,
"ARD": "D9"
},
"11": {
"IC": 21,
"ARD": "D10"
},
"12": {
"IC": 22,
"ARD": "D11"
},
"13": {
"IC": 23,
"ARD": "D12"
},
"14": {
"IC": 24,
"ARD": [
"D13",
"A5"
]
},
"15": {
"IC": 25,
"ARD": [
"D14",
"A6"
]
},
"16": {
"IC": 26,
"ARD": [
"D15",
"A7"
]
},
"17": {
"IC": 27,
"ARD": "D16"
},
"18": {
"IC": 28,
"ARD": "D17"
},
"19": {
"IC": 29,
"ARD": "D18"
},
"20": {
"IC": 30,
"ARD": "D19"
}
}
}
}

View File

@@ -18,7 +18,7 @@
"extra": [
"## Information",
"This is a generic board definition for RTL8710BX with 4 MiB of flash. It has a bigger application partition size (980 KiB). The used bootloader is also different from the standard Tuya one.",
"It can be found in [Ezviz T31 smart plug](https://www.ezviz.com/product/T31/2021) - bare chip soldered onto the manufacturer-made PCB. The plug is not Tuya/SmartLife-compatible and has a 25Q32CSIG flash chip. Refer to [libretiny#23](https://github.com/kuba2k2/libretiny/issues/23) for photos and more information.",
"It can be found in [Ezviz T31 smart plug](https://www.ezviz.com/product/T31/2021) - bare chip soldered onto the manufacturer-made PCB. The plug is not Tuya/SmartLife-compatible and has a 25Q32CSIG flash chip. Refer to [libretiny#23](https://github.com/libretiny-eu/libretiny/issues/23) for photos and more information.",
"Note that stock firmware seems to use smaller app images (0x80000 / 512 KiB). After 0x180000 some product-test data and device logs can be found. Because the OTA2 offset is 0x100000, the board definition was configured to use all available space."
]
},

View File

@@ -0,0 +1,102 @@
{
"_base": [
"generic",
"realtek-ambz2",
"realtek-ambz2-8720",
"realtek-ambz2-image",
"realtek-ambz2-2mb-896k",
"ic/rtl8720cf"
],
"build": {
"mcu": "rtl8720cf",
"variant": "generic-rtl8720cf-2mb-896k"
},
"name": "Generic - RTL8720CF (2M/896k)",
"symbol": "RTL8720CF (2M/896k)",
"url": "https://docs.libretiny.eu/boards/generic-rtl8720cf-2mb-896k/",
"vendor": "Generic",
"pcb": {
"pinout": {
"1": {
"IC": 15,
"ARD": "D0"
},
"2": {
"IC": 16,
"ARD": "D1"
},
"3": {
"IC": 18,
"ARD": "D2"
},
"4": {
"IC": 19,
"ARD": "D3"
},
"5": {
"IC": 20,
"ARD": "D4"
},
"6": {
"IC": 21,
"ARD": "D5"
},
"7": {
"IC": 22,
"ARD": "D6"
},
"8": {
"IC": 23,
"ARD": "D7"
},
"9": {
"IC": 24,
"ARD": "D8"
},
"10": {
"IC": 25,
"ARD": "D9"
},
"11": {
"IC": 26,
"ARD": "D10"
},
"12": {
"IC": 33,
"ARD": "D11"
},
"13": {
"IC": 34,
"ARD": "D12"
},
"14": {
"IC": 36,
"ARD": "D13"
},
"15": {
"IC": 37,
"ARD": "D14"
},
"16": {
"IC": 38,
"ARD": "D15"
},
"17": {
"IC": 39,
"ARD": "D16"
},
"18": {
"IC": 40,
"ARD": "D17"
},
"19": {
"IC": 1,
"ARD": "D18"
},
"20": {
"IC": 3,
"ARD": "D19"
}
}
}
}

View File

@@ -3,6 +3,7 @@
"generic",
"realtek-ambz2",
"realtek-ambz2-8720",
"realtek-ambz2-image",
"realtek-ambz2-2mb-992k",
"ic/rtl8720cf"
],

22
boards/ln-02.json Normal file
View File

@@ -0,0 +1,22 @@
{
"_base": [
"lightning-ln882x",
"lightning-ln882hki",
"ic/ln882hk",
"pcb/ln-02",
"pcb/ln-02-test"
],
"build": {
"mcu": "ln882hk",
"variant": "ln-02"
},
"name": "LN-02 Wi-Fi/BLE Module",
"url": "https://docs.libretiny.eu/boards/ln-02/",
"vendor": "Unknown",
"doc": {
"fccid": ""
},
"pcb": {
"symbol": "LN-02"
}
}

Some files were not shown because too many files have changed in this diff Show More