×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

Weather radio don't want connect

  • Posts: 1185
  • Thank you received: 370
That’s awkward, there must be something special in your setup. What board do you use?
I think the only way is to add debugging messages into the mlx code of weather radio, especially around mlx.begin(). Maybe out of a strange reason this part never gets reached.
3 years 1 week ago #68977

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
 
I have the WeMos D1 Mini V3.1 (a real one and not a clone).
 

As I mentioned previously, the sensor and board works well with a simple code for the MLX
 
3 years 1 week ago #68980
Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
It's FIXED !!!

The code needs to be changed from:
to
results:
{"version":"1.12"}
{"MLX90614":1}
{"MLX90614":1}
{"MLX90614":{"init":true,"T amb":19.83001,"T obj":20.14999}}
{"MLX90614":{"init":true,"T amb":19.83001,"T obj":20.14999}}
{"MLX90614":{"init":true,"T amb":19.83001,"T obj":20.14999}}
{"MLX90614":{"init":true,"T amb":26.61001,"T obj":37.35}}
{"MLX90614":{"init":true,"T amb":26.61001,"T obj":37.35}}

 
The following user(s) said Thank You: Wolfgang Reissenberger
3 years 1 week ago #68981

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
in fact, just done another test and the line "return (error == 0);" can be commented out completely.
But it's quite slow to update the temperature I must say.
3 years 1 week ago #68982

Please Log in or Create an account to join the conversation.

  • Posts: 1185
  • Thank you received: 370
Many thanks for your feedback. I resolved it slightly different. The main bug was that the status was never updated once the initialization was successful:
/**    mlx.begin() always returns true, hence we need to check the I2C adress */
bool isMLX90614Present() {
  Wire.beginTransmission(MLX90614_I2CADDR);
  byte error = Wire.endTransmission();
  mlx.begin();
  mlxData.status = (error == 0);
  return (mlxData.status);
}
 
void updateMLX() {
 if (mlxData.status || (mlxData.status = isMLX90614Present())) {
   mlxData.ambient_t = mlx.readAmbientTempC();
   mlxData.object_t  = mlx.readObjectTempC();
 }
}

Could you please check if this works for you?
3 years 1 week ago #68985

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
thanks for the update, that however breaks everything. Nothing comes out from the W/V/T etc commands..
correction:
I had selected the wrong baud, hence nothing came out.

However, it's back to the original issue:
Weather Radio V 1.12
{"MLX90614":{"init":false}}
{}
null
Last edit: 3 years 1 week ago by Gonzothegreat.
3 years 1 week ago #68987

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
it works with this:
3 years 1 week ago #68989

Please Log in or Create an account to join the conversation.

  • Posts: 1185
  • Thank you received: 370
and what happens if you comment out the begin/endTransmission additionally?
3 years 1 week ago #68991

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
with this, it can see the sensor but not getting the right values


{"MLX90614":{"init":true,"T amb":1037.55,"T obj":1037.55}}
{"MLX90614":{"init":true,"T amb":1037.55,"T obj":1037.55}}
{"MLX90614":{"init":true,"T amb":1037.55,"T obj":1037.55}}
3 years 1 week ago #68992

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
This works:
Last edit: 3 years 1 week ago by Gonzothegreat.
3 years 1 week ago #68993

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
I do get the following:
{"MLX90614":1}
{"MLX90614":{"init":true,"T amb":20.11001,"T obj":22.35}}
{"MLX90614":{"init":true,"T amb":20.11001,"T obj":22.35}}
{"MLX90614":{"init":true,"T amb":20.11001,"T obj":22.35}}
3 years 1 week ago #68994

Please Log in or Create an account to join the conversation.

  • Posts: 1185
  • Thank you received: 370
Hm, but that's syntactically problematic, since you do not return a value although the function is declared as boolean. What happens if you add a "return(true);" ?
3 years 1 week ago #68996

Please Log in or Create an account to join the conversation.

Time to create page: 0.374 seconds