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

Need example for Turn ON Hitachi AC #570

Closed
viv1ag opened this issue Nov 16, 2018 · 8 comments
Closed

Need example for Turn ON Hitachi AC #570

viv1ag opened this issue Nov 16, 2018 · 8 comments

Comments

@viv1ag
Copy link

viv1ag commented Nov 16, 2018

Dear Developers,

Could you please add the example for "Turn On Hitachi AC" as other AC examples have been added.
#HelpWanted

@crankyoldgit
Copy link
Owner

Assuming you've got a Hitachi A/C unit that uses the 28-byte message size, you should be able to pretty much just edit the TurnOnToshibaAC.ino example code by search & replacing the following:

  • Toshiba -> Hitachi
  • TOSHIBA -> HITACHI
  • toshiba-> hitachi

And the example will probably just work.

@crankyoldgit
Copy link
Owner

crankyoldgit commented Nov 17, 2018

Note: You will need to be using the current head of the master branch of this library, or a version greater than 2.5.2 for that level of Hitachi support. (i.e after 9a5e2ae)

@viv1ag
Copy link
Author

viv1ag commented Nov 17, 2018

Using IRrecvDumpV2.ino; I got following serial print:

Timestamp : 000043.529
Encoding  : HITACHI_AC1
Code      : B2AE4D91F0E1A4000000001078 (104 bits)
Library   : v2.5.2

Raw Timing[211]:
   +  3588, -  3456,    +   404, -  1286,    +   450, -   410,    +   458, -  1266, 
   +   452, -  1266,    +   452, -   410,    +   458, -   412,    +   464, -  1264, 
   +   454, -   410,    +   462, -  1266,    +   452, -   412,    +   460, -  1266, 
   +   454, -   412,    +   458, -  1268,    +   452, -  1266,    +   450, -  1266, 
   +   452, -   410,    +   458, -   414,    +   462, -  1268,    +   454, -   410, 
   +   458, -   414,    +   460, -  1270,    +   452, -  1266,    +   432, -   432, 
   +   458, -  1268,    +   452, -  1268,    +   426, -   438,    +   458, -   414, 
   +   460, -  1270,    +   428, -   436,    +   458, -   416,    +   436, -   440, 
   +   460, -  1272,    +   428, -  1292,    +   426, -  1292,    +   426, -  1290, 
   +   426, -  1292,    +   424, -   438,    +   432, -   442,    +   458, -   418, 
   +   440, -   438,    +   460, -  1272,    +   428, -  1292,    +   428, -  1290, 
   +   426, -   438,    +   450, -   422,    +   438, -   438,    +   460, -   416, 
   +   448, -  1286,    +   426, -  1294,    +   424, -   436,    +   432, -  1296, 
   +   428, -   438,    +   432, -   442,    +   434, -  1298,    +   424, -   438, 
   +   440, -   436,    +   434, -   442,    +   438, -   442,    +   436, -   444, 
   +   436, -   444,    +   434, -   444,    +   436, -   442,    +   436, -   444, 
   +   438, -   442,    +   436, -   444,    +   458, -   422,    +   460, -   420, 
   +   434, -   444,    +   438, -   444,    +   458, -   420,    +   436, -   444, 
   +   460, -   420,    +   436, -   444,    +   436, -   444,    +   448, -   432, 
   +   438, -   442,    +   436, -   444,    +   436, -   444,    +   436, -   444, 
   +   460, -   420,    +   436, -   444,    +   436, -   444,    +   436, -   444, 
   +   438, -   442,    +   460, -   420,    +   460, -   420,    +   460, -   418, 
   +   460, -   420,    +   460, -   420,    +   460, -   420,    +   460, -   420, 
   +   460, -  1274,    +   428, -   440,    +   434, -   442,    +   460, -   418, 
   +   460, -   418,    +   460, -   418,    +   460, -  1274,    +   428, -  1294, 
   +   426, -  1316,    +   404, -  1294,    +   426, -   438,    +   456, -   418, 
   +   458, -   420,    +   460

uint16_t rawData[211] = {3588, 3456,  404, 1286,  450, 410,  458, 1266,  452, 1266,  452, 410,  458, 412,  464, 1264,  454, 410,  462, 1266,  452, 412,  460, 1266,  454, 412,  458, 1268,  452, 1266,  450, 1266,  452, 410,  458, 414,  462, 1268,  454, 410,  458, 414,  460, 1270,  452, 1266,  432, 432,  458, 1268,  452, 1268,  426, 438,  458, 414,  460, 1270,  428, 436,  458, 416,  436, 440,  460, 1272,  428, 1292,  426, 1292,  426, 1290,  426, 1292,  424, 438,  432, 442,  458, 418,  440, 438,  460, 1272,  428, 1292,  428, 1290,  426, 438,  450, 422,  438, 438,  460, 416,  448, 1286,  426, 1294,  424, 436,  432, 1296,  428, 438,  432, 442,  434, 1298,  424, 438,  440, 436,  434, 442,  438, 442,  436, 444,  436, 444,  434, 444,  436, 442,  436, 444,  438, 442,  436, 444,  458, 422,  460, 420,  434, 444,  438, 444,  458, 420,  436, 444,  460, 420,  436, 444,  436, 444,  448, 432,  438, 442,  436, 444,  436, 444,  436, 444,  460, 420,  436, 444,  436, 444,  436, 444,  438, 442,  460, 420,  460, 420,  460, 418,  460, 420,  460, 420,  460, 420,  460, 420,  460, 1274,  428, 440,  434, 442,  460, 418,  460, 418,  460, 418,  460, 1274,  428, 1294,  426, 1316,  404, 1294,  426, 438,  456, 418,  458, 420,  460};  // HITACHI_AC1
uint8_t state[13] = {0xB2, 0xAE, 0x4D, 0x91, 0xF0, 0xE1, 0xA4, 0x00, 0x00, 0x00, 0x00, 0x10, 0x78};

