ET-P1101 – A DIY ESPHome Panasonic Climate interface

5 2 votes
Article Rating
Subscribe
Notify of
guest
71 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Peter Colson
Peter Colson
September 27, 2023 15:46

Hi,

I am keen to add wifi connectivity to HA to 5 Panasonic aircon units in my holiday home in Spain and would love to be able to implement your solution.

However I would, if possible, much prefer to buy pre-built PCB’s than order all the separate components and then have to wait for 2 months (standard shipping) for the bits to arrive! I also appreciate that you don’t want the hassle of sending out units worldwide yourselves!

I see you have put the PCB spec on PCBWay and I can get them to make them for me. PCBWay also offer a PCB assembly service but I don’t think you have submitted the list of components and their board locations to PCBWay to enable them to supply pre-assembled units. Any reason why?

I would have thought it would be a perfect solution for you in that you’d get a 10% commission on a much higher value spend and your followers could get fully assembled boards much quicker (1 week?) and with much less hassle than having to order the components and build it themselves, should they choose to do so? I certainly would!

Peter Colson
Peter Colson
Reply to  michel
November 7, 2023 15:59

Now all the bits have finally arrived, I am assembling the boards and have just added the first cable but suspect the ones supplied (via your link) are wired the opposite way round to your picture of the finished module, and the one you point Bill Collins to here (bottom photo)? Photo of mine attached. Am I right in assuming the numbers (1,2,3,5) on the PCB correspond with the numbered pins on the CN-CNT plug? So on the cables supplied to me, 1=Black,2=Red,3=White and 5=Orange?

Hoping to get these finished so I can take them out to my house in Spain on friday – very much looking forward to installing them! Like Oliver M., I still wish I could have bought them fully assembled, though! You deserve to get more out of this.

CN-CNT-cable
Thomas
Thomas
October 11, 2023 11:17

Thanks so much for this, I only found the post after you guy’s stopped shipping them. There is a comment on PCB-way is that something I should wait to be addressed before ordering?

Lars Hammarstrand
Lars Hammarstrand
October 13, 2023 17:24

I already have a whole bunch of Wemos ESP32 D1 mini at home that I was thinking of trying to use for this purpose. Is there any possibility to post the circuit diagram as well?

Thanks in advance!

Lars Hammarstrand
Lars Hammarstrand
Reply to  michel
October 13, 2023 18:38

Sorry, my bad I wasn’t clear enough. I meant a pure electrical circuit diagram, not the PCB wiring diagram ie

ESP32-IoT-Shield-PCB-Schematic-Circuit-Diagram.png
Bill Collins
Bill Collins
October 18, 2023 05:51

Hey, I’ve ordered some of the boards and components and putting it altogether. I had some of the connectors for the CN-CNT connector already but I’m not sure of the pin out from the connector on the AC to map them properly. Do you have to have a pinout for the connector on the ACs?

Googling it is getting me more confused so it would be hugely helpful

Erling
Erling
October 29, 2023 12:36

Hello. This is great.
I have also connected a Wired DS18B20 temperature sensor. Which GPIO is this mapped to? Possible configuration for this?

Oliver M.
Oliver M.
November 3, 2023 16:23

Hello,
I have got 6 Panasonic aircons. I really appreciate your project, because I do not like cloud solutions in my home automation and knx interface would be six times 350€.
My soldering skills are really poor. PCBWay is offering an assembly solution. I filled the bom as far as I could, but some affiliate links do not work anymore. My electicals skill are also limited, so I do not have a clou what to put instead.
Can you give me advice? May be there are more like me, who would order already assembled devices with PCBWay. Components are C1, R1-R4 and R5
Many thanx in advance
Oliver

qwerty
qwerty
November 6, 2023 16:04

Hi Michel, thank you for this wonderful project. it is addressing exactly the use-case i was looking for.
However, i a technical issue.
I ordered all the parts you suggested (from the ALI links you provided), but i cannot get the ESP to connect to the WIFI.
i was googling a bit on this LOLIN ESP board, but there seems to be wifi problems with it.
I was wondering if you or other builder had experienced this when building this project?
And if so, how was it resolved.

