TMC is an independent, primarily volunteer organization that relies on ad revenue to cover its operating costs. Please consider whitelisting TMC on your ad blocker or making a Paypal contribution here: paypal.me/SupportTMC

Open ChargePort

Discussion in 'Model S: Battery & Charging' started by Fuzzylogic, Sep 4, 2013.

  1. Fuzzylogic

    Fuzzylogic EU Sport 359 & S94

    Joined:
    Jun 23, 2009
    Messages:
    336
    Location:
    The Netherlands
    #1 Fuzzylogic, Sep 4, 2013
    Last edited: Jan 7, 2014
    Open Chargeport

    What is it?
    As the name suggests, it's a transmitter that will open the charge port of a Model S.


    Last week I received my EU spec model S, and charged a few times with the cable Tesla supplies with the car.
    The button to open the Charge port door, really is a nice feature.
    As there is no such thing on a standard Type 2 charge cable, i now have to open the car door, touch the battery icon, and select open charge port. Not very convenient.

    Therefore i wanted to make my own transmitter that opens the chargeport, and that can be fitted into a standard Type2 plug.

    Credits to Banahogg who documented his attempts to analyze the RF data here
    which helped me finish this project in a few days.



    The components needed:

    I used a 433 Mhz module connected to a PIC microcontroller. (US model S, might require a 315Mhz module)
    Only a few other components are required.

    1x PIC12F1822 microcontroller
    1x TX-SAW MID/3V
    1x Lithium cell, 3V
    2x 100nf capacitor
    1x 10uf capacitor
    1x pushbutton

    Feel free to build your own Open Chargeport, or improve it. PIC sourcecode can be downloaded from Github:
    OpenChargeport

    The chip inside the Model S charge plug is a Si4010, i have made a version for this chip as well, will upload it to Github soon.


    OpenChargePort.jpg
     
  2. Doug_G

    Doug_G Lead Moderator

    Joined:
    Apr 2, 2010
    Messages:
    15,851
    Location:
    Ottawa, Canada
    FYI 433 MHz is legal for this type of usage in the USA, and in fact is the one frequency permitted almost everywhere. So it's probably the same transmitter.
     
  3. markwj

    markwj Moderator, Asia Pacific

    Joined:
    Apr 10, 2011
    Messages:
    3,661
    Location:
    Hong Kong
    Nice. Very nice. Now, hcsharp to integrate to one of his cans...
     
  4. mknox

    mknox Well-Known Member

    Joined:
    Aug 7, 2012
    Messages:
    8,556
    Location:
    Toronto, ON
    Some smart meter systems operate near this frequency. I wonder if the meter would pop the charge port when it transmits if the car was parked nearby?
     
  5. widodh

    widodh Model S R231 EU

    Joined:
    Jan 23, 2011
    Messages:
    4,822
    Location:
    Middelburg, The Netherlands
    Which exact 433Mhz channel is it? Since I have a lot of 433Mhz transmitter lying around here.
     
  6. PearlModelS

    PearlModelS Member

    Joined:
    Feb 20, 2013
    Messages:
    47
    Location:
    LI
    Brilliant.

    I see a new product developing. How about one that attaches to the key fob?
     
  7. Fuzzylogic

    Fuzzylogic EU Sport 359 & S94

    Joined:
    Jun 23, 2009
    Messages:
    336
    Location:
    The Netherlands
    The frequency is 433.92 MHz. Please see the datasheet of the Aurel TX SAW/MID for more info.
    Important is that you use a AM/ASK module. FSK will not work.

    @mknox Smart meters and any other devices that transmit on this frequency will not open the charge port, as it's a 50 bit code that is used. The chance of that being the same as a smart meter is almost zero.
     
  8. LuckyLuke

    LuckyLuke Model S P85DL

    Joined:
    Dec 14, 2011
    Messages:
    2,092
    Location:
    Eindhoven, The Netherlands
    Great work Fuzzy! A lot of people will be looking for this functionality.
    Would be nice to include this inside a Female type 2 plug with a small push button for instance, most (cheaper) type 2 plugs can be opened/closed with screws.
     
  9. Lloyd

    Lloyd Active Member

    Joined:
    Jan 12, 2011
    Messages:
    4,885
    Location:
    San Luis Obispo, CA
    I would like to have one mounted in my trunk. I typically store my J1772 adapter in the rear trunk.
     
  10. Fuzzylogic

    Fuzzylogic EU Sport 359 & S94

    Joined:
    Jun 23, 2009
    Messages:
    336
    Location:
    The Netherlands
    I looked inside the plug already, but there is very little room for a decent (waterproof) push button.
     
  11. efusco

    efusco Moderator - Model S & X forums

    Joined:
    Mar 29, 2009
    Messages:
    4,589
    Location:
    Nixa, Missouri, United States
  12. PhilBa

    PhilBa Active Member

    Joined:
    Apr 20, 2013
    Messages:
    1,355
    Location:
    Seattle
    Interesting idea. I get "invalid attachment" when I try to download the source. What is the waveform you are sending? I was thinking of a quick proto with an arduino.
     
  13. Bugeater

    Bugeater Member

    Joined:
    May 11, 2013
    Messages:
    443
    Location:
    Silicon Valley
    Why don't you put the transmitter into the J1772 adapter?
     
  14. Fuzzylogic

    Fuzzylogic EU Sport 359 & S94

    Joined:
    Jun 23, 2009
    Messages:
    336
    Location:
    The Netherlands
    Sorry, fixed the download link.

    The sourcecode is for a Microchip PIC 12F1822 chip, and written in assembler.
    The HEX file is also included, which you can directly program in the PIC chip.

    It takes less then 100 words of program space, and doesn't use any peripherals other then one timer. So it should be relatively easy to use another microcontroller.
     
  15. LuckyLuke

    LuckyLuke Model S P85DL

    Joined:
    Dec 14, 2011
    Messages:
    2,092
    Location:
    Eindhoven, The Netherlands
    I wonder if there aren't any programmable keychain transmitters available that can be learned to send this 50-bit code?
    I googled a bit already but not sure what to look for.
     
  16. TonyWilliams

    TonyWilliams Active Member

    Joined:
    Jun 11, 2012
    Messages:
    1,001
    Location:
    San Diego - Tesla powered Rav4 EV
    #16 TonyWilliams, Sep 5, 2013
    Last edited: Sep 11, 2013
    This is the actual transmitter circuit card in the UMC:

    S1 is the switch for the J1772 proximity circuit. R1 is the 150 ohm resistor that signals the proximity pin is connected to the car. When the S1 switch is pressed (open), the 330 ohm resistor R2 is added in series to R1, creating 480 ohms to ground (150 + 330) which signals to disconnect. Yep, that simple.

    S2 is the switch for the transmitter that opens the Model S charge port. It is powered from the UMC with 3.3 volts from the blue wire (not pictured).

    IMG_2134.jpg
     
  17. FlasherZ

    FlasherZ Sig Model S + Sig Model X + Model 3 Resv

    Joined:
    Jun 21, 2012
    Messages:
    7,019
    My wife would probably kill me if I added yet another project to my UTAH list (Unfinished Things Around the House). If someone else has a smaller UTAH list, I'd love to see a keyfob version, as small as possible, and would pay for it.
     
  18. Eberhard

    Eberhard #421 Model S #S32

    Joined:
    Oct 17, 2010
    Messages:
    1,141
    Location:
    Germany
    I dont understand, why tesla didnt include this function into the key.
     
  19. zax123

    zax123 CDN Model S P308

    Joined:
    Jun 4, 2012
    Messages:
    911
    Location:
    Candiac, QC, CAN
    Does the keyfob use the same frequency?
     
  20. lolachampcar

    lolachampcar Active Member

    Joined:
    Nov 26, 2012
    Messages:
    4,446
    Location:
    WPB Florida
    I've asked the above poster for the board and will order the Silicon Labs dev board set up shortly. It comes with a fob and a receiver. With luck, I can use the receiver to determine the code then program that into the fob. I'll check DigiKey to see if they sell just the fobs (for those that want one).

    I'm a digital guy and, although I've did a good bit of work years ago with the SL 8051 stuff, I'm not really up on transmission protocols. I'll try to "educate myself up" on the basics of AM/ASK versus FSK while I'm waiting on the demo board. By chance has anyone absolutely confirmed the operating frequency for the US as low 300s is not one of the three frequencies offered in the dev. board sets?
    "Important is that you use a AM/ASK module. FSK will not work."
     

Share This Page