New beta version of openXsensor (=openXvario)

Development & General Chat for the superb openxvario project.

Moderator: rainer

User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

I'm going for ebay.. Can find them nearly at the same price, and if something happens PayPal gives me the money back..

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW

User avatar
bob195558
Posts: 2377
Joined: Sun Dec 16, 2012 7:24 pm
Country: United States
Location: New England, Vermont
Contact:

Re: New beta version of openXsensor (=openXvario) (Shop Safe)

Post by bob195558 »

I have used Bank of America (if you can use it in Euro) and they have "Shop Safe" which you can make a
shopping card (print it out with its own card numbers), set the max amount and the number of months it is valid for
which when used your purchase shows on your real credit card account. It gives you some protections.
I use this all the time when PayPal is not available: (www.bankofamerica.com).
No cost to use it too, but I like PayPal better also when it is available.

Bob B.
Er9x on 9x radio, with Smartieparts Programmer and TelemetrEZ Board.
ErSky9x on Taranis, Sky9x, 9Xtreme radios.
3D-Printing: (https://openrcforums.com/forum/viewforum.php?f=129).
ReSt
Posts: 1581
Joined: Tue Dec 27, 2011 11:34 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by ReSt »

on ebay with free shipping 10,80$
http://www.ebay.de/itm/191600135686?ssP ... 1436.l2648

Reinhard
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

I believe that would be only available in your country?? :)
João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

ReSt wrote: Wed Mar 01, 2017 9:56 pm on ebay with free shipping 10,80$
http://www.ebay.de/itm/191600135686?ssP ... 1436.l2648

Reinhard
Yeah,that is the same I saw, hence my comment above.. And there are others :)
Thanks anyway.

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW

User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

I am trying to setup RPM, and I'm using a hall effect switch connected to oXs pin 8. The sensor is the Allegro A3144. Datasheet attached to this post.
The output of this sensor is open collector and goes low in the presence of a magnetic field.

My question is, do I need a pullup resistor on the sensor's output as it is open collector, or does the oXs set the internal pullup on pin 8?

Thanks

João
Attachments
Allegro Hall Effect Switch A3144-Datasheet.pdf
(735.22 KiB) Downloaded 222 times
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by mstrens »

I checked the code and in principe the internal pullup is activated.
You can easily check it if you measure the voltage when the pin is unconnected (or better connected to ground with a high value resistor e.g. with 200k to ground, voltage should still be quite close from Vcc)
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Thanks, will check that..

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Hi, I have a problem.. I am using the oXs in D8 mode (no S.Port) and I am trying to send Volt_1 and Volt_3 as A3 and A4.
The problem is that Ersky9x is not detecting it. Mike asked me to find out what ID's A3 and A4 are using. Please see quote from Mike's post.
FrSky 'D' telemetry doesn't support A3 and A4, only SPort does. If the oXs is sending something for A3 and A4, it must be using IDs I don't know about. Can you find out what IDs it is using?
So, what ID's are A3 and A4 using? Or is it not possible at all to use them with HUB telemetry?
If not, what fields would you suggest to send 2 extra voltages??

Thank you

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by mstrens »

As far I know A3 and A4 have been added by Frsky in the Sport protocol.
I have no ID for them in Hub protocol.
If Mike know the Id's I could add it.
Currently I suggest using T1 and T2 which are supported by Hub protocol
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Thanks a lot, that's all we needed to know.. There are no ID's. I will try the T1 and T2 fields..
Hmm, I have a problem though. I just remembered I might want to send the engine temperature as well in the near future. Just trying to find a suitable sensor. Which other field would you recommend for sending a voltage?
I am testing it all before I install it in the model, of course..
Thanks

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by mstrens »

you can use AccX,Y or Z too.
Still if I remember wel, the Tx (at least openTx) discards the last one or 2 digits being sent by oXs. This is perhaps tot the case for your Tx firmare.
Anyway, with the scaling parameters on oXs (or those on Tx side) you can easily fix this.
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Thanks. There are some possibilities then. I'm not sure what Ersky9x does with the last couple of digits, but I guess I will find out soon ;)
We have a very nice and powerful tool in Ersky9x, which are the scalers ;) I'm sure I will make good use of them :)
By the way, I just thought of the fuel field as a possible candidate. But maybe I will try to mess with capacitive sensors to measure the fuel quantity in the tank. I know frsky has something like that, but I would like to achieve something with better resolution, if possible. Always learning :D

Thanks a lot again.

João

My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by mstrens »

FYI (but probably you know it already) , latest version of oXs support an external ADC too in order to get more accurate voltage measurements if needed.
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Thanks, yeah I know, I just didn't get one of those boards yet.
2 of the voltages are to be read from 2 LiPo batteries, one with one cell and the other with 2 cells. The third voltage is supposed to detect if the glow plug is bad. This I will have to test to see if it works..