I have also reached out to Lolin support on Aliexpress, but it would be good to get the community feedback.

qwerty
qwerty
Reply to  michel
November 7, 2023 12:12

yes. clicked the link and ordered at Ali.
I got the V2.1.0 version, which is supposed to be better then the v1.0.0 version. However, i am still struggling.
If you dont have any immediate recognition of this issue, i will dig a bit more. Perhaps i can load it with some other firmware (tasmota) to validate the HW.

Gaspar
Gaspar
Reply to  michel
November 8, 2023 02:36

Same problem here (same parts, v2.1.0 from the Ali link). When flashing the bin into the ESP module I get a bunch of errors. After some google, I also read that the C3 has issues.

substitutions:
    devicename: "ac-test"
    long_devicename: "AC Test"
    pcb_version: "230902"
    
esphome:
  name: ac-test
  name_add_mac_suffix: false ## if 'false' use different names/hostnames for each device!
  platformio_options:
    board_build.flash_mode: dio
  comment: "${long_devicename} ${pcb_version}"
  friendly_name: ac-test
  


esp32:
  board: esp32-c3-devkitm-1
  framework:
    type: esp-idf
  variant: ESP32C3


external_components:
  source: github://DomiStyle/esphome-panasonic-ac
  components: [panasonic_ac]


  
wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password
  ap:
    ssid: "${devicename} Hotspot"
    password: ########
    
captive_portal:
    
web_server:
  port: 80
  
logger:
  level: DEBUG


# Enable Home Assistant API
api:
  encryption:
    key:#########


ota:
  password: #######



uart:
  tx_pin: GPIO7
  rx_pin: GPIO6
  id: ac_uart
  baud_rate: 9600
  parity: EVEN


switch:
  - platform: restart
    name: "$long_devicename Restart"
  
climate:
  - platform: panasonic_ac
    type: cnt    
    ### or change "cnt" into "wlan" for DNSK-P11 ###
    name: "${long_devicename}"
    vertical_swing_select:
      name: "${long_devicename} Vertical Swing Mode"
    outside_temperature:
      name: "${long_devicename} Outside Temperature"

I added the line:

  platformio_options:
    board_build.flash_mode: dio

based on some google results, and at least it wont boot loop lock. If left to the default ‘qio’, the board enters a boot loop and I need to erase the flash all together before trying anything else.

With that config, If I check the logs I get (see below) but the device don’t connect to the wifi nor creates a hotspot.

ESP-ROM:esp32c3-api1-20210207
Build:Feb  7 2021
rst:0x15 (USB_UART_CHIP_RESET),boot:0xd (SPI_FAST_FLASH_BOOT)
Saved PC:0x4004c97e
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fcd5810,len:0x1684
load:0x403cc710,len:0x940
load:0x403ce710,len:0x2e48
entry 0x403cc710
I (24) boot: ESP-IDF 4.4.5 2nd stage bootloader
I (24) boot: compile time 12:10:23
I (25) boot: chip revision: v0.4
I (26) boot.esp32c3: SPI Speed      : 80MHz
I (31) boot.esp32c3: SPI Mode       : DIO
I (36) boot.esp32c3: SPI Flash Size : 4MB
I (40) boot: Enabling RNG early entropy source...
I (46) boot: Partition Table:
I (49) boot: ## Label            Usage          Type ST Offset   Length
I (57) boot:  0 otadata          OTA data         01 00 00009000 00002000
I (64) boot:  1 phy_init         RF data          01 01 0000b000 00001000
I (72) boot:  2 app0             OTA app          00 10 00010000 001c0000
I (79) boot:  3 app1             OTA app          00 11 001d0000 001c0000
I (87) boot:  4 nvs              WiFi data        01 02 00390000 0006d000
I (94) boot: End of partition table
I (98) esp_image: segment 0: paddr=00010020 vaddr=3c0b0020 size=240c0h (147648) map
I (129) esp_image: segment 1: paddr=000340e8 vaddr=3fc8f800 size=0235ch (  9052) load
I (131) esp_image: segment 2: paddr=0003644c vaddr=40380000 size=09bcch ( 39884) load
I (142) esp_image: segment 3: paddr=00040020 vaddr=42000020 size=a30f4h (667892) map
I (243) esp_image: segment 4: paddr=000e311c vaddr=40389bcc size=05b70h ( 23408) load
I (252) boot: Loaded app from partition at offset 0x10000
I (253) boot: Disabling RNG early entropy source...
I (264) cpu_start: Pro cpu up.
I (273) cpu_start: Pro cpu start user code
I (273) cpu_start: cpu freq: 160000000
I (273) cpu_start: Application information:
I (276) cpu_start: Project name:     ac-test
I (280) cpu_start: App version:      2023.10.6
I (286) cpu_start: Compile time:     Nov  8 2023 12:09:57
I (292) cpu_start: ELF file SHA256:  1738cdde84fe9787...
I (298) cpu_start: ESP-IDF:          4.4.5
I (302) cpu_start: Min chip rev:     v0.3
I (307) cpu_start: Max chip rev:     v0.99 
I (312) cpu_start: Chip rev:         v0.4
I (317) heap_init: Initializing. RAM available for dynamic allocation:
I (324) heap_init: At 3FC95E50 len 000468C0 (282 KiB): DRAM
I (330) heap_init: At 3FCDC710 len 00002950 (10 KiB): STACK/DRAM
I (337) heap_init: At 50000020 len 00001FE0 (7 KiB): RTCRAM
I (344) spi_flash: detected chip: generic
I (348) spi_flash: flash io: dio
I (352) sleep: Configure to isolate all GPIO pins in sleep state
I (358) sleep: Enable automatic switching of GPIO sleep configuration
I (366) cpu_start: Starting scheduler.
Gaspar
Gaspar
Reply to  michel
November 8, 2023 20:11

Framework is different. You use ‘arduino’ where I use ‘esp’idf’ as per the example. I’ll try that one, not sure if it will make a difference (I’m still new into this ESP bussiness 😛 )

Gaspar
Gaspar
Reply to  michel
November 9, 2023 03:25

I changed the framework and it kinda worked. First time I plugged it into the AC unit, it took ~1min and I started getting data on my ESPHome, but after 2~3min running, I got a timeout and that was it, can’t connect anymore.

That should prove that the config works, but now I need to figure out how to debug that DC and how to make it more reliable :/

Gaspar
Gaspar
Reply to  michel
November 12, 2023 20:15

During the weekend I was able to properly test/debug many options. Now I have a reliable configuration (flashed to other boards and work like a charm).
My last iteration is:

substitutions:
  devicename: esp32-airco-server
  long_devicename: Panasonic Aircon Server
  pcb_version: "230902"


esphome:
  name: "${devicename}"
  name_add_mac_suffix: true ## if 'false' use different names/hostnames for each device!
  comment: "${long_devicename} ${pcb_version}"
  platformio_options:
    board_build.flash_mode: dio


esp32:
  board: esp32-c3-devkitm-1
  framework:
    type: arduino
  variant: ESP32C3


external_components:
  source: github://DomiStyle/esphome-panasonic-ac
  components: [panasonic_ac]


  
wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password
  manual_ip:
    static_ip: xxx.xxx.xxx.xxx
    gateway: xxx.xxx.xxx.xxx
    subnet: xxx.xxx.xxx.xxx
  ap:
    ssid: "${devicename} Hotspot"
    password: xxxxxxxx
  output_power: 8.5db
  power_save_mode: none
    
captive_portal:
    
web_server:
  port: 80
  
logger:
  level: VERBOSE


# Enable Home Assistant API
api:
  encryption:
    key: "xxxxxxxxxxxxx"


ota:
  password: "xxxxxxxxxxxxx"



