Skip to content

@mega-yfue/eufy-sdk / mapCellValue

Function: mapCellValue()

ts
function mapCellValue(map, cell): "unknown" | "obstacle" | "free" | "carpet" | undefined;

What one cell of the map is — floor, wall, carpet or unexplored.

The plane packs four cells to a byte, two bits each, low bits first, in one run with no row padding: the cell at (col, row) is at bit (i & 3) * 2 of byte i >> 2, where i = row * width + col. undefined for a cell outside the map.

Parameters

map

VacuumMapPlane

cell

MapCell

Returns

"unknown" | "obstacle" | "free" | "carpet" | undefined

Independent and unofficial. Not affiliated with, endorsed by, or sponsored by Anker Innovations, Anker eufy, or eufy. "Anker eufy", "eufy" and "Anker" are trademarks of their respective owners. Use responsibly — rapid or failed logins can trigger captcha or temporary cooldowns.