Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Designing a PCB #4

Open
puddly opened this issue May 26, 2019 · 15 comments
Open

Designing a PCB #4

puddly opened this issue May 26, 2019 · 15 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@puddly
Copy link
Owner

puddly commented May 26, 2019

My goal is to have a self-contained device that is powered by either the RJ45 port's 9V pin or by a microUSB connector and can communicate with a computer over usb or WiFi.

I'm currently using a dev kit built around the ESP32-WROOM-32 because it has:

  • two hardware UARTs (one for USB and one for communicating with the bus).
  • the UARTs support signal inversion (the bus uses 5V logic and is pulled down to 0V).
  • first-party support for FreeRTOS.
  • Bluetooth and WiFi.

I'd like wireless connectivity so I really see two ways to do this:

  • Make a "shield" for an existing dev board (e.g. the ESP32 dev kit). This saves time because pre-made dev boards already come with a voltage regulator and a USB-serial interface. All that needs to be done is to solder a few headers and a 9V->5V regulator to an unpopulated PCB. Plus the dev board can be repurposed if you ever get rid of your GE appliances.

  • Designing around a wireless module (e.g. the ESP32-WROOM-32). This would avoid having unnecessary components and will result in a simpler board but will take more time to solder together.

Component-wise, we need:

  • USB-serial converter (anything but the CH340).
  • a dual-supply transceiver for level shifting with direction and enable pins (maybe the SN74LVC2T45?).
  • a component (or two) that converts 9V to both 5V and 3.3V and provides enough current for wireless operation (ESP32 needs at least 250mA, I think).
  • RJ45 port. Tying together the two possible locations of the 9V pin (the GND and COMM stay fixed) allows for handling both normal and crossover ethernet cables.

I'm going to try and make something with KiCad when I have some time.

@jallen2281

@puddly puddly added enhancement New feature or request help wanted Extra attention is needed labels Jan 23, 2020
@mulcmu
Copy link

mulcmu commented Aug 10, 2020

Here was my KiCad schematic for a "shield" using parts recommended above. Any comments or suggestions before routing the PCB?

OnionStraws Draft.pdf

@puddly
Copy link
Owner Author

puddly commented Aug 10, 2020

Thanks for the help! I've been hoping to finish this project for a while but I have no experience with actually designing PCBs so it's been a little hard to get started.

Here's some more info that I've found in the meantime:

  1. Almost like I2C, the bus is being pulled down to GND by a 4.7k resistor.

    • Actively driving the bus down to GND with the chip I was originally using might not be a good idea because we can collide with another device concurrently pulling the bus up to 5V and possibly damage something. I think only pulling the bus up to 5V during transmission and letting it fall back down to GND will be a safer approach.
    • Removing the need for the SN74LVC2T45 chip reduces the cost a little.
    • Implementing collision detection by receiving and transmitting concurrently might also be a good idea, as we can just immediately stop transmitting a message if what we receive from the bus doesn't match what we expect.
    • The ESP-32's UART's RX and TX pins can be inverted (independently) in software, which might simplify the design little?
  2. The input voltage on the RJ45 apparently can go as high as 16V on some appliances, not just 9V as I had measured on my machine.

    • The LD1117S50TR can't handle this high of an input voltage so we'd need a new voltage regulator.
    • Some people have also reported that their off-brand ESP-32 dev kits briefly draw up to 750mA when scanning for wireless networks.
  3. There are multiple footprints for the many ESP-32 dev kits available online. You can find the schematics and reference design documents for the different dev boards on Espressif's website but I think basing the design around the ESP-WROOM-32 DEVKIT V4 is or the smaller ESP32-PICO-KIT V4.1 is a good idea. They're both $10 from Digikey. Alternatively you can get a non-standard design for about $4 off of AliExpress. I'll have to investigate the footprints of the different boards a little more to see which ones are the most compatible.

@mulcmu
Copy link

mulcmu commented Aug 11, 2020

I've done a few custom boards for hobby stuff. Just got a new GE Washer and Dryer. Was looking to push cycle done and maybe time remaining to home assistant.

  1. Have you tried any alternate arrangements for RX/TX connection? Still need something to shift from 3.3V to 5V?

  2. Looks like there are some 1A 35V linear regulators to get the 5V supply (like MC7805BDTRKGOSCT-ND). I will look into a small DC/DC buck converter. More parts and expense but more efficient for something powered 24/7.

  3. My generic modules from Amazon had the ESP-WROOM-32 DEVKIT V4 pinout but are a bit more compact. The ESP module pcb antenna didn't hang out from the base PCB.

@puddly
Copy link
Owner Author

puddly commented Aug 11, 2020

  1. The whole 5V bus with a pull-down level shifting problem is what's really tripping me up with this whole project so could you clarify what you mean by an alternate arrangement? All of the devices on the bus are 5V so I'm trying to get the ESP32 to act like everything else. I believe the official Green Bean used a pair of optocouplers for the level shifting.

  2. The bus passes around data around on my machine about once per second so the larger power supply might be necessary if the ESP-32 will be transmitting frequently. I think with some sort of bus packet filters microcontroller-side it'd be possible to keep the ESP-32 in a low-power state for quite some time before it wakes up, especially if the common use case would be to just notify HA of a couple of events periodically.

  3. This is the one I'm currently using and the PCB has a big cutout where the ESP-32's trace antenna is sitting. I'll have to compare its current draw to the Amazon ones.

@mulcmu
Copy link

mulcmu commented Sep 21, 2020

Looks like the hardware & interface has been changed. My RJ45 port doesn't have pin 7 populated. I was still getting 14 Vdc between pin 1 & 8. It appears pins 3 to 6 all could have connections to the main PCB. Haven't hooked it up to a scope yet...

no pin 7

6 pin connector

