Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Send temperature from remote controller #27

Closed
hamishfagg opened this issue Feb 7, 2023 · 6 comments
Closed

Send temperature from remote controller #27

hamishfagg opened this issue Feb 7, 2023 · 6 comments

Comments

@hamishfagg
Copy link

Hi there,
Is your code able to send a temperature measurement from the remote (or from your PCB/wifi) to the indoor unit? I've had a look through the code and I don't think it's there but I might be missing it. Would it be hard to add?

@issalig
Copy link
Owner

issalig commented Feb 7, 2023

What do you mean? If it its possible to set a target temperature? If that's the question, the answer is yes and it is done by function air_set_temp at

void air_set_temp(air_status_t *air, uint8_t target_temp) {

@issalig
Copy link
Owner

issalig commented Feb 7, 2023

Well, re-reading your message maybe you mean the status messages that remote sends to indoor unit like this one:

!!!Note: lasts tests do not confirm the behaviour of bit 0

40 00 55 05 08 81 00 68 00 f1 
      |           |  |- 0110 1000 -> 104/2 -> 52 - 35 = 17   (temp)
      |-opc1         |-bit0 ON:1 OFF:0                 

In such a case, you are true I do not have a function to build these messages. I just decode them because I used remote and my pcb together. A function for sending temp status would be like the following one. Of course without wired controller you need an external thermometer to read the date and set it to sensor_temp variable.

void air_send_remote_temp(air_status_t *air, uint8_t value)  {
  //             00    01    02    03    04    05    06    07    08    CRC
  byte data[] = {0x40, 0x00, 0x55, 0x05, 0x08, 0x81, 0x00, 0x7C, 0x00, 0xE5}; //dummy msg
  //data[2]==0x55 data[5]==0x81   opcodes for this message
  //sensor temp
  data[7] = int((air->sensor_temp) + 35) << 1;
  //compute crc
  data[9] = XORChecksum8(data, sizeof(data) - 1);

  air_send_data(air, data, sizeof(data));
}

@issalig
Copy link
Owner

issalig commented Feb 8, 2023

If there is not remote and the pcb is alone, it would be necessary to have a ping function

void air_send_ping(air_status_t *air, uint8_t value)  {
  //             00    01    02    03    04    05    06    07    08   09   10    CRC
  byte data[] = {0x40, 0x00, 0x15, 0x07, 0x08, 0x0C, 0x81, 0x00, 0x00, 0x48, 0x00, 0x9F}; //dummy msg

  air_send_data(air, data, sizeof(data));
}

@hamishfagg
Copy link
Author

Thank you for all of your tips on this! I will have a go at it when I have some time.

@hamishfagg
Copy link
Author

I've discovered when trying to install my PCB that my heatpump is missing several components on the AB terminal board (most notably a transformer) so unfortunately I can't install it. But thanks for your help!

@issalig
Copy link
Owner

issalig commented Apr 11, 2023

Ooops. Could you post a photo? Maybe there is an easy fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants