mlx90614 - mlx90614 infrared temperature#
Adaptation status unknown
Note
This page document is automatically generated by this file. If there is any error, please submit issue or help modify pr, thank you!
Example
-- Usage Examples
local mlx90614 = require "mlx90614"
sys.taskInit(function()
-- The hardware i2c mode 618 does not support this mode because 618 sending will send a stop signal.
i2cid = 0
i2c_speed = i2c.SLOW
print("i2c",i2c.setup(i2cid,i2c_speed))
-- Software i2c is common in this way and requires firmware compiled after 2023.5.8
--i2cid = i2c.createSoft(18,19)
mlx90614.init(i2cid)
while 1 do
print("mlx90614 ambient",mlx90614.ambient())
print("mlx90614 object",mlx90614.object())
sys.wait(1000)
end
end)
mlx90614.init(i2c_id)#
mlx90614 Initialization
Parameters
Incoming Value Type |
Explanation |
---|---|
number |
i2c bus hardware/software id |
Return Value
return value type |
explanation |
---|---|
bool |
Successful return true |
Examples
mlx90614.init(0)
mlx90614.ambient()#
Get mlx90614 ambient temperature
Parameters
None
Return Value
return value type |
explanation |
---|---|
table |
mlx90614 Ambient temperature |
Examples
local mlx90614_ambient = mlx90614.ambient()
log.info("mlx90614_ambient", mlx90614_ambient)
mlx90614.ambient()#
Get mlx90614 ambient temperature
Parameters
None
Return Value
return value type |
explanation |
---|---|
table |
mlx90614 Ambient temperature |
Examples
local mlx90614_ambient = mlx90614.ambient()
log.info("mlx90614_ambient", mlx90614_ambient)