Thanks

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Hi Mstrens, new challenge here ;) I have been messing with this, Please have a look :)

https://www.youtube.com/watch?v=TWWXsZ9W0j0

Any possibility to implement something like this on oXs?
we would need some calibration values because of different tank sizes with different aluminum foil sizes and different resistor values. But in the code I found it appears to be possible to adjust the sensitivity. That, as I said depends on several factors.
I can post the code if you need it.. It uses a library for the capacitive sensor..
One thing that it does that I don't like is that even if the tank if full, if you reset the arduino, it will show the tank as Empty.
It would be nice if this could be changed and depend only on the capacitance measured. So if the tank had fuel insisde, it would show the amount.

Thanks for looking. A lot of testing needed I would say. :)

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
RightRudder
Posts: 241
Joined: Tue Jan 15, 2013 9:41 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by RightRudder »

Very cool idea Joao. Does it work with non polar fluids like perol?
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

I don't know.. Will have to test. Will do later. I have a couple methanol powered and one petrol powered models.
The good thing is that if it works, it may be possible to cover the sides of the tank completely with the 2 foil electrodes, or 2 nets, and have a good reading with the plane in different positions. As i said, it needs loads of testing..

I also like the idea of keeping electricity out of the tank :D

I have been playing with oXs and possible sensors for IC powered models. On the next video you can see that my radio detects if the glow plug goes bad. Sensors are all connected to oXs of course.

https://www.youtube.com/watch?v=hmNHB02mrBI

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Mstrens, would you try to implement this on oXs? I'm asking because if not, then all this work that I'm doing is useless and it is not worth doing it :)

Thank you

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by mstrens »

I would have to loot at. I am currently implementing reading the magnetometer from the gy-86 module.
I do not know yet if it is accurate enough and if it is posible to add it oXs (taking into account the other tasks performed by oXs simultanously).
I think Frsky or Hitech had also fuel sensors based on capacitor measurement (with a patch to be applied on the outside of the tank) but they had several sets of plates and where able to detect just 4 level of liquid. It is not a continous measurement but it is probably more reliable.
Would this not be better?
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

I don't know, I have seen a video of the frsky sensor working and it didn't seem to work very well.
It is very difficult to measure liquids when the tank is moving, and that is what I'm trying to improve at the moment. I personally believe we can do much better than the hitec and frsky sensors, as the telemetry systems, specially the oXs and both open source radio firmware, are much better than when those sensors were developed.
I would like to see the values on the radio in percentage or any other form, and then create my own different levels alarms.
I am seeing the numbers increasing or decreasing on the serial monitor as I fill or empty the tank. I wouldn't say that the numbers change proportionally, but they do increase and decrease.
There are a couple of problems though.
Every different tank will need calibration, but so does the voltage sensor, the acc sensor, the amp sensor, etc, right?? :)
What is different here is that the calibration might be a bit more tricky because capacitance will depend on the size of the tank, on the size of the plates and how they are placed, and on the value of the resistor that makes the RC filter together with the capacitor (tank). We need to bring the values to a range that needs to be determined, or being able to convert any range to 1024 steps. Does this sound right? ;) :)
The output need to be averaged, that is for sure. Even if the consecutive values are quite close to each other if the tank does not move.

There is another little annoying problem in the code, or even in the library itself which is, when we reset the arduino, it starts measuring as if the tank was empty, showing low numbers, even if the tank is more than half full for example.
But someone that understands about programming could probably fix this if at all possible.
The arduino code I'm using is actually very simple. All the work seems to be made by the arduino library..
Will attach the code and library to this post in a second, so you can see it for yourself.
I have just added the code for the 3 level LEDs you saw on the video. All the rest is unchanged..

Thanks for looking

João

EDIT: Zip file with the code and Library attached..
Attachments
Capacity_Sensor_Code and Library.zip
(8.14 KiB) Downloaded 153 times
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

Will you change these two settings on the next release you post?

"#define MSEC_PER_BYTE" needs probably to default to "7" again, otherwise it may cause problems when sending the Cell's voltage, as per my earlier testing.

Also the delay value in " if ( millis() > 1000 ) oXs_Out.sendData();" needs to be changed to at least 1500 to avoid the false alarms at power ON.
With a vario and ACC 1000 is definitely not enough..

Can't remember at the moment if there was another setting that needed changing :)

Thank you

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by mstrens »