uart:
  tx_pin: GPIO7
  rx_pin: GPIO6
  id: ac_uart
  baud_rate: 9600
  parity: EVEN


switch:
  - platform: restart
    name: "$long_devicename Restart"
  
climate:
  - platform: panasonic_ac
    id: ac_server
    type: cnt
    name: "$long_devicename"
    vertical_swing_select:
      name: "$long_devicename Vertical Swing Mode"
    outside_temperature:
      name: "$long_devicename Outside Temperature"
    current_power_consumption:
      id: power_consumption_ac_server
      name: "$long_devicename Power Consumption"
      unit_of_measurement: W
      accuracy_decimals: 0
      device_class: power
      state_class: measurement
    nanoex_switch:
      name: Panasonic AC NanoeX Switch
      icon: mdi:air-filter


sensor:
  - platform: total_daily_energy
    name: "$long_devicename Total Daily Energy"
    power_id: power_consumption_ac_server
    filters:
        - multiply: 0.001
    unit_of_measurement: kWh
    device_class: energy


time:
  - platform: homeassistant
    id: my_time


# For revisions from 220722-01 and higer the optional temperature sensor is available.
# DS18B20 1-wire Temperature Sensor
dallas:
  - pin: GPIO18
#sensor:
# - platform: dallas
# # Check the dallas sensor address in the log file
# # For more info: https://esphome.io/components/sensor/dallas.html
# address: 0x540000001524be28
# name: "$long_devicename Temperature"
# id: temp

To consider:
Although I have the board version 2.1.0, it looks like reducing the wifi power output and disabling the power save mode, helps with the frequent disconnections.

wifi:
  output_power: 8.5db
  power_save_mode: none

I had to manually setup my ip address, since for reason mDNS is not working properly on my network.

Also network related, I setup a second access point to handle only my ESP devices (I suspect that my main AC was getting overload with too many devices connecting at once).

I kept the ‘arduino’ framework as per your configuration.

I’m pretty sure that I have the dallas sensor properly connected, but I still get on my logs:

[08:14:08][C][dallas.sensor:076]:   Pin: GPIO18
[08:14:08][C][dallas.sensor:077]:   Update Interval: 60.0s
[08:14:08][W][dallas.sensor:080]:   Found no sensors!

Do you have any hint on how to make it work?

Gaspar
Gaspar
Reply to  michel
November 12, 2023 20:47

I don’t think it has GPIO22. Based on this
https://docs.espressif.com/projects/esp-idf/en/latest/esp32c3/api-reference/peripherals/gpio.html

It only seem to have from 0 to 21. Also I’m not sure if the ‘mini’ is different than the plain ESP32 C3

Gaspar
Gaspar
Reply to  michel
November 12, 2023 21:29

I guess that with trial and error I’m going to get good at this. Not GPIO10, but GPIO1 !
d5 on you schematics seem to connect to pin 1 (green value) on that picture, and looking at
https://www.wemos.cc/en/latest/_static/files/sch_c3_mini_v2.1.0.pdf

that corresponds to GPIO1.

Also,

[09:26:15][C][dallas.sensor:076]:   Pin: GPIO1
[09:26:15][C][dallas.sensor:077]:   Update Interval: 60.0s
[09:26:15][D][dallas.sensor:082]:   Found sensors:
[09:26:15][D][dallas.sensor:084]:     0x2a3ce10457295c28

Thanks for all your help Michel!!

Gaspar
Gaspar
Reply to  michel
November 12, 2023 22:49

Not sure if my previous comment was sent. GPIO10 didn’t work, but looking at your diagram D5 seems to align with GPIO1 (https://www.wemos.cc/en/latest/_static/files/sch_c3_mini_v2.1.0.pdf)

And once switched to that GPIO, it worked like a charm.

Thanks for all your help Michel!

qwerty
qwerty
Reply to  michel
November 17, 2023 19:37

Guys, i thought would be good to give an update on my project.
I manage to get 2 devices working. The config posted above is proven to be working.
I had to add the “output_power: 8.5db” command to get the wifi working.

Couple of questions/comments:
1) what is the purpose of this nanoex_switch? I have removed it for now untill someone explain where its good for

