Add TLV493D magnetic sensor

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
flightman
Normal user
Posts: 15
Joined: 17 Jul 2023, 17:48

Add TLV493D magnetic sensor

#1 Post by flightman » 09 Aug 2023, 11:27

Good morning,

First of all I don't know if I'm in the right part of the forum to make this request, please move my message if necessary.

I am looking to interface espeasy with an Infineon TLV493D type magnetic field sensor.
Below is an example of code given on the site http://www.esp32learning.com/code/tlv49 ... xample.php
As well as the ADAFRUIT doc: https://cdn-learn.adafruit.com/download ... ometer.pdf

Thank you in advance for telling me how I can add component to the ESPEASY interface.

Code: Select all

#include <Tlv493d.h>

// Tlv493d Opject
Tlv493d Tlv493dMagnetic3DSensor = Tlv493d();

void setup() 
{
  Serial.begin(9600);
  while(!Serial);
  Tlv493dMagnetic3DSensor.begin();
}

void loop() {
  Tlv493dMagnetic3DSensor.updateData();
  delay(100);

  Serial.print("X = ");
  Serial.print(Tlv493dMagnetic3DSensor.getX());
  Serial.print(" mT; Y = ");
  Serial.print(Tlv493dMagnetic3DSensor.getY());
  Serial.print(" mT; Z = ");
  Serial.print(Tlv493dMagnetic3DSensor.getZ());
  Serial.println(" mT");
   
  delay(500);
}

User avatar
Ath
Normal user
Posts: 3521
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Add TLV493D magnetic sensor

#2 Post by Ath » 09 Aug 2023, 11:47

That sensor isn't yet supported by ESPEasy. And we only have the HMC5883L magnetometer, that depends on the earth magnetic field to give its position. Haven't tried that with a magnet though. And also the ADXL345, but that will return it's relative position in x/y/z direction, don't think it will respond (well) to a magnetic field.

What type of hardware implementation are you aiming at here?
/Ton (PayPal.me)

flightman
Normal user
Posts: 15
Joined: 17 Jul 2023, 17:48

Re: Add TLV493D magnetic sensor

#3 Post by flightman » 09 Aug 2023, 12:10

Yes I see the HMC5883L but I need a widest range for my tests.
I am trying to find out how I can implement the component code in the ESPEASY software, as a new component.
Thanks

User avatar
Ath
Normal user
Posts: 3521
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Add TLV493D magnetic sensor

#4 Post by Ath » 09 Aug 2023, 12:51

/Ton (PayPal.me)

flightman
Normal user
Posts: 15
Joined: 17 Jul 2023, 17:48

Re: Add TLV493D magnetic sensor

#5 Post by flightman » 09 Aug 2023, 13:34

ok thank you

User avatar
Ath
Normal user
Posts: 3521
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Add TLV493D magnetic sensor

#6 Post by Ath » 10 Aug 2023, 09:49

flightman wrote: 09 Aug 2023, 13:34ok thank you
If you are actually creating a new plugin, then you can request a PluginID from the Github issue we opened for that :)
Easiest would be of course if you are using that ID from the start.
/Ton (PayPal.me)

flightman
Normal user
Posts: 15
Joined: 17 Jul 2023, 17:48

Re: Add TLV493D magnetic sensor

#7 Post by flightman » 10 Aug 2023, 18:07

Ok thanks for the information

Post Reply

Who is online

Users browsing this forum: No registered users and 29 guests