Did you had a look at this.
I presume it should be much more accurate than just using an arduino program.
Furthermore, there are 4 channels. It means that it should be possible to put 4 sets of plates on the tank and so better to get some averages when liquid is moving.
This kind of chip reduces the CPU needed on Arduino side.
https://create.arduino.cc/projecthub/te ... 004-9333c7
The chip it self is not so expensive (5€) but if you buy an already module then price increases to 25/45 €.
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by mstrens »

Another solution could be to use a differential pressure sensor like the MPXV7002DP.
This is already supported by oXs.
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

mstrens wrote: Fri Apr 07, 2017 11:22 am Did you had a look at this.
I presume it should be much more accurate than just using an arduino program.
Furthermore, there are 4 channels. It means that it should be possible to put 4 sets of plates on the tank and so better to get some averages when liquid is moving.
This kind of chip reduces the CPU needed on Arduino side.
https://create.arduino.cc/projecthub/te ... 004-9333c7
The chip it self is not so expensive (5€) but if you buy an already module then price increases to 25/45 €.
I did have a look at it when doing research on this. Quoted from the Page:
Caveats

Any sensing or engineering mechanism always has it's own set of limitations. For this application, this is what we noticed:

Capacitive sensing is prone to external stray capacitance and sometimes it saturates the ADC. This was however fixed using proper shielding.
Calibration is key and accurate calibration is very important
Environmental factors have a huge effect on the capacitance and they have to be shielded from and/or corrected appropriately.
So the disadvantages are exactly the same as the idea I'm working on, plus the board / chip is expensive.
It needs calibration, just like the idea I've posted.
The only advantage is that it talks to the arduino over I2c

I would like to try a cheaper approach, and make it even better..

For example, frsky already had a great vario, so, no need to make an oXs vario, right? Well, wrong :) the oxs vario is much better than the commercial ones. You see the point?? :)

Also, they did install only 2 parallel strips, I don't see that is the right approach for our needs as we need to measure with the tank in different positions, but I could be wrong. You lay that bottle on it's side and you will have problems :)

As you probably saw on my video, I did move the tank to different positions and apart from ONE single position, I had a consistent reading. When the fuel indication increases when the tank is not horizontal, that is not a problem, but when the tank is tilted to a particular side, the fuel indication decreases, and that could trigger a false alarm.
I would like to stay away from commercial stuff if possible, specially when building this could be as simple (and cheap) as gluing some copper or aluminum foil to your tank and add a resistor to the system :)
It is up to you of course, as i don't know any programming ;)

Thanks

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

mstrens wrote: Fri Apr 07, 2017 11:26 am Another solution could be to use a differential pressure sensor like the MPXV7002DP.
This is already supported by oXs.
Hmmm, how would you do this? because on glow fuel powered models the fuel tank is most of the times pressured by the exaust gases, so it pushes the fuel to the engine's carburator..

João

EDIT: Minimum operating temperature from this sensor is 10ºC? This is not even good for measuring airspeed :mrgreen: Not where I live anyway ;)
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
RightRudder
Posts: 241
Joined: Tue Jan 15, 2013 9:41 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by RightRudder »

I have a commercial fuel level sensor which works based on the capacitance effect. In this case they have arranged for the capacitor plates to take the form of a rod running inside a hollow tube. At the top, the two are separated and fixed with insulating epoxy. The tube has a small hole on the side at the top which is inside the tank and allows air to escape so that the fuel level can go up inside the tube to the same level as the tank. This arrangement has the advantage that it works in any tank and can be cut to the needed length. It can even work on an angle. This can be inserted through the rubber bung and wires soldered on the outside. It avoids problems when the fuel is sloshing around in the tank as well, if the air hole is small, the level in the tube won't change quickly and acts as an averaging filter. One fills the tank gradually in 1/4 increments and uses software to set four calibration points and then the software interpolates and gives a smooth indication of fuel level.
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: New beta version of openXsensor (=openXvario)

Post by jhsa »

I have also looked at it
The problem is, I don't really want anything conducting electricity inside the tank :)
Also it needs to be mounted vertically in the tank, right? If you tilt the tank too much it will still have problems in my opinion..

Not easy to measure fuel on airplanes :)

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
RightRudder
Posts: 241
Joined: Tue Jan 15, 2013 9:41 pm
Country: -

Re: New beta version of openXsensor (=openXvario)

Post by RightRudder »

The elements can be epoxy coated so electrical potentials are insulated from the fuel. It doesn't need to be vertical, it can be on an angle but it needs to cover the vertical distance from max to min fuel. This approach avoids the problems you mentioned with external plates and tank sizes, proximity to external things that can change the capacitance etc. This commercial one is made for measuring fuel on airplanes.

https://www.aircraftspruce.ca/catalog/e ... uelsys.php

Post Reply

Return to “OpenXVario - an open source vario supported by the open source firmwares!!”