nanoex_switch:
      name: Panasonic AC NanoeX Switch
      icon: mdi:air-filter

2) I suggest to you add a clear diagram of the wiring of the cable. I was struggling with this and i think i destroyed 2 ESP devices as a result of wrong wiring. There are some links to other projects where this wire is used, but even that was not good enough. Now ordering some new ESP’s to try to get the last airco working.

Peter Colson
Peter Colson
Reply to  michel
November 18, 2023 17:53

I have managed to get two of your boards working and installed in my Panasonic CS-ExxPKEW units with CN-CNT cables, although it is really difficult to access and connect to the CN-CNT socket (on the main PCB and just behind the bottom two connectors) and there is no provision for fitting a wifi module anywhere at the front of the unit. My units must be night on 10 years old so probably way before wifi modules were even considered.

Many thanks for adding the cable diagram as the cables I was supplied with (via your link) are definitely wired the opposite way around to yours! Might I also suggest you add the pin numbers to the diagram – if I am not mistaken, 5 is at the top and 1 at the bottom (with latch on the underside). It looks like my diligence on this might have saved me blowing a couple of the ESP boards!

I also had problems with the encryption key using a common | secret esphome_api_password as it appears each board needs a unique key which is set differently each time you run ‘prepare for first install’ using web.esphome.io. Clicking and copying the newly generated encryption key into the yaml code seemed to work fine for me.

I also had huge issues with wifi dropping out so much that I could rarely load the devices web server page properly, but I eventually found comments elsewhere on adding the output_power: 8.5 to the wifi section and all is now working reliably. I suggest you might want to add it to your code? Maybe it’s only an issue with some AP’s? I am using Ubiquiti AC Pro’s, if that helps.

Thank you all for the time you have spent overcoming the issues and updating the code and documentation. I must say I am pretty impressed with the results and now look forward to being able to warm up my house a couple of days before I get here the next time I visit in winter!  

lollo
lollo
Reply to  Peter Colson
February 23, 2024 09:20

Hi, could you share some photos of your installation, please? Also my unit is very old and have not a default space to fit a wifi module. Thanks a lot

Paul
December 14, 2023 10:56

Thank you for all your hard work inputting together this excellent project. A question, why have you gone with the ESP32-C3 Mini As opposed to a standard ESP32 ?

Paul
Admin
Reply to  Paul
December 14, 2023 14:47

The ESP32-C3 module was the only one which would fit in the enclosure which fits perfectly in the AC unit…. Any other module is wider, making it impossible to fit.

Paul
Reply to  michel
December 16, 2023 06:18

True.

nick Pt
nick Pt
December 25, 2023 01:11

How can I make it work with the remote controller CZ-RTC5B? or do I need to purchase
I recall you sold already made boards, do you still do this?

at7
at7
December 28, 2023 15:34

Hi,
I’m planning to build on P11 module.

By looking schematics above, I’m bit concerned about the Level shifters.
It seem OK from ESP TX to Panasonic direction, when ESP is driving 3V3 side.
However, I doubt, that RX part works when Panasonic is driving 5V side and ESP is receiving from 3V3 side.
Should RX part have e.g. resistor & 3v3 zener combination instead?

Are the existing software receiving/checking messages back from Panasonic?

Paul
Paul
Reply to  at7
February 4, 2024 00:38

The level shifters are bi-directional, so there will be no 5V signalling on the ESP module. Technically the ESP32 IO pins are 5V tolerant, so the module should handle it without a problem.

DAN
DAN
January 8, 2024 23:00

Thanks for a great project, I’m just soldering up my first board and have a question.

Do I need female pin headers to solder to the board to plug the male headers on the esp in to?

Murray
Murray
January 13, 2024 03:32

Thanks for putting this project together, I’ve just built 3 of these to replace the CZ-TACG1 modules in my CS-Z71VKR air conditioners, and they work brilliantly!

