L1 Pro Grove Port Not Working Properly with Seeed Grove Motion Sensors?

TLDR: Seeed’s Grove-compatible motion sensors don’t seem to work on the Grove-compatible port the Wio Tracker L1 Pro comes with.

I have a Wio Tracker L1 Pro which has a Grove connector in it. I bought 2x/each of these Seeed Grove-compatible motion sensors: the mini PIR motion sensor, and the Digital PIR Motion Sensor.

The Meshtastic App has a “Detection Sensor” settings panel all set to chose your settings (Pin 17 seems to be the correct detection/trigger pin) and go. I also setup a Primary channel specifically for the motion sensor alerts between the L1 Pro and my other mesh node. Neither model of motion sensor seems to work properly unfortunately…

The Digital PIR Motion Sensor won’t let the L1 Pro boot-up when it’s plugged in (just get a black screen).

The mini PIR Motion Sensor WILL let it boot up, but it still doesn’t work right no matter what trigger state I set – the signal appears to stay HIGH after the first trigger instead of returning to LOW.

  • Set to “High” trigger mode, the node keeps sending repeated “detected” messages even with no motion
  • “Rising Edge,” it triggers once and then never triggers again because there is no second LOW→HIGH transition.
  • “Either Edge Low” produced a “state: 0” message, which seems to confirm the input is being interpreted as stuck HIGH rather than behaving like a normal active-high PIR output.

Any idea how to get this to work or what I’m doing wrong?

1 Like

Ill see if anyone can take a look at this… I know the plug and play is not all that great… have you tried with a XIAO Expansion Board?

make sure you are using the corect pins in the code… D1 and D0 looa at the silkscreens

Thank you! And these are the only Seeed/Wio/XIAO devices I have at the moment.

For the code, you mean the firmware, right? I’m using the newest stock firmware from the Meshtastic web updater for the Wio Tracker L1 Pro – no custom code or anything (I can’t code, or understand what the code says/means on Github either lol).

What I can tell you hardware-wise, is on the motion sensors themselves the white wire says “NC” (Not Connected) and runs to D1 on the L1 Pro’s Grove connector. Yellow says “SIG” (Signal), and runs to the D0 on the L1 Pro.

In the Meshtastic App itself, in the Motion Sensor settings, when I set that to monitor Pin 17 for a signal, that definitely DOES read a motion sensor signal from D0 on the PCB since I get a text sent to my other node that it detected motion (just that it does that incorrectly, or only once, etc. - like I explained above). So somewhere in the code of the FW and/or the App I guess a correlation is made that Pin 17 setting = D0 on the board itself.

1 Like

I’m pretty positive I found out why this isn’t working.

Despite the Wio Tracker L1 Pro Product Page, Wiki, Industrial Product Datasheet, Block Diagram, and Hardware Schematic all repeatedly describe the Grove connector as supporting UART / IIC / GPIO, it does not appear to work as a Grove GPIO / digital-trigger input the way that wording strongly implies.

I did a lot of testing with a multimeter, and the big finding is this:

If I measure D0 on the L1 Pro Grove connector (the yellow signal/trigger line), it sits at about 5.200V by itself. D1 also measures about 5.2V.

That seems to be the core problem.

The Grove PIR motion sensors I bought are simple digital/GPIO-style modules. They work by idling LOW, then sending a HIGH signal when motion is detected. When I isolated the Mini PIR sensor from the L1 Pro and tested it by itself, that is exactly what it did:

  • idle: 0.0V
  • motion: about 2.965V
  • then it returned to 0.0V

So the sensor itself appears to be working correctly.

But if the L1 Pro’s D0 trigger line is already sitting high all the time at ~5.2V, then there is no clean/repeatable way for that PIR to create the kind of digital trigger the Meshtastic Detection Sensor feature is expecting. In other words: the host line already looks “high” before the PIR even does anything.

You can also see from the hardware schematic that the Grove D0/D1 lines are pulled up on the Grove-connector side:

How it’s wired makes sense IF the Grove port is only intended for I2C-style Grove sensors, since I2C lines normally idle high. That may also explain why the tested sensor table only lists I2C-style Grove sensors… But then why does the L1 Pro documentation repeatedly list the Grove connector as compatible with GPIO (which work the opposite way as I2C and idles low) like my PIR motion sensors I can’t get to work? …so if Grove Digital/GPIO modules actually do work on this connector as the documentation says, I HAVE to be missing a required configuration step; or I’m sorry to say, but the documentation is very misleading.

