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

Add support for internal CAN controller #6

Open
mkaiser opened this issue Nov 2, 2023 · 4 comments
Open

Add support for internal CAN controller #6

mkaiser opened this issue Nov 2, 2023 · 4 comments

Comments

@mkaiser
Copy link

mkaiser commented Nov 2, 2023

hey there,

in ESPHome 2023.10 I contributed some patches to support the internal CAN controller (our heatpumps need 20kbits) of newer ESP32 chips (see https://esphome.io/components/canbus.html?highlight=can)

image

Although I have not managed to get all my heatingpump sensors to work, I want to share my results :)
( I guess it it still something with the different CAN addresses of my TTF-07cool, but it is definitvely a software-issue, because the results are the same when I use the mcp or the internal CAN)

I forked your project and inserted some comments meant as a template to use the internal CAN controller instead of the external SPI-connected mcp2515 (heatingpump.yaml).
Also, I renamed the can_controller id from "my_mcp2515" to the more generic "my_can_controller" in heatingpump.h

mkaiser@954405d

When I uploaded to github, I did not notice, that my code beautifier messed up...

So my questions here are:

  • Would you accept such PRs in general?
  • Could you define some code formatting, so merging would be easier?
  • What do you think of refactoring the YAML-code a bit more, e.g., using the insertion operator?

https://esphome.io/guides/configuration-types.html#yaml-insertion-operator

BR

Martin

@bullitt186
Copy link
Owner

Hey Martin, Thanks a lot for your contribution; I started some significant refactoring to allow a more modular approach but haven't checked in the changes yet. I'll review your PR in the next days and merge it with my changes. THanks a lot already!

@mkaiser
Copy link
Author

mkaiser commented Nov 2, 2023

sounds good :)

let me know, if I can help / test something

@mkaiser
Copy link
Author

mkaiser commented Dec 31, 2023

Hey Martin, Thanks a lot for your contribution; I started some significant refactoring to allow a more modular approach but haven't checked in the changes yet. I'll review your PR in the next days and merge it with my changes. THanks a lot already!

hey,

I don't wont to push too much - but are there any updates?

btw. some of the HA community guys which participate often in the heatpump / can-related thread gathered here:

https://discord.gg/y3Vp3RJTGq

If you join, we could maybe help a bit :)

@cbialobos
Copy link

Hi, I'm using the integrated can controller:

canbus:

  • platform: esp32_can
    tx_pin: GPIO2
    rx_pin: GPIO1
    id: my_mcp2515
    can_id: 700
    use_extended_id: false
    bit_rate: 20kbps
    on_frame:

I'm using the m5stack S3 lite and the CAN bus Module, Grove

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

3 participants