question

nebulight avatar image
nebulight asked

Raspberry Pi, ADC and tank sender with custom ohms 0-90?

So I finally installed my pi and touch screen in my camper van. Everything is working fine on the victron product side but when I went to disconnect my tank sender from the manual gauge to install on the Expander PI ADC board and it still said shorted. I couldn't figure out what was wrong, then I take out the voltmeter and found that the tank sender is a 0 empty to 90 ohms full.... *facepalm*. I bought my camper van from someone else and the sender was already installed and I just assumed it was a standard NA 240-33ohm sender. Instead of getting a new tank sender, is it possible to change the settings somehow on the Pi to read this tank sender?

At least the panel turned out well (looks like I can't upload any photos).


Venus OSVenus GX - VGX
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

3 Answers
nebulight avatar image
nebulight answered ·

I found this in the file sensors.h. Can I just change those values? However I don't know much about programming, after I make this change, do I need to compile or just drop this file on my Pi?


// defines for the tank level sensor analog front end parameters

#define TANK_LEVEL_SENSOR_DIVIDER (680) // ohms

#define EUR_MAX_TANK_LEVEL_RESISTANCE (180) //ohms

#define USA_MAX_TANK_LEVEL_RESISTANCE (240) //ohms

#define USA_MIN_TANK_LEVEL_RESISTANCE (30) //ohms

8 comments
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

kai avatar image kai ♦ commented ·

I'm just guessing from the context - yes you would have to recompile / make for the header file changes to take effect

0 Likes 0 ·
Show more comments
dunnp avatar image dunnp commented ·

Where can I find that file? I have the same problem - 0-90 ohm sender.

Phil

0 Likes 0 ·
Show more comments
nebulight avatar image
nebulight answered ·

are bumps allowed? I never figured this out and I'm considering getting a Cerbo GX when the come out. Maybe it would be nice to have the software give you the option to assign your tank sender settings? In the US, there are a lot of different values.

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

tonyjobson avatar image
tonyjobson answered ·

https://community.victronenergy.com/questions/41629/tank-sensor-calibration.html

custom sensors are in the new or soon to be released beta firmware for the Venus physical devices so we should hopefully be able to calibrate full and empty and then cope with a wide range of restive sensors.

(I've not setup my pi to test any of this yet. i was doing my research before buying anything.)

My use case was: (and for search engines) : Gas it. Gas-it sender 0 to 90 Ohms and 95 Ohms



2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.