So my current understanding is:

  • the built-in Grove connector on the L1 Pro may be fine for certain I2C-style Grove modules
  • but it does not appear to behave like a normal Grove Digital / GPIO input for motion sensors like the ones I bought

I would like to try the nearby 8-pin PTH header instead, because those pins measured 0.0V and seem much more likely to work as real GPIO. But from what I can tell, those PTH pins do not appear to be exposed/selectable in stock Meshtastic firmware for the Detection Sensor feature. They may be usable with custom firmware, but I do not know how to code or recompile the firmware, and I really do not want to have to maintain a custom build every time Meshtastic updates.

PLEASE correct me if I’m wrong about any of the above. I do NOT know this stuff well at all. It took me no joke around 10–12 hours of testing, with ChatGPT walking me through how to use the multimeter and where to measure, just to get this far. And I HAVE had AI hallucinate massively multiple times and screw up my conclusions (no matter how much I research on my own and double-check it to the limit of my knowledge)…

…but I keep returning to the readings on D0/D1:

  • I know the Mini PIR alone behaves like a normal digital trigger sensor
  • And that L1 Pro Grove D0/D1 sit at about 5.2V by themselves
  • so the only logical conclusion is the issue seems to be the L1 Pro Grove port behavior, not the PIR sensor

So at this point I’m stuck… hoping all you experts here can shed some light on all this with the extra information I put above (and SO sorry for such a massive post - LOTS to go over!).

2 Likes

Thanks for the detailed reply!

I will try to get someone from seeed to ,look at it.

Like i said on the software side, I am not so sure the meshtastic software is robust enough to properly sense and control the Grove GPIO… I am assuming that is the core problem… but pull ups could also be a problem… please stand by for more news…

1 Like

I had a response (now deleted) but wanted to check first with you…
What Mini PIR are you using?

[This was deleted]
You may be able to invert the input from the PIR using a mosfet.

Some (older?) PIR’s may have an option for Open-Collector (Open-Drain) signal inversion.

If you have some soldering skills you could build an in-line mosfet inverter for the signal output.

1 Like

Currently, the native Meshtastic firmware mainly provides built-in support for I2C sensors. For sensors using UART or GPIO, firmware modification or custom development would be required. Wio Tracker L1 Pro fully supports both UART and GPIO on the Grove interface. However, they need to be configured through software/firmware settings.

1 Like

do you know if meshtastic will support IIC coms with… for example an ATtiny MCU that could relay commands between the L1 Grove and the external digital or analog sensor? or even a XIAO unit such as SAMD I would still assume not.. becaise Meshtastic is not programmed for communicating with these units either… also what about sensecap on the L1?

Sorry for the late reply everyone. I’ll try to be as brief as I can below as I’ve already written WAY too much above lol…

@cgwaltney For the software not being ‘robust enough’ to control the Grove GPIO - Seeed already has it programmed (and tested with) the WAY more advanced I2C modules which transmit actual data - in my mind, IF the hardware is capable, the simple digital GPIO ones like the motion sensors which ONLY read high/low should be a piece of cake. PLUS Meshtastic, in their iPhone/Android Apps, has already done most of the work for them with settings panels (and the coding required for those to be read) for both Motion Detectors, and Telemetry (mostly I2C) devices - like those are default setting you can change in the app for both types. ***however I WILL say that I think the only way this will work is if we use the PTH pad - which WOULD require firmware/software changes on Seeed/Meshtastic’s end on Github.

@grobasoz I know you can add other parts to the setup and make it work. Like after using resistors wasn’t enought to have the D0/Trigger line be read reliably, ChatGPT had me looking at transistors (which I barely know how those work…) as the next step to try… but semmingly the ENTIRE point of a Grove connector is that it’s plug-and-play with NO extra wiring/parts/etc. (or even code I thought!) needed to work. Thank you very much for the info though! - I’ll def keep that on the back burner if nothing else works (and I don’t move over to another competing brand - as those seem to have simple sensors like ones for motion already all figured out…).

@Janet The Meshtastic firmware which interacts with the app DOES have an entire settings panel for ‘Detection Sensors’ pre-programmed though, and aren’t most motion sensors the same digital GPIO high/low ones like I’ve been trying to use? - so the programming is already done for GPIO as well as I2C.

For the circuitry, and again, FULL disclaimer that I am NOT able to comprehend wiring schematics 100% (or even 50% for that matter lol), but can you please explain how with only code changes that the D0/Trigger line could be able to be dropped down to 0.0v? It seems like the diagram for the Grove sensor (and the rest of the board surrounding it), as I (quasi lol) understand it is basically set in stone to be always HIGH, and there’s no way without additional hardware or hardware changes to the PCB itself, to get that D0 pin to be at 0.0v so it can read the high/low trigger from the Grove PIR motion sensors. PLEASE let me know if I’m totally wrong here - the diagram from Seeed is above.

**EDIT, I researched this some more: I think this is because Seeed wired this specific Grove port with the ability to work with both 3.3v and 5v I2C (ONLY I think) devices. Because of the physical (are those pull-up resistors?) hardwired into that circuit, low-power devices like these mini PIR sensors aren’t strong enough to pull the signal down to a LOW state (even when I tried adding resistors). So although the NRF chip itself can be programmed to read these motion sensors, the physical hardware sitting between the chip and the Grove port makes it impossible to work with these high/low PIR motion sensors without changing/adding hardware. PLEASE correct me if I’m wrong somewhere!

1 Like

Thanks! I would say try with another Digital or IIC sensor and make sure it is working at all

a combo like this should get you into the meshtastic game with onboard IIC and Digital imputs onboard and IIC, Digital Analog and UART grove ports

also you may check into this device that was made theoredically to be grove to meshtastic compatable… but it is a very weak device… the onboard LoRa range is poor and the GPS doesnt work AT ALL… but the source code may have nuggets..

No worries - as mentioned the IO works as expected but the issue is the 5V… if your device is 3V3 then you may have a problem. Some PIR’s allow this however…

Thanks for the suggestions, but I was never looking for a frankensteined project full of multiple bare boards, wires, modules, adding/removing resistors/transistors/mosfets, etc. I bought the Wio Tracker L1 Pro because it seemed like a good node, came all assembled with a case, and also said it was “Fully compatible with the Grove Ecosystem”, and Grove is described as a “comprehensive ecosystem of standardized, plug-and-play modules”… So I figured at most I would have to cut a hole in the case with an X-Acto for the Grove connector and call it a day… but here we are… oh… probably 18+ hours? into the project? lol

For the XIAO ESP32S3 & Wio-SX1262 Kit you mentioned, I ordered 4x motion sensors because I wanted 4x sensors total, and was actually going to buy 3x of the nRF52840 version of that (ESP ones have exponentially worse battery life) if the L1 Pro worked properly… Seems like even on those, with the LoRa, GPS, BT, etc. taking up nearly ALL the free pins, that the remaining two pins (D30/D31: mapped to P0.09/P0.10) are set to be I2C ONLY on a firmware level - just like the L1 Pro Grove port seems to be… if that can be circumvented in the code or not I haven’t tried as I don’t own one to test with.

@grobasoz yup, both my PIR’s spec sheets say 3.3v (and both their product pages list up to 5v – which I think is wrong), but you’re 100% correct hat the problem is the high/~5v that’s constantly on the Grove’s trigger pins which there’s no way to remove without modding/changing/adding hardware.

Also stay tuned, I DID get this to work! I’m typing up what I did right now which might take a while (and it was what I did NOT want to do: edit and re-compiling the firmware to get the PTH to work, which I’ll now have to do EVERY firmware update unless we can get GitHub to change it moving forward - which I think might be possible).

2 Likes

Here’s the solution I came to. I’m sure I’m making some assumptions, and trusting AI on many things I lack much experience on… but hopefully I’m not stretching the truth or making too many possible false assumptions or using wrong terms below (all I can say is it works for me lol). Also going to reiterate the problem all the way to the solution:

PROBLEM:

The problem with the Grove connector on the Wio Tracker L1 Pro is it will NOT work with ANY Grove module which triggers by sending a high trigger – since the Grove D0/D1 trigger pins are ALWAYS on high – and there’s NO way via software to make those trigger pins idle at low since they’re hard-wired to always be on high. This also means all the marketing terms Seeed uses to say they’re compatible with every Grove (I2C/UART/GPIO) module is completely false.

PROPOSED SOLUTION:

