HSI for Gen II with Arduino and CAN-BUS Shield

Discussion in 'Gen 2 Prius Accessories & Modifications' started by alexmol, Apr 15, 2011.

  1. alexmol

    alexmol Junior Member

    Joined:
    Feb 24, 2011
    21
    22
    0
    Location:
    Portugal
    Vehicle:
    2005 Prius
    Model:
    N/A
    Hi!

    I'm developing an HSI bar for the second gen using an Arduino and the CAN-BUS Shield.

    Hardware is just the Arduino UNO, Can-Bus Shield, 2x16 Serial LCD Display and a OBD Cable.

    I'll post the Arduino code later here. For the moment I only read passive CAN messages.

    I've developed the graphical part using only 8 custom caracters, which was the most difficult part so far.


    The bar currently shows:

    Braking pedal - from 0 to 20% fills the regeneration bar on the left
    Gas-Pedal: dinamically fills the main bar, the first half is electric-only mode (if the car is warmed up), second half is from ICE ignition till about 2200RPM, power section if from about 2300 rpm till 65% gas-pedal position.

    Battery current, in Amps
    Cooling liquid temperature, in degC
    RPM

    Pictures and videos coming soon.

    Best Regards
    Alexandre
     
    3 people like this.
  2. alexmol

    alexmol Junior Member

    Joined:
    Feb 24, 2011
    21
    22
    0
    Location:
    Portugal
    Vehicle:
    2005 Prius
    Model:
    N/A
    Here's a video of the first stage of development, basicaly like a scangauge, where it reads gas-pedal, brake-pedal, rpm, battery current and cooling liquid temperature.


    I can't post links yet (new in the forum) so just go to youtube and search for:

    Desenvolvimento de uma barra HSI para o Prius 2G
    (sorry the video is in portuguese, I'll try to make an english version if this thread gets popular)


    Best Regards
     
    2 people like this.
  3. seilerts

    seilerts Battery Curmudgeon

    Joined:
    Mar 7, 2010
    3,326
    1,489
    38
    Location:
    Santa Fe, NM
    Vehicle:
    2005 Prius
    That looks really nice!
     
  4. ccdisce

    ccdisce Active Member

    Joined:
    Oct 10, 2010
    259
    144
    0
    Location:
    Stone Mtn GA USA
    Vehicle:
    2008 Prius
    Model:
    N/A
    Custom Fonts are just tedius having done them before for my Ford Info Panel.

    Looks great! Thanks.
     
  5. 2009Prius

    2009Prius A Wimpy DIYer

    Joined:
    Mar 25, 2009
    2,703
    484
    63
    Location:
    USA
    Vehicle:
    2009 Prius
  6. Dolce_Vita

    Dolce_Vita Member

    Joined:
    Apr 2, 2010
    228
    25
    0
    Location:
    Sydney, Australia
    Vehicle:
    2008 Prius
    Model:
    N/A
    I cant see the videos, but i'm very interested!
     
  7. alexmol

    alexmol Junior Member

    Joined:
    Feb 24, 2011
    21
    22
    0
    Location:
    Portugal
    Vehicle:
    2005 Prius
    Model:
    N/A
    I'll post the links to the videos later, when I have access to the posting link functionality, I'm still a junior member here :rolleyes:

    Or maybe one of you senior members can post the links...

    I've now tested the HSI bar with good results but I'm still missing some things.

    One of them is B-mode. How should the CHG bar behave when in B-mode.
    The drag regeneration is greater, but besides that should the bar behave differently than in D-mode?

    How does it work on the 2010 Prius?

    How would you like to work?

    Regards
     
  8. PaJa

    PaJa Senior member

    Joined:
    Sep 3, 2009
    678
    113
    92
    Location:
    Czech republic
    Vehicle:
    2017 Prius
    Model:
    N/A
    PART 1:
     
  9. BrettS

    BrettS Active Member

    Joined:
    Jan 18, 2011
    287
    120
    0
    Location:
    Orlando
    Vehicle:
    2010 Prius
    Model:
    III
    That looks like a very interesting project. The HSI screen is the one that I leave up 99% of the time when I'm driving my 2010 and I've found that it provides the best information for me.

    I can answer some of your questions about how the CHG bar behaves in a 2010. The CHG bar is based on the amount of charge being generated by the regen system and is not based on brake pedal position. For example, if you're traveling at 40MPH and you press the brakes you'll see the CHG bar fill up. As the car slows down you'll see the CHG bar start to decrease (even though you haven't changed the position of the pedal) as the car gets under 10MPH or so and starts to switch to the friction brakes you'll see the CHG bar drop to almost 0.

    If you're driving along and lift your foot off of both pedals the CHG bar expands to about 1MM as the car introduces a very small amount of regen instead of actually coasting.

    If you put it in B mode and lift your foot off of both pedals the CHG bar will be about 2 or 2.5MM long as the car introduces more regen to slow it down faster.

    Like I said, I've been driving my 2010 for some time using the HSI indicator and there are a few things that I wish I could see that are not shown on the 2010, but I think you've covered most of them with your device. I'd most like to see the amount of current going to or from the battery as well as the ICE RPM. The coolant temp is good too.

    I'd also like to see an indication of whether the ICE was on or not. Usually I can tell by looking at the MPG display... if it's pegged at 100MPG then most likely the ICE is off (although sometimes coasting at a high speed with the ICE on will also peg it at 100MPG) It's also impossible to tell using this method when the vehicle is stopped. In that case it always displays 0MPG whether the ICE is on or not. Although, I suppose with your device you can tell if it's on or not by looking at the ICE RPM number.

    The other thing that might be interesting to do with your display would be to have the CHG bar work all the time and not just display the regen charge. On the 2010 when the ICE is on and the generator is ingaged to recharge the battery it still doesn't show anything on the CHG bar. It might be nice to see when the battery is being charged and how much power is being provided by the generator.

    hope this helps,
    Brett
     
    1 person likes this.
  10. alexmol

    alexmol Junior Member

    Joined:
    Feb 24, 2011
    21
    22
    0
    Location:
    Portugal
    Vehicle:
    2005 Prius
    Model:
    N/A
    Thanks for all the info Brett!

    With my device I can easily see if the ICE is off or in high speed coasting mode by looking at the instant RPM (lower right). If its around 960 then it's in that mode.

    By watching the instant battery current (lower left) I can see how much current is beeing fed into the battery when in recharging mode or during regenerative braking.

    Basically I think I can get all the info you would like to see, although not all in graphical mode.


    My ideia for the CHG bar would be to aid the driver in not using the friction brakes...

    I'll try to program the CHG bar to work with current flowing into the battery and see if it's much different from my actual implementation.

    Also I still have some doubts about the behavior of the CHG bar in B-mode during braking.

    Above 22mph if you engage B-mode the ICE will rev to do engine braking. In that condition how does the CHG bar behave?

    Many thanks!
    Alex
     
  11. alexmol

    alexmol Junior Member

    Joined:
    Feb 24, 2011
    21
    22
    0
    Location:
    Portugal
    Vehicle:
    2005 Prius
    Model:
    N/A
    Here's another video showing sleep mode and dimmer functions.

    It also shows EV mode detection and my prefered placement of the LCD

     
  12. alexmol

    alexmol Junior Member

    Joined:
    Feb 24, 2011
    21
    22
    0
    Location:
    Portugal
    Vehicle:
    2005 Prius
    Model:
    N/A
    Here's the first English spoken video o the current status of my hsi bar with Arduino.

     
    pashko90, babybird, F8L and 3 others like this.
  13. usbseawolf2000

    usbseawolf2000 HSD PhD

    Joined:
    Sep 22, 2004
    14,487
    2,985
    0
    Location:
    Fort Lee, NJ
    Vehicle:
    2012 Prius Plug-in
    Model:
    Plug-in Base
    This is awesome. How do I get one? :d
     
  14. cwa

    cwa Member

    Joined:
    Mar 15, 2011
    41
    2
    0
    Location:
    Colombo
    Vehicle:
    2008 Prius
    Model:
    N/A
    Hi Alexandre,

    This is one of the best interfaces I have seen ever. Do you plan to rebuild more units? Even as it is, this will be very useful to many prius GenII users.

    Sorry for this dumb question, but is this interface depend on OBDII? The reason is My Prius is GenII, but JDM. It does not recognise OBDII devices.

    CWA
     
  15. efusco

    efusco Moderator Emeritus
    Staff Member

    Joined:
    Nov 26, 2003
    19,886
    1,163
    9
    Location:
    Nixa, MO
    Vehicle:
    2004 Prius
    Model:
    N/A
    When you get that project finished be sure to contact Danny ([email protected]), the Prius Shop and PriusChat owner, I'm sure he'd be glad to sell them in the shop if you can produce enough. I think there'll be a really big market for them in the Gen II crowd.
     
    NortTexSalv04Prius likes this.
  16. usbseawolf2000

    usbseawolf2000 HSD PhD

    Joined:
    Sep 22, 2004
    14,487
    2,985
    0
    Location:
    Fort Lee, NJ
    Vehicle:
    2012 Prius Plug-in
    Model:
    Plug-in Base
    It looks like it can also be a DIY project. The parts cost about $100.

    Alexandre, are you getting the power from the ODBII port? Will someone with soldering skill be able to do this project? My understanding is, connect all the pieces and then program it through a USB cable.
     
  17. F8L

    F8L Protecting Habitat & AG Lands

    Joined:
    Aug 14, 2006
    19,011
    4,066
    50
    Location:
    Grass Valley, CA.
    Vehicle:
    Other Non-Hybrid
    Model:
    N/A
    So it look slike this has a couple of cool features lacking in the SGII but the SGII has a lot of features this lacks. Can the two be used at the same time with an OBDII splitter?
     
  18. usbseawolf2000

    usbseawolf2000 HSD PhD

    Joined:
    Sep 22, 2004
    14,487
    2,985
    0
    Location:
    Fort Lee, NJ
    Vehicle:
    2012 Prius Plug-in
    Model:
    Plug-in Base
    After further research, it looks like all the parts plug right in, without any soldering.

    I am tempting to buy the necessary hardware if Alexandre is so kind to share his work.

    F8L, this thing can have all the features SGII have plus more since the firmware is open source. I believe you can even have a bigger color LCD screen! However, the current example firmware uses 2x16 screen.
     
  19. telmo744

    telmo744 HSD fanatic

    Joined:
    Apr 8, 2010
    2,121
    737
    0
    Location:
    Portugal
    Vehicle:
    2010 Prius
    Model:
    N/A
    Olá, Alexandre!
    Keep up the good work!...
     
  20. alexmol

    alexmol Junior Member

    Joined:
    Feb 24, 2011
    21
    22
    0
    Location:
    Portugal
    Vehicle:
    2005 Prius
    Model:
    N/A
    Hi all!

    Thanks for the comments.

    I'm still fixing 2 problems, after that I can sell the device if enough hardware is available. Before selling I still have to get some nice boxes for the controller and the LCD.

    Still to fix:

    -Standby current is about 50mA, too high for "use and forget" as it can deplete your 12V battery if you don't use the car for a long time. This will probably lead to some hardware changes making it less friendly to those who want to build one but are not familiar with electronics.

    -LCD will withstand summer temperatures inside the car?

    The current version is also an open source project. Anyone can buy the parts and build it, no tools necessary, just a USB cable and the Arduino software to upload the code. I'll post a link to the code later.
    If you plan to build one be advised that the code was developed for the sparkfun 2x16 serial LCD, it will only work with that because of the programming of the custom characters necessary to draw the bar.
    If you use another brand of serial LCD 2x16 you will need to alter the code for programming the custom characters (minimus 8 custom characters, each character 5x8 pixels).

    It gets the CAN-BUS signals and 12V from the OBD port. Should work on all 2nd gen Prius and even on 3G (haven't tested yet).

    Hope I answered all your questions!

    Regards
    Alex
     
    macandlinuxuser and babybird like this.
Loading...