Global Conventions
Mapping of cross-language patterns
Error Handling
error (return)throws XxxExceptionraises Exception
(T, error)T throws XxxExceptionT / raises Exception
error (no return)void throws XxxExceptionNone / raises Exception
Streaming / Callbacks
func(T) callbackConsumer<T>callable / iterator
<-chan TStreamHandleIterator[T]
context.Context paramStreamHandle.cancel()timeout / close channel
Types
uint32 / intintint
boolbooleanbool
[]bytebyte[]bytes
[]TList<T>list[T]
stringStringstr
Naming
PascalCase methodscamelCase methodsPascalCase methods
struct DTOrecord DTOdataclass / class DTO
client.XxxManagerclient.xxxManager()client.XxxManager
AccountManager
Device account registration —
AccountService| Method | Go | Java |
|---|---|---|
| Add account | AddAccount(email, password string) error |
void addAccount(String email, String password) throws AccountException |
| Get status | GetStatus() (AccountStatus, error) |
AccountStatus getStatus() throws AccountException |
| Remove account | RemoveAccount(password string) error |
void removeAccount(String password) throws AccountException |
PowerManager
Device power control —
PowerService| Method | Go | Java |
|---|---|---|
| Reboot | Reboot(force bool, reason string) (PowerResult, error) |
void reboot(boolean force, String reason) throws PowerException |
| Shutdown | Shutdown(force bool, reason string) (PowerResult, error) |
void shutdown(boolean force, String reason) throws PowerException |
⚠ Divergence
Go returns
PowerResult{Success, Message}; Java is void (throws exception on failure).
WiFiManager
WiFi interface management —
WiFiService| Method | Go | Java |
|---|---|---|
| List interfaces | ListInterfaces() ([]WiFiInterfaceInfo, error) |
List<WiFiInterfaceInfo> listInterfaces() throws WiFiException |
| Link properties | GetLinkProperties(ifname string) (WiFiInterfaceInfo, error) |
WiFiInterfaceInfo getLinkProperties(String ifname) throws WiFiException |
| Is connected? | IsConnected(ifname string) (bool, error) |
boolean isConnected(String ifname) throws WiFiException |
| Connect | Connect(cfg WiFiClientConfig) error |
void connect(WiFiClientConfig cfg) throws WiFiException |
| Reconnect | Reconnect(ifname string) error |
void reconnect(String ifname) throws WiFiException |
| Disconnect | Disconnect(ifname string) error |
void disconnect(String ifname) throws WiFiException |
| Start hotspot | StartHotspot(cfg WiFiAPConfig) error |
void startHotspot(WiFiAPConfig cfg) throws WiFiException |
| Stop hotspot | StopHotspot(ifname string) error |
void stopHotspot(String ifname) throws WiFiException |
| Scan networks | Scan(ifname string, forceRescan bool) ([]ScannedNetwork, error) |
List<ScannedNetwork> scan(String ifname, boolean forceRescan) throws WiFiException |
EthernetManager
Ethernet interface management —
EthernetService| Method | Go | Java |
|---|---|---|
| List interfaces | ListInterfaces() ([]EthernetLinkInfo, error) |
List<EthernetInterfaceInfo> listInterfaces() throws EthernetException |
| Link properties | GetLinkProperties(ifname string) (EthernetLinkInfo, error) |
EthernetInterfaceInfo getLinkProperties(String ifname) throws EthernetException |
| Is connected? | IsConnected(ifname string) (bool, error) |
boolean isConnected(String ifname) throws EthernetException |
| Apply config | SetConfig(cfg EthernetConfig) error |
void setStaticConfig(String ifname, String ip, String gw, ...) throws EthernetException |
| Enable DHCP | — (via SetConfig) |
void setDhcp(String ifname) throws EthernetException |
| Enable | Enable(ifname string) error |
void enable(String ifname) throws EthernetException |
| Disable | Disable(ifname string) error |
void disable(String ifname) throws EthernetException |
⚠ Divergence
Go uses unified
SetConfig(EthernetConfig); Java splits into setStaticConfig(...) and setDhcp(ifname).
FirewallManager
Firewall zones & rules —
FirewallService| Method | Go | Java |
|---|---|---|
| List zones | ListZones() ([]Zone, error) |
List<Zone> listZones() throws FirewallException |
| Add zone | AddZone(z Zone) error |
void addZone(Zone zone) throws FirewallException |
| Remove zone | RemoveZone(name string) error |
void removeZone(String name) throws FirewallException |
| List rules | ListRules() ([]FirewallRule, error) |
List<FirewallRule> listRules() throws FirewallException |
| Add rule | AddRule(r FirewallRule) error |
void addRule(FirewallRule rule) throws FirewallException |
| Remove rule | RemoveRule(id string) error |
void removeRule(String id) throws FirewallException |
| Flush rules | FlushRules() error |
void flushRules() throws FirewallException |
GpioManager
GPIO & PWM control —
GpioService| Method | Go | Java |
|---|---|---|
| List pins | ListPins() ([]GpioPin, error) |
List<GpioPin> listPins() throws GpioException |
| Get level | GetLevel(pin GpioPin) (bool, error) |
Level getLevel(GpioPin pin) throws GpioException |
| Set level | SetLevel(pin GpioPin, high bool) error |
void setLevel(GpioPin pin, Level level) throws GpioException |
| Get direction | GetDirection(pin GpioPin) (bool, error) |
Direction getDirection(GpioPin pin) throws GpioException |
| Set direction | SetDirection(pin GpioPin, out bool) error |
void setDirection(GpioPin pin, Direction dir) throws GpioException |
| List PWM pins | ListPwmPins() ([]GpioPin, error) |
List<GpioPin> listPwmPins() throws GpioException |
| Set PWM | SetPwm(pin GpioPin, dutyCycle, freqHz float64) error |
PwmState setPwm(GpioPin pin, double dutyCycle, double freqHz) throws GpioException |
| Get PWM | GetPwm(pin GpioPin) (PwmState, error) |
PwmState getPwm(GpioPin pin) throws GpioException |
| Disable PWM | DisablePwm(pin GpioPin) error |
void disablePwm(GpioPin pin) throws GpioException |
⚠ Divergence
- Go
GetLevel→bool| Java →Levelenum (HIGH/LOW) - Go
GetDirection→bool| Java →Directionenum (IN/OUT) - Go
SetPwm→error| Java →PwmState
UartManager
UART serial communication —
GpioService| Method | Go | Java |
|---|---|---|
| List ports | ListPorts() ([]string, error) |
List<String> listPorts() throws UartException |
| Open | Open(cfg UartConfig) error |
void open(UartConfig cfg) throws UartException |
| Close | Close(port string) error |
void close(String port) throws UartException |
| Get config | GetConfig(port string) (UartConfig, error) |
UartConfig getConfig(String port) throws UartException |
| Write | Write(port string, data []byte) (int, error) |
int write(String port, byte[] data) throws UartException |
| Listen (sync) | Listen(ctx, port string, chunkSize int, onChunk func([]byte)) error |
— (use listenAsync) |
| Listen (async) | ListenAsync(ctx, port string, chunkSize int) (<-chan []byte, error) |
StreamHandle listenAsync(String port, int chunkSize,
Consumer<byte[]> onData,
Consumer<Throwable> onError) |
I²CManager
I²C bus communication —
GpioService| Method | Go | Java |
|---|---|---|
| List buses | ListBuses() ([]uint32, error) |
List<Integer> listBuses() throws I2CException |
| Scan bus | ScanBus(bus uint32) ([]uint32, error) |
List<Integer> scanBus(int bus) throws I2CException |
| Get config | GetConfig(bus uint32) (I2CConfig, error) |
I2CConfig getConfig(int bus) throws I2CException |
| Set config | SetConfig(cfg I2CConfig) error |
void setConfig(I2CConfig cfg) throws I2CException |
| Transfer | Transfer(req I2CTransferRequest) ([]byte, error) |
byte[] transfer(I2CTransferRequest req) throws I2CException |
✔ Resolved
scanBus aligned with Go.
SpiManager
SPI bus communication —
GpioService| Method | Go | Java |
|---|---|---|
| List devices | ListDevices() ([]string, error) |
List<String> listDevices() throws SpiException |
| Get config | GetConfig(bus, cs uint32) (SpiConfig, error) |
SpiConfig getConfig(int bus, int chipSelect) throws SpiException |
| Set config | SetConfig(cfg SpiConfig) error |
void setConfig(SpiConfig cfg) throws SpiException |
| Transfer | Transfer(bus, cs uint32, dataOut []byte, readLen uint32) ([]byte, error) |
byte[] transfer(int bus, int chipSelect, byte[] dataOut, int readLength) throws SpiException |
✔ Resolved
Public API exposes only
transfer() — aligned with Go.
BluetoothManager
Bluetooth Classic, BLE & GATT —
BluetoothService| Method | Go | Java |
|---|---|---|
| Adapter info | GetAdapterInfo() (BluetoothAdapterInfo, error) |
AdapterInfo getAdapterInfo() throws BluetoothException |
| Enable | Enable() error |
void enable() throws BluetoothException |
| Disable | Disable() error |
void disable() throws BluetoothException |
| Get local name | GetLocalName() (string, error) |
String getLocalName() throws BluetoothException |
| Set local name | SetLocalName(name string) error |
void setLocalName(String name) throws BluetoothException |
| Set discoverable | SetDiscoverable(enable bool, durationSec int32) error |
void setDiscoverable(boolean disc, int timeoutSec) throws BluetoothException |
| Classic scan | ScanClassic(ctx, onResult func(BluetoothDevice)) error |
StreamHandle startScan(Consumer<BtDevice> onDevice,
Consumer<Throwable> onError) |
| BLE scan | ScanBLE(ctx, filters []BLEScanFilter, onResult func(BLEScanResult)) error |
StreamHandle startBleScan(List<BleScanFilter> filters, boolean inclAdv,
Consumer<BLEScanResult>, Consumer<Throwable>) |
| Bonded devices | GetBondedDevices() ([]BluetoothDevice, error) |
List<BtDevice> getBondedDevices() throws BluetoothException |
| Bond device | BondDevice(ctx, address string, onEvent func(BondEvent)) error |
StreamHandle bondDevice(String address,
Consumer<BondEvent> onEvent,
Consumer<Throwable> onError) |
| Remove bond | RemoveBond(address string) error |
void removeBond(String address) throws BluetoothException |
| Connect device | Connect(address string) error |
void connect(String address) throws BluetoothException |
| Disconnect device | Disconnect(address string) error |
void disconnect(String address) throws BluetoothException |
| Connection state | GetConnectionState(address string) (string, error) |
— (not mapped) |
| GATT connect | — (not available) |
void gattConnect(String address) throws BluetoothException |
| GATT disconnect | — (not available) |
void gattDisconnect(String address) throws BluetoothException |
| GATT discover | — (not available) |
List<GattService> gattDiscoverServices(String address) throws BluetoothException |
| GATT read | — (not available) |
byte[] gattRead(String addr, String svcUuid, String charUuid) throws BluetoothException |
| GATT write | — (not available) |
void gattWrite(String addr, String svcUuid, String charUuid, byte[]) throws BluetoothException |
| GATT subscribe | — (not available) |
StreamHandle gattSubscribe(String addr, String svcUuid,
String charUuid,
Consumer<byte[]> onNotify,
Consumer<Throwable> onError) |
| GATT RSSI | — (not available) |
int gattReadRssi(String address) throws BluetoothException |
⚠ Divergences
- Java has full GATT (connect / discover / read / write / subscribe / RSSI) — Go does not have.
- Go has
GetConnectionState— Java does not have. Slightly different names: Go✔ Resolved — Java renamed toConnect/Disconnectvs JavaconnectDevice/disconnectDevice.connect/disconnect.
SystemManager
Hardware identity, OS info, live metrics & system policies —
SystemService| Method | Go | Java |
|---|---|---|
| API Version | ||
| API version | GetApiVersion() (ApiVersion, error) |
ApiVersion getApiVersion() throws SystemServiceException |
| Hardware Identity | ||
| Device name | GetDeviceName() (string, error) |
String getDeviceName() throws SystemServiceException |
| SoC model | GetSocModel() (string, error) |
String getSocModel() throws SystemServiceException |
| SoC vendor | GetSocVendor() (string, error) |
String getSocVendor() throws SystemServiceException |
| Board model | GetBoardModel() (string, error) |
String getBoardModel() throws SystemServiceException |
| Board vendor | GetBoardVendor() (string, error) |
String getBoardVendor() throws SystemServiceException |
| HW version | GetHardwareVersion() (string, error) |
String getHardwareVersion() throws SystemServiceException |
| HW model | GetHardwareModel() (string, error) |
String getHardwareModel() throws SystemServiceException |
| System UUID | GetSystemUuid() (string, error) |
String getSystemUuid() throws SystemServiceException |
| Board serial | GetBoardSerial() (string, error) |
String getBoardSerial() throws SystemServiceException |
| CPU serial | GetCpuSerial() (string, error) |
String getCpuSerial() throws SystemServiceException |
| Machine ID | GetMachineId() (string, error) |
String getMachineId() throws SystemServiceException |
| Architecture | GetArchitecture() (string, error) |
String getArchitecture() throws SystemServiceException |
| CPU & Memory | ||
| CPU model | GetCpuModel() (string, error) |
String getCpuModel() throws SystemServiceException |
| CPU cores | GetCpuCores() (int64, error) |
long getCpuCores() throws SystemServiceException |
| CPU threads | GetCpuThreads() (int64, error) |
long getCpuThreads() throws SystemServiceException |
| CPU min MHz | GetCpuMinMhz() (float64, error) |
double getCpuMinMhz() throws SystemServiceException |
| CPU max MHz | GetCpuMaxMhz() (float64, error) |
double getCpuMaxMhz() throws SystemServiceException |
| Total RAM | GetTotalRAM() (uint64, error) |
long getTotalRAM() throws SystemServiceException |
| OS & Software | ||
| OS name | GetOsName() (string, error) |
String getOsName() throws SystemServiceException |
| OS version | GetOsVersion() (string, error) |
String getOsVersion() throws SystemServiceException |
| Kernel version | GetKernelVersion() (string, error) |
String getKernelVersion() throws SystemServiceException |
| Distro | GetDistro() (string, error) |
String getDistro() throws SystemServiceException |
| Distro version | GetDistroVersion() (string, error) |
String getDistroVersion() throws SystemServiceException |
| Runtime version | GetRuntimeVersion() (string, error) |
String getRuntimeVersion() throws SystemServiceException |
| Build version | GetBuildVersion() (string, error) |
String getBuildVersion() throws SystemServiceException |
| Build date | GetBuildDate() (string, error) |
String getBuildDate() throws SystemServiceException |
| Live Metrics | ||
| Get metrics | GetMetrics() (Metrics, error) |
MetricsInfoResponse getMetrics() throws SystemServiceException |
| OTA Update (client-streaming) | ||
| Send update | SendUpdate(ctx, data []byte, chunkSize int) (bool, error) |
boolean update(File updateFile) throws SystemServiceException, IOException |
| Send update (path) | — (passar []byte lido do ficheiro) |
boolean update(String updatePath) throws SystemServiceException, IOException |
| System Policies | ||
| Allow untrusted apps | AllowUntrustedApps() error |
boolean allowUntrustedApps() throws SystemServiceException |
| Disallow untrusted apps | DisallowUntrustedApps() error |
boolean disallowUntrustedApps() throws SystemServiceException |
| Untrusted apps? | IsUntrustedAppsAllowed() (bool, error) |
boolean isUntrustedAppsAllowed() throws SystemServiceException |
| Enable reboot on fail | EnableRebootOnFailure() error |
boolean enableRebootOnFailure() throws SystemServiceException |
| Disable reboot on fail | DisableRebootOnFailure() error |
boolean disableRebootOnFailure() throws SystemServiceException |
| Reboot on fail? | IsRebootOnFailureEnabled() (bool, error) |
boolean isRebootOnFailureEnabled() throws SystemServiceException |
| Enable dev mode | EnableDevMode() error |
boolean enableDevMode() throws SystemServiceException |
| Disable dev mode | DisableDevMode() error |
boolean disableDevMode() throws SystemServiceException |
| Dev mode? | IsDevModeEnabled() (bool, error) |
boolean isDevModeEnabled() throws SystemServiceException |
| Enable SSH server | EnableSSHServer() error |
boolean enableSSHServer() throws SystemServiceException |
| Disable SSH server | DisableSSHServer() error |
boolean disableSSHServer() throws SystemServiceException |
| SSH enabled? | IsSSHServerEnabled() (bool, error) |
boolean isSSHServerEnabled() throws SystemServiceException |
⚠ Divergences
- Naming: Java uses
PascalCasein methods (GetDeviceName) instead ofcamelCaselike all other Java managers — inconsistency to fix. - Bulk DTOs: Go has
GetDeviceInfo(),GetCpuInfo(),GetOsInfo()which aggregate individual fields into a single DTO; Java has no equivalent. - GetMetrics: Go returns clean
MetricsDTO; Java returns raw protoMetricsInfoResponse. - Policies (Enable/Disable): Go returns
error; Java returnsboolean. - SendUpdate: Go accepts
[]byte+chunkSize; Java recebeFileouStringpath and chunks internally.
PackageManager
Application package management —
PackageManagerService| Method | Go | Java |
|---|---|---|
| List installed | GetInstalledPackages() ([]InstalledPackage, error) |
List<InstalledPackage> getInstalledPackages() throws PackageManagerException |
| Install/Update | InstallUpdatePackage(filePath string, chunkSize int) (bool, error) |
boolean installUpdatePackage(String filePath, int chunkSize) throws PackageManagerException, IOException |
| Remove package | RemovePackage(appName string) (bool, error) |
boolean removePackage(String appName) throws PackageManagerException |
✔ Resolved
PackageManager implemented in Go — aligned with Java.
DevelopmentManager
Device log streaming —
DevelopmentService| Method | Go | Java |
|---|---|---|
| Subscribe logs (sync) | SubscribeLogs(ctx, filter LogFilter, onEntry func(LogEntry)) error |
— (use subscribeLogsAsync) |
| Subscribe logs (async) | SubscribeLogsAsync(ctx, filter LogFilter) <-chan LogEntry |
StreamHandle subscribeLogsAsync(String app, String tag,
LogLevel minLevel,
Consumer<LogEntry> onEntry,
Consumer<Throwable> onError) |
⚠ Divergence
Go exposes both synchronous version (
SubscribeLogs) como canal (SubscribeLogsAsync).
Java only exposes callback version (subscribeLogsAsync).
Go LogFilter is a DTO; Java passes fields separately (app, tag, minLevel).
⚠ Divergences Summary
Alignment points between Go (source of truth), Java, and Python
| # | Manager | Issue | Suggestion |
|---|---|---|---|
| 1 | PowerManager | Go returns PowerResult; Java is void |
Normalize to void in Go or return DTO in Java |
| 2 | GpioManager | GetLevel → bool (Go) vs Level enum (Java). GetDirection igual. |
Prefer enum in both — more expressive and type-safe |
| 3 | GpioManager | SetPwm → error (Go) vs PwmState (Java) |
Uniformizar — Go pode devolver PwmState |
| 4 | EthernetManager | Go: SetConfig(DTO) — Java: setStaticConfig(...) + setDhcp() |
Align Java to setConfig(EthernetConfig) |
| 5 ✔ | SpiManager | Write/Read/WriteRead that Java did not have |
✔ Resolved — public API exposes only transfer() |
| 6 ✔ | I2CManager | ScanBus(bus) — Java: scan(bus) |
✔ Resolved — renamed to scanBus(bus) |
| 7 | BluetoothManager | Java has full GATT; Go does not have. Go has GetConnectionState; Java does not. |
Implement GATT in Go; add getConnectionState in Java |
| 8 ✔ | BluetoothManager | Connect/Disconnect — Java: connectDevice/disconnectDevice |
✔ Resolved — renamed to connect/disconnect |
| 9 | DevelopmentManager | Go LogFilter DTO — Java passes separate fields |
Create LogFilter record in Java |
| 10 | UartManager | Go has Listen synchronous; Java does not |
Acceptable — Java always uses async callback |
| 11 ✔ | SystemManager | PascalCase (GetDeviceName) — diferente dos outros managers |
✔ Resolved — all methods renamed to camelCase (getDeviceName, etc.) |
| 12 ✔ | SystemManager | GetDeviceInfo() bulk — does not exist in proto |
✔ Resolved — removed from Go; both APIs expose only per-RPC individual methods |
| 13 | SystemManager | GetMetrics: Go returns Metrics DTO; Java returns raw proto MetricsInfoResponse |
Create Metrics record in Java and convert |
| 14 | SystemManager (policies) | Go AllowUntrustedApps() → error; Java → boolean (same for Enable/Disable SSH, DevMode, RebootOnFailure) |
Normalize to void/error in both — returned boolean is redundant |
| 15 | SystemManager (update) | Go SendUpdate(ctx, []byte, chunkSize); Java Update(File) / Update(String) with internal chunking |
Add overload sendUpdate(byte[]) in Java for consistency with Go |
| 16 ✔ | PackageManager | PascalCase |
✔ Resolved — implemented in Go + Java methods renamed to camelCase |
Go ↔ Python Specific Divergences
| # | Manager | Issue (Go vs Python) | Suggestion |
|---|---|---|---|
| 1 | Client (TCP/TLS) | Go NewTCPClient attempts TLS by default; Python NewClientTCP is insecure by default. |
Align semantics: either both insecure by default, or both TLS by default. |
| 2 | Client context | Go exposes real context/cancellation; Python get_context() retorna placeholder. |
Implement equivalent timeout/cancel API in Python (or remove to avoid false parity). |
| 3 | WiFiManager | Go exposes reconnect flow; Python table shows Reconnect as not implemented. |
Add Reconnect(interface_name) in Python (or remove from compared API if not required). |
| 4 | EthernetManager | Go has explicit enable/disable operations; Python only has SetEthernetConfig/Enable DHCP via config. |
Add Enable(interface)/Disable(interface) in Python for high-level parity. |
| 5 | UartManager | Go provides Listen and ListenAsync; Python only exposes synchronous stream iterator (Listen). |
Add async/callback helper in Python (ListenAsync) for functional alignment. |
| 6 | SystemManager (update/policies) | Go includes update operations and policy toggles; several items appear as not implemented in Python. | Prioritize implementation in Python: SendUpdate, toggles for untrusted apps/dev mode/reboot on fail/SSH. |
| 7 | DevelopmentManager | Go exposes synchronous + async subscribe; Python only async/callback. | Add synchronous version in Python (or document limitation as intentional decision). |
| 8 | Shared DTOs | Go has types.go (ex.: SystemInfo, PowerResult); Python does not have consolidated equivalent module. |
Add equivalent Python D> |
⚠ Divergences
- Naming: Java uses
PascalCasein methods (GetDeviceName) instead ofcamelCaselike all other Java managers — inconsistency to fix. - Bulk DTOs: Go has
GetDeviceInfo(),GetCpuInfo(),GetOsInfo()which aggregate individual fields into a single DTO; Java has no equivalent. - GetMetrics: Go returns clean
MetricsDTO; Java returns raw protoMetricsInfoResponse. - Policies (Enable/Disable): Go returns
error; Java returnsboolean. - SendUpdate: Go accepts
[]byte+chunkSize; Java recebeFileouStringpath and chunks internally.
PackageManager
Application package management —
PackageManagerService| Method | Go | Java |
|---|---|---|
| List installed | GetInstalledPackages() ([]InstalledPackage, error) |
List<InstalledPackage> getInstalledPackages() throws PackageManagerException |
| Install/Update | InstallUpdatePackage(filePath string, chunkSize int) (bool, error) |
boolean installUpdatePackage(String filePath, int chunkSize) throws PackageManagerException, IOException |
| Remove package | RemovePackage(appName string) (bool, error) |
boolean removePackage(String appName) throws PackageManagerException |
✔ Resolved
PackageManager implemented in Go — aligned with Java.
DevelopmentManager
Device log streaming —
DevelopmentService| Method | Go | Java |
|---|---|---|
| Subscribe logs (sync) | SubscribeLogs(ctx, filter LogFilter, onEntry func(LogEntry)) error |
— (use subscribeLogsAsync) |
| Subscribe logs (async) | SubscribeLogsAsync(ctx, filter LogFilter) <-chan LogEntry |
StreamHandle subscribeLogsAsync(String app, String tag,
LogLevel minLevel,
Consumer<LogEntry> onEntry,
Consumer<Throwable> onError) |
⚠ Divergence
Go exposes both synchronous version (
SubscribeLogs) como canal (SubscribeLogsAsync).
Java only exposes callback version (subscribeLogsAsync).
Go est)",
"Get local name": "GetLocalName(request)",
"Set local name": "SetLocalName(request)",
"Set discoverable": "SetDiscoverable(request)",
"Classic scan": "StartScan(request)",
"BLE scan": "StartBleScan(request)",
"Bonded devices": "GetBondedDevices(request)",
"Bond device": "BondDevice(request)",
"Remove bond": "RemoveBond(request)",
"Connect device": "ConnectDevice(request)",
"Disconnect device": "DisconnectDevice(request)",
"Connection state": "GetConnectionState(request)",
"GATT connect": "GattConnect(request)",
"GATT disconnect": "GattDisconnect(request)",
"GATT discover": "GattDiscoverServices(request)",
"GATT read": "GattReadCharacteristic(request)",
"GATT write": "GattWriteCharacteristic(request)",
"GATT subscribe": "GattSubscribeCharacteristic(request)",
"GATT RSSI": "GattReadRssi(request)",
},
system: {
"API version": "GetApiVersion()",
"Device name": "GetDeviceName()",
"SoC model": "GetSocModel()",
"SoC vendor": "GetSocVendor()",
"Board model": "GetBoardModel()",
"Board vendor": "GetBoardVendor()",
"HW version": "GetHardwareVersion()",
"HW model": "GetHardwareModel()",
"System UUID": "GetSystemUuid()",
"Board serial": "GetBoardSerial()",
"CPU serial": "GetCpuSerial()",
"Machine ID": "GetMachineId()",
Architecture: "GetArchitecture()",
"CPU model": "GetCpuModel()",
"CPU cores": "GetCpuCores()",
"CPU threads": "GetCpuThreads()",
"CPU min MHz": "GetCpuMinMhz()",
"CPU max MHz": "GetCpuMaxMhz()",
"Total RAM": "GetTotalRAM()",
"OS name": "GetOsName()",
"OS version": "GetOSVersion()",
"Kernel version": "GetKernelVersion()",
Distro: "GetDistro()",
"Distro version": "GetDistroVersion()",
"Runtime version": "GetRuntimeVersion()",
"Build version": "GetBuildVersion()",
"Build date": "GetBuildDate()",
"Get metrics": "GetMetrics()",
"Send update": "N/A (not implemented in current python SDK)",
"Send update (path)": "N/A (not implemented in current python SDK)",
"Allow untrusted apps": "N/A (not implemented in current python SDK)",
"Disallow untrusted apps": "N/A (not implemented in current python SDK)",
"Untrusted apps?": "IsUntrustedAppsAllowed()",
"Enable reboot on fail": "N/A (not implemented in current python SDK)",
"Disable reboot on fail": "N/A (not implemented in current python SDK)",
"Reboot on fail?": "IsRebootOnFailureEnabled()",
"Enable dev mode": "N/A (not implemented in current python SDK)",
"Disable dev mode": "N/A (not implemented in current python SDK)",
"Dev mode?": "IsDevModeEnabled()",
"Enable SSH server": "N/A (not implemented in current python SDK)",
"Disable SSH server": "N/A (not implemented in current python SDK)",
"SSH enabled?": "IsSSHServerEnabled()",
},
packages: {
"List installed": "GetInstalledPackages()",
"Install/Update": "InstallUpdatePackage(timeout=60.0)",
"Remove package": "RemovePackage(app_name: str)",
},
development: {
"Subscribe logs (sync)": "N/A (not implemented in current python SDK)",
"Subscribe logs (async)": "SubscribeLogs(...)",
},
};
const tables = document.querySelectorAll(".table-wrapper table");
for (const table of tables) {
const sectionId = table.closest(".section")?.id;
const headerCells = table.querySelectorAll("thead th");
if (
sectionId &&
headerCells.length === 3 &&
headerCells[0].textContent.trim() === "Method" &&
headerCells[1].textContent.trim() === "Go" &&
headerCells[2].textContent.trim() === "Java"
) {
const pyHeader = document.createElement("th");
pyHeader.textContent = "Python";
table.querySelector("thead tr")?.appendChild(pyHeader);
const rows = table.querySelectorAll("tbody tr");
for (const row of rows) {
if (row.children.length !== 3) continue;
const method = row.children[0].textContent.trim();
const pySig = pyBySection[sectionId]?.[method] || "N/A (not mapped yet)";
const td = document.createElement("td");
if (pySig.startsWith("N/A")) {
td.className = "na";
td.textContent = pySig;
} else {
td.innerHTML = `${pySig}`;
}
row.appendChild(td);
}
}
}
})();