Since the Grove connector isn’t compatible with many types of modules, that only leaves the PTH pads as an option to get a high/low module to work (like the Grove PIR motion sensors I’ve been testing, but also maybe another ~20ish similar modules from Grove which use the same high/low triggering mechanism) – but the problem with those is Seeed never added the PTH pins to the resource files the Meshtastic Github uses to compile the L1 Pro specific firmware…

SOLUTION:

The ONLY solution I found (that doesn’t involve adding/removing/modding hardware) is to edit the code to enable those PTH pads, re-compile, then flash it to your L1 Pro… which will have to be done EVERY time the Meshtastic firmware is updated (which Alpha builds seem to be updated every ~2-3 weeks). For the record this is also WELL beyond what most casual users are able to do (or are willing to do I should also say lol), so I’m hoping I can get the below lines of code added permanently on Github so it’ll be this way, stock, moving forward.

CODE CHANGE FIX:

For the exact fix which made my L1 Pro work, I only had to add a couple lines to variant.cpp:

    // Exposed two pins from the 8-pin PTH GPIO pads for external sensor use
    2,  // D31 P0.02_DIO_AIN0 PTH GPIO pad
    29, // D32 P0.29_DIO_AIN5 PTH GPIO pad

I then used MacOS Terminal (Windows users would use PowerShell), added the above to variant.cpp, then compiled the new code and uploaded the modified firmware to the L1 Pro (I’m NOT going into detail about that process as that’s a lengthy topic on its own… but I will say ChatGPT basically did all that for me and I just pasted in and ran the code it gave to me – took about 20 minutes pasting in commands, and about 2-3 minutes of CPU time to actually compile).

Once done that lets the PTH pads labeled 02 and 29 on the L1 Pro’s PCB be used as triggers. They sit idle at 0.0V. So to setup your compatible high/low-type detection sensor (which is NOT just motion sensors - there’s a TON of other types!) in the Meshtastic App you go into settings, Detection Sensor setting page, you would select Pin 31 or Pin 32 as the “GPIO Pin to monitor”.

Since the motion sensors I’m using also like 3.3v, I’m also using the 3V3 pad (3.3v) of the PTH, and the GND (Ground) pad of the PTH (so 3x total wires needed: power, ground, trigger) – so I’m not using ANYTHING on the actual Grove connector itself (all this involve soldering - which again, which many casual users can’t do).

OTHER REQUIRED SETUP FOR DETECTION SENSORS:

To have ANY type of Detection Sensor work you also have to have a PRIMARY text channel setup for that. Most default setups have the public LongFast setup as the Primary… you have to move that to a Secondary channel, and setup your Primary to be for the detection sensor (I used “Motion Sensor” as my name). It also has to have a 128 bit encrypted key.

In Detection Sensor settings the node with the sensor attached to it gets set as “Sensor”; and the node(s) you want to get the sensor text alerts 1.) ALSO have to have the same-named Primary channel 2.) HAVE to have the same 128-bit key 3.) Are set to “Client” (with enable notifications toggle set to ON).

4 Likes

Thanks for the update… you could also use the inverter transistor option above.

are you sure the pin is hardware pulled up… or pulled up in the chip by software.

I will pass this info along to seeed! thanks again for the research

1 Like

Excellent workaround - thanks for the information.

1 Like

You’re talking about the Grove connector still, right? If D0/D1 went straight from the nRF chip to the Grove pins, then yes, software might be able to change how they behave, BUT they don’t go straight – there is extra circuitry between them which makes them only able to sit high (and also no switch mechanism to bypass that circuitry), and this is why they’re unusable for modules like the Grove PIR sensors I’ve been using.

That’s why I used the 02/29 PTH pads instead. Those come direct off the nRF (NO circuitry between), and sit low at idle – perfect for the PIR’s (once I added the code to let them be selected as triggers of course).

__
_
_

Right now my biggest issue (which I really REALLY hope isn’t a problem with the L1 Pro’s PCB, the new code, and how I have it setup) is the Seeed Grove PIR Motion Sensors having false motion-trigger alerts no matter how I have them setup. They are SO uber sensitive it isn’t even funny… for example I’ve literally put them inside an (open top) cardboard box (NO A/C vents blowing on them or anything – since they do detect IR temp) and I still get ~10ish false alerts in a 24-hour period…. So I’m still working on the how/why to that and doing more testing (which might involve ordering some parts and different units…).

the sensitivity can be adjusted by working with the R2 or installing a pot… FYI