Posts: 2,151
Threads: 20
Joined: Jun 2016
Reputation:
63
2020-02-15, 03:44 AM
(This post was last modified: 2020-02-15, 03:44 AM by seandepagnier.)
Is the voltage related to how fast it spins?
You might use a diodes to convert this to a digital signal within the range an uC can sample it.
Posts: 205
Threads: 31
Joined: Apr 2017
Reputation:
2
I was thinking of a bridge rectifier and a voltage divider. That would give me 2 pulses per rotation. I am concerned about the voltage drop when it slows. I don't know how low before a esp would fail to detect the pulse. i could then just find the time between pulses to determine the speed. a square wave would be best. I don't have a oscilloscope so this is all guess work.
Signet claims there sensors are self powered.. I doubt i could get enough current to power a nano. i think for a esp i needs in the .08 amp range. It would be nice to have self powered sensors. The old analogue display is on the boat i think i am going to have a peek. it is -7 today and -25 tomorrow and -stupid till next week. May be if it is calm i will get brave and go to the boat.
I think i need a Radioisotope piezoelectric generator to solve my energy issues on the boat. You can get 80ish years before you have to refuel.
The other thought is the adc if the voltage is linear or reasonable so.
Posts: 205
Threads: 31
Joined: Apr 2017
Reputation:
2
So I can read the device just by sending it to a digital pin on the esp32. I want to know if i should send it to SignalK or Send it as nmea 1083 and if so what sentence.?
Posts: 205
Threads: 31
Joined: Apr 2017
Reputation:
2
Thanks, ya i think i will go the sk way. It looks like the better solution. I have coded both ways before. I just hacked most of my wind sensor code as i need the wind speed code and ditched the direction and anchor light code. I have a few esp32 dev v1 module. they suck because of the size but they work.
Posts: 205
Threads: 31
Joined: Apr 2017
Reputation:
2
Well I have it sending data to signalK need to clean up the bounce a bit. A scope to see the signal i am getting would be nice.
Any recommendations on a nice small Power converter for an esp32. 12 -16 v -> 7 to 9 volts. I am using a esp32 devkit V1.
My esp goes into ap mode if it does not have or cant find openplotters' credentials. from my phone or laptop i can then set the connection info.
I still have to test if i can do OTA updates.
I cant seem to get SignalK to generate a VHW sentence for Opencpn...
Posts: 205
Threads: 31
Joined: Apr 2017
Reputation:
2
2020-03-07, 08:14 PM
(This post was last modified: 2020-03-07, 10:10 PM by ddelorme.)
thanks I just ordered 6.
I also ordered a few esp8266. I think they would work better for this as I only need 1 digital pin. About and half the power requirements.
Posts: 205
Threads: 31
Joined: Apr 2017
Reputation:
2
woohoo It works.. After several weeks of looking at the code then putting it off and doing other stuff. I used the buck converter abarrow suggested and rewrote the code for a esp8266. It works... I can update the code via wifi and use wifimanager to set the connection to the skserver. It updates the skserver every .5 seconds. power is greatly reduced from a esp32... it all fits on a gikfun proto board and into a printed case that can mount on the bulkhead near the device.
I need to add a fuse and a small switch at the device end but it looks like a workable solution.
I have 3 wifi devices now a wind sensor, battery monitor, and this speed though water sensor.
It would be nice to add a display on the wifimanager page to display sensor data when not connected to the skserver.
I always feel bad about leaving all the unused pins. But I want to keep the traffic down.
Well day 12 of not leaving the house hope everyone is safe. It looks like i am selling my Tanzer 26 and moving to the BC coast as soon as everything settles down. Time for a new boat and a new chapter in my life.