This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
DIY Battery Monitor - ESP32 based
#20
(2023-06-07, 10:48 PM)Techstyle Wrote: 1-wire pin is declared in the first line of code - pin 25 in my case, which is digital 2:

Code:
/// 1-Wire Temp Sensors - Exhaust Temp Sensors ///

  DallasTemperatureSensors* dts = new DallasTemperatureSensors(25); //digital 2

// Oil temp (fasten to oil P sensor) - /propulsion/engine/oilTemperature
  auto* oil_temp =
      new OneWireTemperature(dts, 1000, "/Oil Temperature/oneWire");

  oil_temp->connect_to(new Linear(1.0, 0.0, "/Oil Temperature/linear"))
      ->connect_to(
          new SKOutputFloat("propulsion.engine.oilTemperature",
                             "/Oil Temperature/sk_path"));

as for the INA219, that is a I2C device and therefore is called for in:

Code:
Wire.begin(21,22);                // join i2c bus (address optional for master)

there is default pins for this so you may be able to omit the pin numbers

thanks, got it. it is just set differetly than arduino boards. this visual studio does look a much more versatile tool. I got it working, sorta, until I apparently fried my board. Let's see what tomorrow brings. Hopefully a new board.
Reply


Messages In This Thread
DIY Battery Monitor - ESP32 based - by Techstyle - 2023-02-22, 07:26 PM
RE: DIY Battery Monitor - ESP32 based - by we9v - 2023-02-28, 05:16 PM
RE: DIY Battery Monitor - ESP32 based - by Tuomas_S - 2023-06-08, 09:23 PM

Forum Jump:


Users browsing this thread: 3 Guest(s)