Electron Project Discussion [Hardware]


Yeah I could, and I will play around with it a bit more. The thing is though, it’s already set to a very high (low sensitivity) setting, and it’s still getting triggered a couple times a day on average, so the vibration of the container when it is open/closed must resonate all the way to the accelerometer and trigger it.


The Accelerometer chip used in the particle Asset Tracker can be set up to only trigger an interrupt when the bin is flipped 90 degrees which would should eliminate just vibration triggers.


Lol. I just found out the acrylic parts actually had a protective sticker on them. No wonder they didn’t work. I took it off, put it in front of the laser, and it works fine. However, they still absorb fingerprints, after which about 50% of the readings started to fail, so I definitely need ones with an anti-fingerprint coating added to it


I know about regular sleep, but does it also apply to Deep Sleep mode? I tried to do something like that with the LIS3DH chip on the Asset Tracker, but couldn’t make it work reliably.


I don’t think the anti-fingerprint will make a difference other than the fingerprints will not show up as easily to the eye but the grease/oil will still be on the sensor which is probably affecting the sensor’s send and receive strength. That’s just my guess, the anti-fingerprint coating is worth a try though just for the hell of it.

Glad you realized the protective coating was on there :smile: They always ship that stuff from the factory with front and back protective layers. Acrylic is really easy to scratch, I’ve been cutting clear acrylic and labels for the past 7 years for some products I build.

Have you tried regular glass in front of the sensor?


Yeah the grease/oil is what I mean…all the nasty bits that come from our fingers :scream:

I asked the manufacturer if they have any recommendations for this (I’m sure they do), because they do work really well. Even after covering all of the glass with my greasy fingers, 50% of the laser signals still made it through just fine. These parts are hardcoated though, I tried scratching it with a nail and am unable to.

I think it is a very good solution for protecting a delicate sensor like the VL53L0X.


I know that the LIS3DH is a super low power chip that you can leave running or in sleep mode while the Electron is in Deep Sleep and then have it trigger an interrupt when it detects a 90-degree movement when the can is picked up and emptied.

The power consumption is very low no matter which mode you run the chip in.


Interesting…I should look into that some more for us. Avoiding the couple of pings every day isn’t too critical but would definitely extend the lifespan even more.


Found some info about the anti-fingerprint coating and that it’s not recommended in this ST document about what material is best. Looks like acrylic is a good choice and that putting the sensor directly against the glass provides the best results. :


The way I read it, it could result in a scattering effect, but it’s probably dependent on many factors…I think it’s worth at least trying it out. The way I set up the laser, it’s not a big issue if there’s the occassional scatter effect as it takes a couple of measurements and ignores any invalid or outlier values. Since they go on waste containers I think no protection whatsoever against smudge or fingerprints would be a really big issue over time.

Also, do you know if there is any interrupt from deep sleep possible with the ADXL-362 (which I use) based on position (e.g. some XYZ value threshold)? I really like their super-low cost and super-low current draw, and already got 30 of those anyway here :grinning:


I don’t think the fingerprint coating will do anything to prevent the smudge or dirt from building up on the surface, how could it stop that? It’s just a feature that makes a fingerprint not as visible is how I understand it. Maybe I’m wrong? I guess this is where an Ultrasonic sensor would no be as affected maybe?

I’ve never used the ADXL-362 chip before so I can’t help much with that other than point you to this tutorial on how to use the interrupt feature for that chip:



Here is a window cover that ST recommends for the laser sensor.

Can’t find it via a google search but the contact info to buy it is here;

Email him and see what the pricing is.


I saw that recommendation too, but indeed couldn’t find anything about ‘‘Hornix cover windows’’ or the product codes anywhere on the internet. I’m not really sure what makes it different from other products, but I guess I can get in touch with that person.


I emailed him and he got right back with me. Offered to send me free samples if I covered shipping.

They have 3 different window designs that look to be optimized for the sensor.

Pricing for the windows is under $2 each so very reasonable.


