Ribbit-Network / ribbit-network-frog-hardware

The sensor for the world's largest crowdsourced network of open-source, low-cost, GHG Gas Detection Sensors.
https://www.ribbitnetwork.org/
MIT License
94 stars 26 forks source link

ESP32: Enclosure Updates for ESP32 Based Frog #163

Closed keenanjohnson closed 1 year ago

keenanjohnson commented 1 year ago

Hey @eaudiffred !

As we discussed in our team call earlier, I have fairly high confidence in the new processor that we would use for the microcontroller based version of the Frog.

Here is the actual part and link to adafruit: Adafruit ESP32-S3 Feather with 4MB Flash 2MB PSRAM - STEMMA QT / Qwiic

image

Implementation Notes

The power connector is a USB Type connector again shown on the left hand side of the image below. I imagine we would want to orient the board such that the power connector faces down like our previous designs

image

One thing that is a bit annoying is that USBC Power Adapters tend to be fairly large and not designed for outdoor applications, so I'm wondering if it might be worth designing around a USBC to Barrel Jack to USB C Adapter like this one?

Electrically this would be fine, but physically it will be perhaps mechanically wasteful as that adapter is almost the same length as the whole ESP board haha.

Would love any thoughts or opinions there :)

image
eaudiffred commented 1 year ago

Thanks @keenanjohnson. One initial question about the power supply. Are there any USB-C power supply units that will work? It looks like it's 3V and I think a max on 150mA. I can look around for something so that we don't have to use an adapter. If you know it doesn't exist, just let me know and I'll tie in the adapter.

eaudiffred commented 1 year ago

Just posting this here for reference.
image

eaudiffred commented 1 year ago

I believe this is a STEP file of the board, but I can't seem to figure out how to download it. It's my lack of GitHub knowledge I think. https://github.com/UnexpectedMaker/esp32s3/blob/main/3d%20models/FeatherS3_P4.step

eaudiffred commented 1 year ago

Got it! Remembered the Desktop App. The board is not in the CAD imports folder.

keenanjohnson commented 1 year ago

@eaudiffred ! Any standard 5V Usb C Power Supply should work (where did you see the 3V number)? I've confirmed that here :)

eaudiffred commented 1 year ago

@keenanjohnson, ok cool. That eliminates the need for the adapter, correct?
I misread the data sheet. I thought it was limited to 3V, but that is incorrect.

keenanjohnson commented 1 year ago

There are adapters, but the USBC plug I've read does less well outdoors overtime than a barrel jack, but perhaps that's not really a problem worth solving for the moment until we are sure we have an issue.

eaudiffred commented 1 year ago

I've started to work on the enclosure based on the ESP32 and we will be able to reduce the size significantly. Here is an initial idea for the model.

image image

keenanjohnson commented 1 year ago

Wow this would be excellent if we could take the size down significantly!

Looking at your renderings, I'm a little bit suspect that there is enough room there for the USBC cable. Unfortunately, the power connector on the cable end is usually quite long. We might need to include that in the model to check out if there is enough space?

This thing from a common USBC suply

image

eaudiffred commented 1 year ago

@keenanjohnson, good point. I went ahead and make a model for the USBC supply. It does cause issues. We may be able to reduce the width of the enclosure by taking out space between the clips (red circles). Then rotating the whole board to almost vertical and lengthening the base.

I think I can squish the depth a little too. The width and depth adjustments would make the shroud and head incompatible between versions, but I don't see that as a huge problem right now. The amount of material and time that can be saved seems to be worth the changes.

image

keenanjohnson commented 1 year ago

Yeah, I wouldn't worry about head capability between versions at the moment.

One thing we could consider is a right-angle USB C adapter? Perhaps this would help us with the cable routing out of the side?

https://www.adafruit.com/product/4432

image

eaudiffred commented 1 year ago

Yeah, I was thinking about that and weighing pros and cons of one additional part on the BOM. I'll model that up too and see what configuration seems to save the most material.

eaudiffred commented 1 year ago

I was able to shrink the depth and width a decent amount. We are able to save quite a bit of material by using this smaller board.

image

image

eaudiffred commented 1 year ago

@muditprotect3d, now would be a great time to introduce any ideas regarding the hanging mechanisms! While we are remodeling for the ESP32 we will have lots of opportunity to prototype. Also, any ideas concerning the enclosure in general is more than welcome!

muditprotect3d commented 1 year ago

@eaudiffred sounds good! I will add some to the thread right now

muditprotect3d commented 1 year ago
Screen Shot 2022-10-12 at 1 48 31 PM
muditprotect3d commented 1 year ago

This was one I created, could be attached easily to the back and allow to hook on to a pipe or fencing material

muditprotect3d commented 1 year ago
Screen Shot 2022-10-12 at 1 49 26 PM

This is another one, basically similar to the last one except would span the entire width of the back of the enclosure

muditprotect3d commented 1 year ago
Screen Shot 2022-10-12 at 1 50 10 PM

This one would be a variable one where you could slide the two ends across the channel to fit across any component of varying length

muditprotect3d commented 1 year ago

I created it on the shroud but the ideal location would be on the back of the enclosure

muditprotect3d commented 1 year ago
Screen Shot 2022-10-12 at 1 51 38 PM

These are more simple hooks, but im working on a design right now to make the bottom hook slideable through a channel

muditprotect3d commented 1 year ago

Im working on another design this week, and I had some ideas about the enclosure as well I can send in here by end of week

eaudiffred commented 1 year ago

@muditprotect3d Awesome work! Thanks for sharing. I realize we should document this design work in a separate GitHub issue just to keep projects organized. I'll open a GitHub issue for Hanging Mechanism Designs, and we can keep developing these ideas in there. I'll tag you and reference the posts above. Then we can use this issue for enclosure design related to the ESP32 change.

muditprotect3d commented 1 year ago

Reading this thread again, have we considered/thought about using the space tradeoff to include an external battery instead of a power cable? ( Instead of reducing the size of the enclosure, we could use the extra space due to a smaller processor to include an external battery/power source)?

keenanjohnson commented 1 year ago

Great question @muditprotect3d! In the future once we create a solar powered version of the frog, we will need a battery, but right now even with the microcontroller, we will need to have an external power source to power things. The power management for a battery system is a bit complex and I think needs to be designed first before we could scope modifying an enclosure around that.

eaudiffred commented 1 year ago

I have some prototypes printed and was able to test fit with the main electrical components.
CAD files can be found here.

Here are some pictures comparing V3 and V4: image image image

Here are some pictures showing the electrical component fit.
image image image

eaudiffred commented 1 year ago

The biggest problem remaining is figuring out the clip design for the ESP32 board. I still have not gotten a reliable design that has enough flex for repeated use. I keep snapping the clips when inserting the board on the 1st or second try. Let me know if anyone has ideas! The goal here is just to reduce the amount of hardware (screws in this case) needed for the sensor.

image

keenanjohnson commented 1 year ago

Excellent work @eaudiffred ! Were you able to try plugging in the USB C cable while it's in the enclosure? I'm wondering if there will be any problems with the weight of the hanging cable tilting the hanging sensor and allowing more water into the shields at a high angle as the sensor is getting so small and light now.

Perhaps @muditprotect3d might have some suggestions on the mechanical side for the clips?

eaudiffred commented 1 year ago

@keenanjohnson, excellent point on the cable weight. I just hung the sensor and plugged it in. It did tilt slightly. Enough that its worth moving the power cable entry point.

eaudiffred commented 1 year ago

I went with a slightly different approach and flipped the ESP32.
image image image

muditprotect3d commented 1 year ago

@keenanjohnson @eaudiffred could we do something with sliding it in and having it be an interference fit? This way the plastic material could hold the circuit in place similar to how the screw holes work? It would essentially be like a sliding compartment that we put the controller into to keep it from moving around, but wouldn't require any clips to flex back and forth

eaudiffred commented 1 year ago

@muditprotect3d, Yes that's a great idea! I think that will actually keep the board more secure and be easier to print.

muditprotect3d commented 1 year ago

@eaudiffred Awesome! Would it be useful if I tried to make some CAD models of what I'm thinking here? I'm also working on the hanging mechanism incorporated into the larger device. I have two tests this week so am a little swamped but will get that done by midweek!

eaudiffred commented 1 year ago

@muditprotect3d, yeah that would be great! Here is the most recent model I have been working on.

No rush, get those tests out of the way before worrying about this. Let me know if you run into any blockers or need help on anything. Good luck on the tests!

muditprotect3d commented 1 year ago
Screen Shot 2022-11-20 at 9 45 54 PM

putting this here but here is a mockup of the sliding rails for the feather I was talking about

eaudiffred commented 1 year ago

Just copying this comment here (from Discord) for reference. One thing to keep in mind is that the board will need to slide into place, correct? So there needs to be enough space in the enclosure to drop the board down, and then slide it over. Hopefully my thinking makes sense. Let me know if I need to explain via picture.

keenanjohnson commented 1 year ago

Great work collaborating all! Is it worth it creating a separate issue for this sliding feature or are you all ok collaborating here in this issue?

eaudiffred commented 1 year ago

@keenanjohnson I think we can finish up the sliding feature in this issue and then call it complete. @muditprotect3d could you share the link to the file you've been editing?

muditprotect3d commented 1 year ago

Yes sending now!

muditprotect3d commented 1 year ago

https://cad.onshape.com/documents/3d928932fd41fdc8e9fbaac0/w/87262cd35788e1173a2d535a/e/c180c5717ccf65cb0e58b6c0?renderMode=0&uiState=637f02b3c69bdb43ca62accc

muditprotect3d commented 1 year ago

I'll make the edits you had suggested by the end of the week and have a final CAD prototype ready to print by EOW. Sorry about the delay on my end with this.

eaudiffred commented 1 year ago

@muditprotect3d Looks good! I copied your work over to the main file and added some fillets and chamfers. I'll try and get a test print out this week as well.
image

muditprotect3d commented 1 year ago

Awesome! I think the tolerancing may have to be increased but it will be good to get some prints out and see

keenanjohnson commented 1 year ago

Yes let me know if you have anything that is ready for a test print as well.

keenanjohnson commented 1 year ago

@muditprotect3d I printed the file you sent in Discord and in general, I think it looks great, though there are some issues to sort out. Thanks for your hard work and @eaudiffred for supporting as always!

Board Doesn't Fit in Slot

The biggest issue is that the board is too wide to fit in the slots as provided. The 3D model of the board in Onshape must be wrong or the tolerances are too tight.

Additionally I noticed there isn't too much space to wiggle the board down in line with the slot, even if the slot was the correct width. Perhaps the whole enclosure would need to be wider?

image

image

Cable Bend Radius I'm pretty worried about bending the USB cable 180 degrees like this. The cables are generally pretty stiff and I noticed it really puts a lot of tensions on the connector in the USB housing. I'm wondering if it makes more sense to go back to the esp 32 being vertically mounted? If not, we may need a feature to provide strain relief for the cable so it is not transferred to the connector on the board which is not very strong I think.

image

Board Dimensions

I've include the measurements I took of my board for validation of the dinesnsions from Adafruit's drawings.

image

image

eaudiffred commented 1 year ago

Great feedback @keenanjohnson, thanks! I also printed one last night, but I tweaked the dimensions ahead of time. I was able to get the board to slide in, but it was still a little too tight. I think 22.7mm, the exact width of the board will work well.
image

eaudiffred commented 1 year ago

I also think that the slides can be shorter. Something like this will provide enough support. The slides are 20mm long in this picture.
image

eaudiffred commented 1 year ago

@muditprotect3d great work on the design! I like how this functions and secures the board.

eaudiffred commented 1 year ago

@keenanjohnson, I'm wondering if we should add the 90deg adapter. I hate to add another piece to the BOM, but I like how much time and material we've been able to save.

I'm thinking of two other options right now (the 90deg spacer being a 3rd option): image image

muditprotect3d commented 1 year ago

Hey @eaudiffred @keenanjohnson thank you for the feedback! I didn't have a feather with me when making the slots so I was using the measurements on onshape and kind of figured they would be off a little but this is super helpful feedback! @eaudiffred are the edits you mentioned on the main file? I can go ahead and get another test print as well with the 20mm slots