I am using latest code from master branch only. This 108 bit data will not be worked with Toshiba example file.

@crankyoldgit
Copy link
Owner

Sorry, per comments in the code & PR #563 there is only detailed Hitachi Protocol support for the 28-Byte HITACHI_AC protocol variant. i.e. state[28]
There is no detailed support yet for the HITACHI_AC1 / 13-Byte protocol variant. i.e. state[13]

So, in order to turn on a unit that is using the HITACHI_AC1 protocol, you'll need to use code something like the following for now:

uint8_t state[13] = {0xB2, 0xAE, 0x4D, 0x91, 0xF0, 0xE1, 0xA4, 0x00, 0x00, 0x00, 0x00, 0x10, 0x78};
irsend.sendHitachiAC1(state);

If you can successfully analyse and decode the 13-Byte protocol into it's various parts, we can possibly add full support for that variant.

@crankyoldgit
Copy link
Owner

Hey @viv1ag, How are you going with this? Did it work for you?
As it's been about two week, if we don't hear anything from you soon we are going to assume this issue is stale and mark it closed.

@crankyoldgit
Copy link
Owner

Marking this Stale. Closing for now.

@phoenixxie0
Copy link

Timestamp : 001468.221
Library : v2.8.4

Protocol : HITACHI_AC
Code : 0x80080C02FD807F884840204400A000C00000000000000000800000D5 (224 Bits)
Mesg Desc.: Power: Off, Mode: 4 (Cool), Temp: 17C, Fan: 5 (High), Swing(V): Off, Swing(H): On
uint16_t rawData[451] = {3342, 1698, 422, 1254, 422, 408, 424, 408, 424, 408, 424, 406, 426, 408, 424, 408, 424, 408, 424, 408, 424, 410, 424, 408, 424, 408, 424, 1254, 424, 408, 424, 408, 424, 408, 426, 408, 424, 408, 424, 414, 418, 408, 424, 1256, 420, 1256, 422, 408, 424, 408, 424, 408, 426, 406, 424, 408, 424, 408, 424, 408, 424, 408, 424, 1256, 424, 408, 424, 1254, 424, 1254, 422, 1256, 422, 1256, 422, 1256, 422, 1256, 422, 410, 424, 1254, 422, 1256, 424, 408, 424, 408, 424, 408, 424, 408, 424, 408, 424, 408, 424, 408, 424, 408, 422, 1256, 424, 1256, 422, 1258, 422, 1254, 424, 1254, 422, 1258, 422, 1254, 424, 1254, 422, 408, 424, 410, 424, 408, 424, 1256, 422, 408, 422, 410, 422, 408, 424, 408, 424, 1254, 424, 408, 424, 408, 424, 1254, 424, 408, 424, 408, 424, 408, 424, 410, 422, 1256, 424, 408, 422, 408, 424, 408, 424, 408, 424, 410, 424, 408, 422, 408, 422, 410, 422, 1254, 422, 410, 422, 410, 422, 410, 424, 406, 426, 408, 424, 408, 424, 1254, 424, 408, 424, 408, 424, 408, 422, 1256, 424, 408, 422, 412, 420, 412, 422, 410, 422, 408, 422, 410, 422, 412, 420, 412, 420, 412, 420, 412, 420, 1258, 420, 412, 422, 1256, 422, 410, 420, 410, 422, 412, 420, 412, 420, 412, 418, 414, 420, 412, 418, 414, 418, 414, 418, 414, 420, 414, 418, 414, 418, 414, 418, 1258, 418, 1262, 416, 416, 416, 436, 396, 436, 396, 436, 396, 436, 394, 436, 396, 438, 396, 436, 396, 438, 394, 436, 394, 438, 394, 438, 394, 440, 392, 440, 394, 440, 392, 438, 392, 440, 392, 440, 392, 440, 392, 440, 390, 440, 392, 442, 390, 442, 390, 442, 390, 442, 390, 442, 390, 444, 388, 444, 386, 446, 386, 446, 386, 472, 360, 470, 362, 470, 360, 470, 362, 472, 362, 470, 362, 470, 362, 470, 362, 472, 360, 470, 364, 470, 360, 470, 362, 472, 360, 470, 362, 470, 360, 472, 360, 472, 360, 470, 362, 470, 362, 472, 360, 470, 362, 470, 362, 470, 360, 472, 362, 470, 360, 472, 360, 470, 362, 472, 360, 470, 362, 470, 360, 472, 362, 472, 360, 472, 360, 470, 360, 472, 360, 472, 362, 470, 362, 470, 362, 470, 360, 472, 362, 1316, 362, 470, 362, 472, 360, 470, 360, 472, 360, 472, 362, 472, 360, 472, 360, 472, 360, 472, 360, 472, 360, 472, 360, 470, 362, 472, 360, 472, 360, 470, 362, 470, 362, 472, 360, 472, 360, 472, 360, 470, 360, 472, 360, 472, 360, 472, 360, 1318, 360, 1320, 360, 472, 360, 1318, 360, 472, 360, 1318, 360, 472, 360, 1320, 358}; // HITACHI_AC
uint8_t state[28] = {0x80, 0x08, 0x0C, 0x02, 0xFD, 0x80, 0x7F, 0x88, 0x48, 0x40, 0x20, 0x44, 0x00, 0xA0, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0xD5};

How to write example file for Hitachi AC

@crankyoldgit
Copy link
Owner

See the following example code that can get you started for your particular device/protocol/needs:

But, please remember this FAQ

Repository owner locked as resolved and limited conversation to collaborators Feb 2, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants