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
Digitise an older engine - ESP32
#21
(2022-07-22, 05:03 AM)Techstyle Wrote: @boatingbaileys

I just tried your main.cpp but you may want to include in the readme that you have to add a couple of dependencies to the 'lib deps' section of platformio.ini - the bottom two lines:

Code:
lib_deps =
 ; Peg the SensESP version to 2.0.0 and compatible versions
 SignalK/SensESP @ ^2.0.0
 ; Add any additional dependencies here
 adafruit/Adafruit BMP280 Library@^2.6.3
 SensESP/OneWire@^2.0.0

I have your code up and running, now I am going to rewatch the episodes to try to decipher what's happening and how to connect it all up - thanks

Thanks for that - Completly forgot about the lib_deps. i'll update it now.
Reply
#22
@boatingbaileys

I got some of my project up and running:


1.  I adapted your Coolant sender code to work with my oil Pressure sender.  Haven't tried it yet but used a different scale table to map the resistance to the oil pressure, obviously
2.  Added 6 onewire sensors for a variety of stuff, tested and works well - oil temp, Aft Stateroom temp, Exhaust Elbow temp, Exhaust temp, Alternator Temp, and Transmission Temp
3.  Adapted your BMP280 code to the BME280, which seemed straight forward at first but it is not working, struggling a bit with it
4.  Used your RPM code as is, not tested yet
5.  Used your fuel consumption code but with a new fuel map for my engine and I changed the Signal K Key "propulsion.engine.fuel.rate", this comes with known units - m^3/s.  m^3/s is a bit inconvenient but is more correct by the Signal K Spec.  It does mean that the fuel map needs to be changed.
6.  another change I made was for consistency some of your Signal K keys state "propulsion.main.<whatever>" and some are "propulsion.engine.<whatever>".  I believe "main" refers to main engine and "engine" refers to the only engine - I commonised on "engine" for all of them 

I do fancy adding a flood sensor like you talk about for under the engine bay and near the raw water thru hull

thanks again for all this work
Reply
#23
(2022-07-28, 02:55 AM)Techstyle Wrote: @boatingbaileys

I got some of my project up and running:


1.  I adapted your Coolant sender code to work with my oil Pressure sender.  Haven't tried it yet but used a different scale table to map the resistance to the oil pressure, obviously
2.  Added 6 onewire sensors for a variety of stuff, tested and works well - oil temp, Aft Stateroom temp, Exhaust Elbow temp, Exhaust temp, Alternator Temp, and Transmission Temp
3.  Adapted your BMP280 code to the BME280, which seemed straight forward at first but it is not working, struggling a bit with it
4.  Used your RPM code as is, not tested yet
5.  Used your fuel consumption code but with a new fuel map for my engine and I changed the Signal K Key "propulsion.engine.fuel.rate", this comes with known units - m^3/s.  m^3/s is a bit inconvenient but is more correct by the Signal K Spec.  It does mean that the fuel map needs to be changed.
6.  another change I made was for consistency some of your Signal K keys state "propulsion.main.<whatever>" and some are "propulsion.engine.<whatever>".  I believe "main" refers to main engine and "engine" refers to the only engine - I commonised on "engine" for all of them 

I do fancy adding a flood sensor like you talk about for under the engine bay and near the raw water thru hull

thanks again for all this work

I am also wondering if the BME280 issues are something to do with my platformio - for whatever reason, I cannot compile successfully when Firebeetle32 is selected as the board - Mat - any chance you could post your platformio.ini file?
Reply
#24
(2022-07-28, 05:46 PM)Techstyle Wrote:
(2022-07-28, 02:55 AM)Techstyle Wrote: @boatingbaileys

I got some of my project up and running:


1.  I adapted your Coolant sender code to work with my oil Pressure sender.  Haven't tried it yet but used a different scale table to map the resistance to the oil pressure, obviously
2.  Added 6 onewire sensors for a variety of stuff, tested and works well - oil temp, Aft Stateroom temp, Exhaust Elbow temp, Exhaust temp, Alternator Temp, and Transmission Temp
3.  Adapted your BMP280 code to the BME280, which seemed straight forward at first but it is not working, struggling a bit with it
4.  Used your RPM code as is, not tested yet
5.  Used your fuel consumption code but with a new fuel map for my engine and I changed the Signal K Key "propulsion.engine.fuel.rate", this comes with known units - m^3/s.  m^3/s is a bit inconvenient but is more correct by the Signal K Spec.  It does mean that the fuel map needs to be changed.
6.  another change I made was for consistency some of your Signal K keys state "propulsion.main.<whatever>" and some are "propulsion.engine.<whatever>".  I believe "main" refers to main engine and "engine" refers to the only engine - I commonised on "engine" for all of them 

I do fancy adding a flood sensor like you talk about for under the engine bay and near the raw water thru hull

thanks again for all this work

I am also wondering if the BME280 issues are something to do with my platformio - for whatever reason, I cannot compile successfully when Firebeetle32 is selected as the board - Mat - any chance you could post your platformio.ini file?

Will do, and will respond to the above. Currently got limited access to internet but will be back i a couple of days.
Reply
#25
(2022-07-30, 10:58 PM)Boatingbaileys Wrote: Will do, and will respond to the above. Currently got limited access to internet but will be back i a couple of days.

Thanks, actually I got it working, I had to add some code to get the I2C interface to work.  I had to define the pins

Code:
Wire.begin(22,21)

where 22 is the SCL pin and 21 is the SDA pin.

I think you may have got around this by better defining the board you were using, but I had trouble with that in version 2.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)