@puddly
Copy link
Owner Author

puddly commented Sep 21, 2020

Hmm, I wasn't aware there could be multiple buses on a single RJ45. That does complicate things.

The ESP-32 definitely has enough free pins to do simultaneous TX/RX on all of those but they have to be bigbanged instead of relying on the built-in UARTs and my code doesn't really support concurrency at the moment (though the ESP-32 has first-party support for FreeRTOS, which should make the rewrite trivial).

@mattgallion
Copy link

mattgallion commented Nov 30, 2021

Hey guys,

I know this is an old thread, but I just bought a W&D and am interested in integrating into Home Assistant. I have a lot of experience with PCB design so I can help with layout and can do some board runs too.

@puddly
Copy link
Owner Author

puddly commented Nov 30, 2021

Thanks for your interest!

I've just pushed my attempt at a schematic and an unrouted board to the Git repo under the board/ folder. It was draw up with a KiCad nightly build so it may not open properly with the current stable release.

Unfortunately, a recent package theft has left me without any 5V regulators capable of accepting 9V-16V input (and I won't be able to get replacements until early next year due to the chip shortage) so this project is not seeing much attention these days.

The only portion of the PCB that I'm still struggling with at the moment is the inverted level shifting with the GE bus pulldown. If you can suggest a way to do this while accepting "normal" logic levels from the microcontroller, I think the hardware is close to being done. At least in the eyes of someone who has designed exactly two PCBs with no active components 😄.


Attached is the schematic in case there are any custom symbols/footprints on the board that don't open:

image

@jallen2281
Copy link

I was chatting with a GE repair man today and he uses a "Black Bean" module. It has firmware flashing capabilities as well as everything the green bean has. Just thought it was interesting.

@jallen2281
Copy link

Not sure if this will help someone, but the chip in use on the original module is this: https://www.microchip.com/en-us/product/PIC24FJ256GB106

20211130_180314
20211130_175800

@mattgallion
Copy link

mattgallion commented Dec 2, 2021

@puddly Any reason why you're using a switching regulator for the 5V instead of a linear regulator? I assume your goal is to minimize losses in power, and I'm curious if you know what the current supply capability from the bus is?

I had started my own attempt based on some ideas I found online (https://circuitcellar.com/resources/ee-tips/one-wire-rs-232-half-duplex-ee-tip-135/) but havent tested anything yet. See attached schematic, it's by no means complete. I used a dual inverter to fix the inverted levels, and a digital isolator for the level shifting.

@jallen2281 Thats funny, I was working on my own adapter (copying from the greenbean) and I was going to call it blackbean.

BlackBeanSchematic_0.1.pdf

I've also gotten some inspiration from @doitaljosh at https://github.com/doitaljosh/gea-interface-board

@puddly
Copy link
Owner Author

puddly commented Dec 2, 2021

I assume your goal is to minimize losses in power, and I'm curious if you know what the current supply capability from the bus is?

I don't, unfortunately. I will poke around in my washer when I get a minute.

My understanding is that the ESP32 draws about 40mA when not actively using WiFi, 150mA when using WiFi, and briefly exceeds 500-700mA when scanning for networks. The worst case scenario would be regulating 16V down to 5V and supplying 150mA of current, so a linear regulator would dissipate at least 1.65W.

I used a dual inverter to fix the inverted levels, and a digital isolator for the level shifting.

Thanks for the link, I wish I had found that page sooner. I think your schematic incorporates design 3 in that article, which suppresses the "local echo". For collision detection, loopback reception is actually desirable because the firmware would compare each transmitted character (or bit) to the received one and stop transmitting if they aren't identical.

Thats funny, I was working on my own adapter (copying from the greenbean) and I was going to call it blackbean.

I believe there's also a Navy Bean. This is arguably the most important part of the project but thankfully there are many other beans to choose from. An irregular, kidney shaped PCB with red solder mask might be interesting...

@mulcmu
Copy link

mulcmu commented Dec 9, 2021

Looks like the hardware & interface has been changed. My RJ45 port doesn't have pin 7 populated. I was still getting 14 Vdc between pin 1 & 8. It appears pins 3 to 6 all could have connections to the main PCB. Haven't hooked it up to a scope yet...

Finally hooked it up to scope. Pins 3 & 4 seemed to have a constant 5V and 5 & 6 were at ground with a bit of noise. I couldn't detect anything that looked like a signal. I ordered a U+ CONNECT MODULE PBX23W00Y0 to try to get some insight into what was going on with this alternate interface.

@mulcmu
Copy link

mulcmu commented Jan 4, 2022

I've made some progress on getting my dryer integrated into HA. It has the half duplex GE bus on pin 7 of the RJ45. I didn't have luck with mosfet based level shifting using 2N7000 or TXS0104E level shifting IC. Finally got rx & tx working on breadboard with dryer using non-inverting buffer IC.

Untitled
Edit: 1/29/22 Fixed diode direction in figure.

I was using a adjustable DC/DC switching module for the 5v power supply (https://www.amazon.com/gp/product/B01MQGMOKI/). The dryer was able to power both the ESP32 and U+CONNECT MODULE at the same time.

ESPHome custom component and full schematic are posted here https://github.com/mulcmu/esphome-ge-dryer-uart

Edit: my washer has the full duplex GEA3 bus. I've built and tested rev 0.2 of my PCB. Rev 0.3 was uploaded with some fixes and a few extra items.

@mightymos
Copy link

mightymos commented Jun 13, 2022

Wiring diagrams for specific machines can be requested here:
https://products.geappliances.com/appliance/gea-support-search-content?contentId=19249

GTW460ASJ6WW (washer) with RJ45 GEA3 pinout shown:
GTW460ASJ6WW_Washer_WiringDiagram.pdf

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

5 participants