That sounds pretty good. The design of it makes me think however it won’t fit on my current sensor as the laser is on the same side as all the resistances, regulators etc. (so no smooth surface for the adhesive to be put on).

But I could also get a VL53L0X where theyre on seperate sides.



It looks like others here are helping you out a lot on the technical side.

I also live in Canada, but my temperatures appear to be quite a bit colder than where you are …

Anyways, I can provide you some information about pricing garbage services. It varies all over the place.

Most places in Canada (as far as I am aware), include a flat rate for garbage services as part of residential municipal taxes. Apartments, condos and businesses will be different. However, there is no incentive for good garbage behaviour or savings with a business model like that.

More and more municipalities are starting to change things. A newer model used in some places in Ontario is to provide 26 garbage tags when you pay the municipal taxes. You attach a tag to each bag of garbage you put out for pick-up. That gives you one bag for the pick-up every 2 weeks, on average (you can use as many as you want per pick-up). You can buy more tags from the municipal office if you need them. That encourages individual people to reduce their garbage. Recycling and compost are free for pick-up.

A newer model used in some places in Quebec is to put scan codes on the 95 gallon garbage and recycling bins. The bins will be picked up every second week; this is again included in the residential municipal tax bill. Buying scan codes for additional garbage or recycling bins can be done. The price for garbage bin scan codes are the most expensive; the scan codes for recycling are noticeably less expensive. I am not sure how the price for compost bins fits in; in the rural areas people are supposed to have their own composter and that is free (since there is no pick-up).

By the way, while in school years back (1990s), one of my classmates did a university project to put stress gauges and accelerometers on the lift mechanism of the garbage trucks. They could weigh the amount of material being picked up. This enabled the industry to charge based on weight of material; I think that did not take off; probably business reasons as you have said. Mind you, today’s technology can now automatically detect who’s garbage is being picked up (RFID, scanners, etc.).

I think that things might change quickly now with greater awareness of environmental concerns, plus having technology such as IoT to do something about it!


@Vitesze What is the max range in MM that you get from the VL53X sensors in long range mode?

I’m testing mine now and see around 2100mm max before it starts showing the 8190mm max reading.

Is this the same for you?

What is the mm range you see when the bin is empty?


The max I can get is about 2100-2200mm…occassionally up to about 2230mm but at that point it fails most of the time. The typical distance I calculated when the bin is empty (I don’t actually look at their reported range - i let it convert it into a fill ratio with a formula. Works for now as all the containers have near-identical sizes) is about 1700mm or so due to the angle.

Spend part of the afternoon looking into my antenna issue; although the gain of the particle antenna is decent at 3dbi, the u.fl connection is really weak. After looking into it a bit more though I decided that just soldering it is the best way to go

Not sure how I will attach the Particle itself properly; I don’t want to solder it to anything as I want to be able to take it off if I ever have to switch PCBs (yes desoldering is a thing, but imagine if I’d ever have a 1000 of these). The female headers I have keep it decently in place, but it still falls out sometimes

Firmware side all seems good. Not sure yet how I will handle the firmware updates, as I can’t find a proper way to detect when the device is downloading something and when it’s not…I had an issue where one of my devices exceeded the 40sec threshold I set for downloading the firmware, so it got put in Deep Sleep and wouldn’t wake up anymore…had to go out and manually complete the update.


I’m seeing the same max distance as you are.

What kind of uFL antenna adapter are you using? It looks like your attaching the antenna directly to the uFL connector on the Electron which I have never seen before.

You might want to check out this thread for getting your product update code working as reliably as possible.


Nono, I’m using the default Taoglas antenna and attach it with a cable + female u.fl. but since my sensor is especially experiencing a lot of up-down movements while almost upside-down, the antenna is at big risk of popping out at some point. So I soldered the two connectors together :slight_smile:

Also, my sensors can download code just fine. It’s rather, sometimes they can take up to a minute. I don’t know how to check if they’re busy with this, and I also don’t always want to keep them on for such a long period of time ‘‘just in case’’