Boatybits here, my RPM circuit - did it work? Great to see it getting used. 😎 Excellent ytube, " how I really did it" is thin on the ground for cruising sailors. well done.
It sure did, it works really well thanks very much. The Volvo gauge stills works which is what I also wanted and not to damage any of the engine wiring. I’ve said it before, I’m just putting the stuff together, the amazing work is coming from all of you building circuits and software so many thanks again.
@@BoatingwiththeBaileys Great, glad it works! JLCPCB is such a great place to make all these little circuits made into pcb's - treat yourself, my next project will have rj45 sockets as well so network cables can be used to keep the wiring tidy. Keep up the videos & fair winds. 😎
@@neverendingrefit759 Hi mate, I was wondering why using a zenner diode at D1 ? Is it just to protect the optocoupler in case of a surge ? Also it looks like OP just used a basic diode. So, what's the use for it and is it critical ?
@@furrane Dunno! 😁 The circuit I just cut n pasted then hoped for the best, guessing from some google that the zenor will protect against any big voltages seen from the alternator. Just glad it actually works 😎
This is the first time I have actually seen an actual installation, although preliminary. Excellent that it worked as you thought. Thanks for sharing. Cheers.
Thank you for yet another great and instructional video. Your content is helping me a lot with my own sensesp project. The rpm solution looks very elegant compared to the Hall effect sensor solution I am looking at, but I am afraid it is above my level currently. Cheers
Very interesting, thank you. Been using ESP for a while to monitor our fridges and Webasto heater ... wish I'd seen this project before buying CANBUS interface for our Volvo D2!
@@BoatingwiththeBaileys Yes, very simple ... opto-coupler across the dosing pump. Worked out how my mL each pump represents so can measure fuel use in L/hour or L/day and from rates, kW output. Not doing any controls. Liveaboard and when weather is cold, our 5.5kW unit can really drink the fuel!
@@BoatingwiththeBaileys Tried the k-line stuff and thought there must be a more simple way of monitoring this thing! Just use opto to trigger interrupt on rising edge ... interrupt routine times duration since last in mS and increments pulse count. Good luck.
Hello, a tip concerning the coolant-temperature sensor. M18x1.5 thread was widely used in the 70s-80s for Peugeot/Citroën/Renault. Reference is FAE 31020.
Thank you for making these videos! Subb'd. How long do you think the wires running to the sensor can be? Can I just integrate a cable induced voltage drop into the calibration?
Thanks for your comments. Yeah, I don’t see why you couldn’t adjust within the code. The ESP analogue side isn’t the best and you can buy a dedicated digital converter which is more accurate. I’m going to be doing a little more calibration with mine in an updated video. My cables are around 1m I would say if that helps
@@BoatingwiththeBaileys I have on my boat for second season. Used it on two cruises. GPS, AIS, instruments, LTE/4G internet with touchscreen in cockpit. Here is another video of actual set up on a boat with autopilot ua-cam.com/video/3zMjUs2X3qU/v-deo.html
Hi BoatingBailyes! I've been a subscriber to your channel for some time now. :) I'm trying to follow your ESP32 video series and am encountering some issues with the temperature sensor. I can't seem to find a temperature curve for the sensor used in my Mini Sole 17 engine anywhere. The best I can do is measure the resistance at various temperatures using the analog temperature gauge. However It won't be precise. I think I don't really get the part of the video where you change the temperature sensor for a 100ohms resistance in order to calibrate... It would be possible to calibrate the sensor without knowing any expected temperature value of my sensor? Thanks in advance!
Hello - thanks for being a long time subscriber, great to have you onboard. Your approach will work fine. It turned out my early code wasn’t quite correct which meant things went a little out of sync as the temperature climbed and I couldn’t really work out why. There is a later video on this when someone else building the same setup spotted this and now the code is correct online and in that later video. I think try what you are proposing, if you can get to any temperature and then measure the resistance and add that to your curve it should work. Repeat until you have a good curve to cover all the temps. What I was trying to do with the resistor was to say the engine is now at 80c so that’s 100ohms for example. But as a say the code was a little out and I was having to change values to get thing’s correct. Let us know how you get on with yours, a bit more feedback on this would be helpful to make sure it does work for everyone else. Mine works well now and my engine temps stay between 7 5and 90 now all the time. Good luck - Mat
Hi again. Did you manage to get a good test of the RPM counter ? - I cannot even get the code to work. Nothing related to the RPM counter appears in the serial monitor and the path does not show up in SK either. Do you need a working optocoupler setup to get it to show up in SK ? Is the code you are using the same as in github ? - pleased with your videos and help so far
Hi yeah RPM is working well. If you tap a small voltage on the end of that, something should happen. Can you see the path in SignalK? If you are monitoring it from the console, you should see it passing by with just a 0 and you should also see that in SignalK as a 0 also. I am using the same code as whats on Github. Do you have the same ESP as i do? and do you want to paste the code in here to just confirm everything?
@@BoatingwiththeBaileys thanks for reverting. Iam using a az -delivery ESP32 development kit. I dont see any anything in the serial monitor at all. Do you mean just applying 3.3v permanently on the GPIO iam using ? - yes please paste the section of your code just to be sure....
Sorry for the delay, the comment got suck in 'held for review' Yes, if you just take a wire from the pin you are using, to the 3v supply on the board without using your optocoupler, that should triger a couple of On/Offs and the code should see that as RPM. //RPM Application///// const char* config_path_calibrate = "/Engine RPM/calibrate"; const char* config_path_skpath = "/Engine RPM/sk_path"; const float multiplier = 1.0; auto* sensor = new DigitalInputCounter(16, INPUT_PULLUP, RISING, 500); sensor->connect_to(new Frequency(multiplier, config_path_calibrate)) // connect the output of sensor to the input of Frequency() ->connect_to(new SKOutputFloat("propulsion.main.revolutions", config_path_skpath)); // connect the output of Frequency() to a Signal K Output as a number Can you see propulsion.main.revolutions as a path in SignalK ? This code uses Pin 16. Is that the same pin on your board?
@@BoatingwiththeBaileys thanks got it working....my mistake.... Think i got confused by having to different versions of main.cpp opened.... Basically got rpm, cooling water, oil pressure, alternator and thrustbearing temps running now.... Just need to work out how to change the code so I can run 3 different bilge sensors from separate areas
@Klaus Mortensen - Glad you got it working. Copy the code and where it says bilge, call it something like bilge1 or a name of your choice and keep changing where it says bilge to this name. Give the SKpatch an individual name and also change the pin it reads for each 'bilge sensor' , I think its set to 25 for now and that should work, Other option is to trigger a bilge alarm from any of the sensors and wire them in parallel.
Thanks for sharing the code. Installed and running but struggling understanding the calibration part of the analog temperature sensors. I have adjusted the const float R1 = 809 so when connecting a resistor of 147 Ohm instead of the temp sensor it also shows 147 Ohm. However it seems like its no taking my calibration sets into consideration at all.
Hi - I haven't update the code online yet around the temp sensor as this isn't tested, but TechStyle over on the OpenMarine forum spotted an issue which i think i managed to work around using a higher R1 value than the actuall resisitor size. Try chaning this line: analog_input->connect_to(new AnalogVoltage(Vin,Vin)) Code will then look like the below. //// Engine Temp Config //// const float Vin = 3.3; const float R1 = 1000.0; auto* analog_input = new AnalogInput(36, 2000); analog_input->connect_to(new AnalogVoltage(Vin,Vin)) ->connect_to(new VoltageDividerR2(R1, Vin, "/Engine Temp/sender")) ->connect_to(new TemperatureInterpreter("/Engine Temp/curve")) ->connect_to(new Linear(1.0, 0.0, "/Engine Temp/calibrate")) ->connect_to(new SKOutputFloat("propulsion.engine.temperature", "/Engine Temp/sk_path")); I copied this code from the SensESP library which is still the same as what i've got online. I have a feeling my actual R1 resisitor is 100 Ohm where the code is set to 1000 Ohm. See if that helps?
@@BoatingwiththeBaileys Thanks... ended up changing the code as suggest, set R1 to 180 Ohm and deleted the line //->connect_to(new Linear(1.01, 0.0, "/Engine Temp/calibrate")) as I believe it either need to use the calibration curve points added manually or this linear calibration... not sure about though:-), so please correct me if I understand it wrong.
I think it’s there so that you can change the whole range by a set value, for example if your sensor was consistently 1 or 2 degrees out you can calibrate that out. Another handy tip is to delete both that and your curve line so that you see the calculated resistance value as the output.
Hi - Thanks for the comments, Thats possible and if you look at a video coming out this Saturday, you will see changes that have been made to a visualization app called Kip. That now has a feature where you can install it as an App. You could then boot straight to that app and go full screen to do exactly what you describe.
Can you give more details on the optocoupler you used to in the rpm circuit. Did you build it or buy it? I have seen some for sale but they have a 12V version and a 3-5V version. Which one would be needed?
This is the circuit design which came from Boatymonpy github.com/boatybits/boatymonpy/blob/master/Schematic_BoatMonitorSMD_Sheet_1_20200209152710.png and built the small unit myself. The output from my alternator on the W termianl is around 9v ac and i used an EL357N. You could buy one and then modify it. I would first check to see what the output on the W terminal is to ground and take it from there.
I would need to check the compontant on the board to be 100%. I definatly searched for it, but i remember strugling with several of these componants at that time. I've looked through my ebay orders and RS and can't find. It could have been switched out for a PC817 as thats come up a couple of times. I can check when next at the boat if that helps?
@BoatingwiththeBaileys no that's OK was just wondering as I can't seem to get one at the moment and was curious to see if you had the same issue. Keep up the good work 👍
Hello, Its attached to the top of the exhaust pipe with a stainless steel clamp. When the engine is running the temp here is low, around 20-25deg C, when then engine stops, you see a bit of residual heat build-up but nothing that will do anything to this sensor. They are rated to 125c i believe, well above the range of the exhaust hose. This video might also help, as it shows the installation on the engine and engine compartment. About 4:00mins into it you can see the sensor. ua-cam.com/video/II8URyYTFqc/v-deo.html
@LumpinLoaf ah, it's linked in the description- this is the site github.com/boatybits/boatymonpy/blob/master/Schematic_BoatMonitorSMD_Sheet_1_20200209152710.png
Hi, I haven't really got it fully waterproof, its in a box so its at least splashproof, about the same as other components within the engine bay. You could put it in fully waterproof box and try sealing any entry points with hot glue or something similar.
Boatybits here, my RPM circuit - did it work? Great to see it getting used. 😎 Excellent ytube, " how I really did it" is thin on the ground for cruising sailors. well done.
It sure did, it works really well thanks very much. The Volvo gauge stills works which is what I also wanted and not to damage any of the engine wiring. I’ve said it before, I’m just putting the stuff together, the amazing work is coming from all of you building circuits and software so many thanks again.
@@BoatingwiththeBaileys Great, glad it works! JLCPCB is such a great place to make all these little circuits made into pcb's - treat yourself, my next project will have rj45 sockets as well so network cables can be used to keep the wiring tidy. Keep up the videos & fair winds. 😎
@@neverendingrefit759 Hi mate, I was wondering why using a zenner diode at D1 ? Is it just to protect the optocoupler in case of a surge ? Also it looks like OP just used a basic diode. So, what's the use for it and is it critical ?
@@furrane Dunno! 😁 The circuit I just cut n pasted then hoped for the best, guessing from some google that the zenor will protect against any big voltages seen from the alternator. Just glad it actually works 😎
This is the first time I have actually seen an actual installation, although preliminary. Excellent that it worked as you thought. Thanks for sharing. Cheers.
Thanks. I will update this as it’s a little more permanent now although I’ve not quite got it powered how I want yet
Thank you for yet another great and instructional video. Your content is helping me a lot with my own sensesp project. The rpm solution looks very elegant compared to the Hall effect sensor solution I am looking at, but I am afraid it is above my level currently. Cheers
Thanks for your comments. Let’s us know if we can help you get your project up and running.
Very interesting, thank you. Been using ESP for a while to monitor our fridges and Webasto heater ... wish I'd seen this project before buying CANBUS interface for our Volvo D2!
Thanks for your comments, Im interested in what you are doing with the Webasto, can you give me some more information on that, please?
@@BoatingwiththeBaileys Yes, very simple ... opto-coupler across the dosing pump. Worked out how my mL each pump represents so can measure fuel use in L/hour or L/day and from rates, kW output. Not doing any controls. Liveaboard and when weather is cold, our 5.5kW unit can really drink the fuel!
@@svgabrielle What a great idea! I can feel another project coming on. Thanks for the reply.
@@BoatingwiththeBaileys Tried the k-line stuff and thought there must be a more simple way of monitoring this thing! Just use opto to trigger interrupt on rising edge ... interrupt routine times duration since last in mS and increments pulse count. Good luck.
Hello, a tip concerning the coolant-temperature sensor. M18x1.5 thread was widely used in the 70s-80s for Peugeot/Citroën/Renault. Reference is FAE 31020.
Thanks for the info! - Great alternative to anything with "Volvo Penta" on it!
Wonderful!
Many thanks ⛵️👍
Thank you for making these videos! Subb'd. How long do you think the wires running to the sensor can be? Can I just integrate a cable induced voltage drop into the calibration?
Thanks for your comments. Yeah, I don’t see why you couldn’t adjust within the code. The ESP analogue side isn’t the best and you can buy a dedicated digital converter which is more accurate. I’m going to be doing a little more calibration with mine in an updated video. My cables are around 1m I would say if that helps
Check also BBN Marine OS for raspberry pi4. Many free and opensource boat software packages preinstalled and preconfigured.
Thanks. How are you getting on with this setup?
@@BoatingwiththeBaileys I have on my boat for second season. Used it on two cruises. GPS, AIS, instruments, LTE/4G internet with touchscreen in cockpit.
Here is another video of actual set up on a boat with autopilot
ua-cam.com/video/3zMjUs2X3qU/v-deo.html
Hi BoatingBailyes!
I've been a subscriber to your channel for some time now. :)
I'm trying to follow your ESP32 video series and am encountering some issues with the temperature sensor. I can't seem to find a temperature curve for the sensor used in my Mini Sole 17 engine anywhere.
The best I can do is measure the resistance at various temperatures using the analog temperature gauge. However It won't be precise.
I think I don't really get the part of the video where you change the temperature sensor for a 100ohms resistance in order to calibrate... It would be possible to calibrate the sensor without knowing any expected temperature value of my sensor?
Thanks in advance!
Hello - thanks for being a long time subscriber, great to have you onboard.
Your approach will work fine. It turned out my early code wasn’t quite correct which meant things went a little out of sync as the temperature climbed and I couldn’t really work out why. There is a later video on this when someone else building the same setup spotted this and now the code is correct online and in that later video.
I think try what you are proposing, if you can get to any temperature and then measure the resistance and add that to your curve it should work. Repeat until you have a good curve to cover all the temps. What I was trying to do with the resistor was to say the engine is now at 80c so that’s 100ohms for example. But as a say the code was a little out and I was having to change values to get thing’s correct.
Let us know how you get on with yours, a bit more feedback on this would be helpful to make sure it does work for everyone else.
Mine works well now and my engine temps stay between 7 5and 90 now all the time.
Good luck - Mat
Hi again. Did you manage to get a good test of the RPM counter ? - I cannot even get the code to work. Nothing related to the RPM counter appears in the serial monitor and the path does not show up in SK either. Do you need a working optocoupler setup to get it to show up in SK ? Is the code you are using the same as in github ? - pleased with your videos and help so far
Hi yeah RPM is working well. If you tap a small voltage on the end of that, something should happen. Can you see the path in SignalK? If you are monitoring it from the console, you should see it passing by with just a 0 and you should also see that in SignalK as a 0 also. I am using the same code as whats on Github. Do you have the same ESP as i do? and do you want to paste the code in here to just confirm everything?
@@BoatingwiththeBaileys thanks for reverting. Iam using a az -delivery ESP32 development kit. I dont see any anything in the serial monitor at all. Do you mean just applying 3.3v permanently on the GPIO iam using ? - yes please paste the section of your code just to be sure....
Sorry for the delay, the comment got suck in 'held for review' Yes, if you just take a wire from the pin you are using, to the 3v supply on the board without using your optocoupler, that should triger a couple of On/Offs and the code should see that as RPM.
//RPM Application/////
const char* config_path_calibrate = "/Engine RPM/calibrate";
const char* config_path_skpath = "/Engine RPM/sk_path";
const float multiplier = 1.0;
auto* sensor = new DigitalInputCounter(16, INPUT_PULLUP, RISING, 500);
sensor->connect_to(new Frequency(multiplier, config_path_calibrate))
// connect the output of sensor to the input of Frequency()
->connect_to(new SKOutputFloat("propulsion.main.revolutions", config_path_skpath));
// connect the output of Frequency() to a Signal K Output as a number
Can you see propulsion.main.revolutions as a path in SignalK ? This code uses Pin 16. Is that the same pin on your board?
@@BoatingwiththeBaileys thanks got it working....my mistake.... Think i got confused by having to different versions of main.cpp opened.... Basically got rpm, cooling water, oil pressure, alternator and thrustbearing temps running now.... Just need to work out how to change the code so I can run 3 different bilge sensors from separate areas
@Klaus Mortensen - Glad you got it working. Copy the code and where it says bilge, call it something like bilge1 or a name of your choice and keep changing where it says bilge to this name. Give the SKpatch an individual name and also change the pin it reads for each 'bilge sensor' , I think its set to 25 for now and that should work, Other option is to trigger a bilge alarm from any of the sensors and wire them in parallel.
Thanks for sharing the code. Installed and running but struggling understanding the calibration part of the analog temperature sensors. I have adjusted the const float R1 = 809 so when connecting a resistor of 147 Ohm instead of the temp sensor it also shows 147 Ohm. However it seems like its no taking my calibration sets into consideration at all.
Hi - I haven't update the code online yet around the temp sensor as this isn't tested, but TechStyle over on the OpenMarine forum spotted an issue which i think i managed to work around using a higher R1 value than the actuall resisitor size. Try chaning this line:
analog_input->connect_to(new AnalogVoltage(Vin,Vin))
Code will then look like the below.
//// Engine Temp Config ////
const float Vin = 3.3;
const float R1 = 1000.0;
auto* analog_input = new AnalogInput(36, 2000);
analog_input->connect_to(new AnalogVoltage(Vin,Vin))
->connect_to(new VoltageDividerR2(R1, Vin, "/Engine Temp/sender"))
->connect_to(new TemperatureInterpreter("/Engine Temp/curve"))
->connect_to(new Linear(1.0, 0.0, "/Engine Temp/calibrate"))
->connect_to(new SKOutputFloat("propulsion.engine.temperature", "/Engine Temp/sk_path"));
I copied this code from the SensESP library which is still the same as what i've got online. I have a feeling my actual R1 resisitor is 100 Ohm where the code is set to 1000 Ohm. See if that helps?
@@BoatingwiththeBaileys Thanks... ended up changing the code as suggest, set R1 to 180 Ohm and deleted the line //->connect_to(new Linear(1.01, 0.0, "/Engine Temp/calibrate")) as I believe it either need to use the calibration curve points added manually or this linear calibration... not sure about though:-), so please correct me if I understand it wrong.
I think it’s there so that you can change the whole range by a set value, for example if your sensor was consistently 1 or 2 degrees out you can calibrate that out. Another handy tip is to delete both that and your curve line so that you see the calculated resistance value as the output.
@@BoatingwiththeBaileys Thanks, got it working now :-)
This is cool, can you program r pi so that it boots up like a car digital dash would or does it always start up like a Windows computer
Hi - Thanks for the comments, Thats possible and if you look at a video coming out this Saturday, you will see changes that have been made to a visualization app called Kip. That now has a feature where you can install it as an App. You could then boot straight to that app and go full screen to do exactly what you describe.
Can you give more details on the optocoupler you used to in the rpm circuit. Did you build it or buy it? I have seen some for sale but they have a 12V version and a 3-5V version. Which one would be needed?
This is the circuit design which came from Boatymonpy github.com/boatybits/boatymonpy/blob/master/Schematic_BoatMonitorSMD_Sheet_1_20200209152710.png and built the small unit myself.
The output from my alternator on the W termianl is around 9v ac and i used an EL357N. You could buy one and then modify it. I would first check to see what the output on the W terminal is to ground and take it from there.
Very good and informative videos. Is your platformIO files available for download ?
Hi, Thanks for your comments. The code is here github.com/Boatingwiththebaileys/ESP32-code
hi Mat, another quick question for you! did you use a el357(B)(TA)G or did you use a different model?
I would need to check the compontant on the board to be 100%. I definatly searched for it, but i remember strugling with several of these componants at that time. I've looked through my ebay orders and RS and can't find. It could have been switched out for a PC817 as thats come up a couple of times. I can check when next at the boat if that helps?
@BoatingwiththeBaileys no that's OK was just wondering as I can't seem to get one at the moment and was curious to see if you had the same issue. Keep up the good work 👍
Hola, saludos. El codigo de la interfaz donde estan los indicadores, usted mismo lo hizo?
Hola, se traduce como ‘ indicadores ‘, ¿no sé qué significa eso? El código base es del proyecto SENSE ESP en el que junté muchos ejemplos.
Do you put the exhaust temp sensor in or on top the pipe? Thx.
Hello, Its attached to the top of the exhaust pipe with a stainless steel clamp. When the engine is running the temp here is low, around 20-25deg C, when then engine stops, you see a bit of residual heat build-up but nothing that will do anything to this sensor. They are rated to 125c i believe, well above the range of the exhaust hose. This video might also help, as it shows the installation on the engine and engine compartment. About 4:00mins into it you can see the sensor. ua-cam.com/video/II8URyYTFqc/v-deo.html
@@BoatingwiththeBaileys thank you very much for the comment and the video!
Where did you find that documentation?
Hi - For the temp sensor or are you asking about something else?
Sorry the RPM diagram at 0:38.
@LumpinLoaf ah, it's linked in the description- this is the site github.com/boatybits/boatymonpy/blob/master/Schematic_BoatMonitorSMD_Sheet_1_20200209152710.png
And how you get this waterproof?
Hi, I haven't really got it fully waterproof, its in a box so its at least splashproof, about the same as other components within the engine bay. You could put it in fully waterproof box and try sealing any entry points with hot glue or something similar.
I spend hours detailing my engine but yours puts mine to shame... Just sayin' 🙂
Many thanks for your comments - I have to give some credit to Allegra’s first owner, he also did a great job