On one of them I soldered a second temperature probe and pushed it through the wall behind to measure the roofspace temp as well.

The only issue I had was with the length of the cz-tacg1 cables – I bought the 20cm long Ali express ones from the BOM link, but they were way too short to reach the cn-cnt connector from the wifi module location. I had to lengthen them to 50cm to reach.

There are plenty of 50cm ones available on Aliexpress.

All in all a great little project, and timely as it seems Panasonic comfort cloud is getting harder to use in Home Assistant now.

Cheers

b1ggi
b1ggi
January 25, 2024 01:31

Thanks for the tutorial, works perfectly

my CNT-CN cable wires from ali had a different colors, had some trouble converting your picture to mine, and i had to google some basic pcb/parts orientation and how to exactly install them, a better picture from the pcb without esp32 would have helped.
But all in all great project, thanks!

Last edited 2 months ago by b1ggi
Asher
Asher
February 1, 2024 11:54

Hi Espthings! Thanks for letting me buy the boards through PCBWay. I’ve got 2 completed and installed all working well.

Appreciated!

lollo
lollo
Reply to  Asher
February 23, 2024 10:29

Hi, if I choose the Assembly service on PCBWay, they send me the complete items, ready to work, with all components, cable and c3-mini? So, I have only to flash the firmware?

lollo
lollo
Reply to  michel
February 23, 2024 11:27

Excuse me, but why?

lollo
lollo
Reply to  michel
February 23, 2024 12:08

Oh, but I’m perfectly able to build it by myself and I love DIY. But, imho, why I have to place a lot of different orders, waiting months for deliveries (in the hope that no one will missing), pay for more than one shipping (I don’t know) and at the end find also the time to solder the components?
I don’t want offend anyone, you have my completely respect for all your hard work, mine is only a practical approach.
Thanks for all

Niels Eliasen
Niels Eliasen
February 7, 2024 11:07

Hello
Am I missing something.. or where is the enclosure for this ?

Niels Schjøtt Eliasen
Niels Schjøtt Eliasen
Reply to  michel
February 7, 2024 21:04

Obviously I am missing something … where ?

Niels Schjøtt Eliasen
Niels Schjøtt Eliasen
Reply to  michel
February 29, 2024 10:37

Hello Michel
My eyes have been examined multiple times over the years… and yes! I do have glasses! 🙂 🙂 🙂
I have another question though….
The Panasonic model that I have is a CS-NE9PKE-1 ,,,, and I do not have neither the Wi-Fi module installed nor can I find the “5-pin CN-CNT” as seen above … is there some hidden thing that needs to added/replaced/dug out ??
(I have checked multiple times … with glasses! 🙂 🙂 )

lollo78
lollo78
March 3, 2024 20:05

Hi, my Panasonic AC (NKE series) use the A75C3887 remote.
I have Econavi, Mild_Dry and NanoE-G, but I don’t know exactly what features I have to uncomment in the esphome config. OK for mild_dry_switch and econavi_switch, but
eco_switch and nanoex_switch (NanoEX is the same things of NanoE-G)?
Thanks

lollo78
lollo78
March 21, 2024 19:58

Hi, I have a different cable color. Please, could you check if this schematic is right? Thanks

WIRING
lollo78
lollo78
Reply to  lollo78
March 21, 2024 20:06

here the cable details

cable
lollo78
lollo78
Reply to  michel
March 21, 2024 20:20

Of course: color is irrelevant.
I read all the articles a lot of time, but my confusion is about what you mean with “notch down”.
This connector position is right or the right way is exactly the opposite side?
Sorry for my bad english.

Connector
lollo78
lollo78
Reply to  michel
March 21, 2024 21:05

So, my photo is right? I understood well?
Do you approve it? Thanks

Geert
Geert
March 29, 2024 15:40

Great job ! I also have an Etherea unit which has built-in wifi from the factory, are these ones supported ?

Translate »
71
0
Would love your thoughts, please comment.x
()
x