1. Attachments are working again! Check out this thread for more details and to report any other bugs.

My Duinomite Mega Canview V4 equivalent Project

Discussion in 'Prius PHEV Plug-In Modifications' started by lopezjm2001, Jul 19, 2012.

?
  1. Yes

    11 vote(s)
    100.0%
  2. Prefer to use Android Torque device

    0 vote(s)
    0.0%
  3. Prefer to use Scangauge

    0 vote(s)
    0.0%
  1. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    Thanks for the info. I have been busy building a 40ah A123 battery pack.

    Can you put your changes to the Basic code in bold. So I can clearly see what you added.

    Have you found anything by logging the DTCs.
     
  2. SynEco@eVehicle.co.nz

    Joined:
    Jan 9, 2007
    139
    19
    0
    Vehicle:
    2004 Prius
    Model:
    II
    Hope you documenting with Pics your A123 build ??

    .. considering using these for my next project ... . a PHEV SUV
     
  3. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    Yes, I have been taking photos and I will make a post on the other thread "Planning Canview and BMS+ conversion with Lithium". There are other documented conversions on this thread by Planetaire, Mr Plugin and FWD. Planetaire has the best Conversion for a 20AH A123 pack.

    It is still early days. I still have a long way to go.

    The A123 20AH cells supply in China has dried up. I had to accept A123 cells with no markings.
     
    NortTexSalv04Prius likes this.
  4. SynEco@eVehicle.co.nz

    Joined:
    Jan 9, 2007
    139
    19
    0
    Vehicle:
    2004 Prius
    Model:
    II
    They all have "SynECO" in the comment on each line
     
  5. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    OK
     
  6. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    I have made an update to the basic program. I found a bug. The subroutine for inversebyte is incorrect, only half the code works.
    Code:
    inversebyte:
      If bmsvolts = &HC3 Then voltsbms = &H3C : If bmsvolts = &HC8 Then voltsbms = &H8C
      If bmsvolts = &HCD Then voltsbms = &HDC : If bmsvolts = &HD2 Then voltsbms = &H2D
      If bmsvolts = &H7D Then voltsbms = &HD7 : If bmsvolts = &HDC Then voltsbms = &HCD
      If bmsvolts = &HE1 Then voltsbms = &H1E : If bmsvolts = &HE6 Then voltsbms = &H6E
      If bmsvolts = &HEB Then voltsbms = &HBE
    Return
    It should be:
    Code:
    inversebyte:
      If bmsvolts = &HC3 Then voltsbms = &H3C  'PHEV mode 195v
      If bmsvolts = &HC8 Then voltsbms = &H8C  'PHEV mode 200v
      If bmsvolts = &HCD Then voltsbms = &HDC  'PHEV mode 205v
      If bmsvolts = &HD2 Then voltsbms = &H2D  'PHEV mode 210v
      If bmsvolts = &H7D Then voltsbms = &HD7  'PHEV mode 215v
      If bmsvolts = &HDC Then voltsbms = &HCD  'PHEV mode 220v
      If bmsvolts = &HE1 Then voltsbms = &H1E  'PHEV mode 225v
      If bmsvolts = &HE6 Then voltsbms = &H6E  'PHEV mode 230v
      If bmsvolts = &HEB Then voltsbms = &HBE  'PHEV mode 235v
    Return
    I have added a warning for a depleted battery that will work in either forcedEV mode or PHEV mode and changed the F2 key to enable/disable the warning.

    Here is the added code:

    Code:
    updateWarn()  'main loop
     
    If K$ = Chr$(146)  Then F2() ' Forced EV PHEV battery depleted warning switch
     
    Sub F2
      ' If R2 = 0 Then R2 = 1 Else R2 = 0
      If Warningpage=1 then Warningpage=0 Else Warningpage=1
      font 1
      If page=0 then
    	If Warningpage=1 then Print @(10,370) "Warning ACTIVE"; else Print @(10,370) "			  ";
      Endif
    End Sub
     
    Sub Updatewarn
      If warningpage=1 then
    	If (R4=0 and SoC<=73 and warn=0 and SoC<>65) then
    	  page=25 : warn=1 : Gosub warningVGA
    	Endif
    	If R4=1 then
    	  warn=0
    	  warningpage=0
    	Endif
      Endif
      If page=0 then
    	If Warningpage=1 then Print @(10,370) "Warning ACTIVE"; else Print @(10,370) "			  ";
      Endif
    End Sub
     
    If K$ = Chr$(27) Then
    	page=0 : warn=0 : GoSub printHeader : GoSub drawboxes : GoSub drawlabels_lhs : GoSub drawlabels_rhs : UpdateF4()
    	counter=counter+1
    	If counter=>3 then AHT=0
      Endif
     
    WarningVGA:
      If warn=1 then
    	cls : Font 2,2,1 : Print @(80,150) "!! WARNING !!"
    	Font 2,1,0 : Print @(100,250) "PHEV battery pack depleted"
    	Print @(100,300) "Press F4 and then ESC to exit"
      Endif
    Return
     

    Attached Files:

    mrbigh likes this.
  7. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    I bought a new Duinomite Mega from Olimexery on Ebay as a back-up and for programming. It comes loaded with DMbasic firmware, I have changed it to MMBasic so it can be used with my program, below are the instructions I made up to download the latest firmware of MMBasic V4.3. It is just a matter of following the instructions below and it is ready to go. The instructions below have been tested and proven with a brand new Duinomite Mega

    STEP BY STEP USING A COMPUTER WITH WINDOWS 7 (CANVIEW FOR DUMMIES) 10/04/2013

    The Duinomite Mega is delivered with it's own version of basic called DMbasic which we no longer use. We need to install the latest firmware version of MMbasic with CAN by Geoff Graham. We need to dowload two zip files from this website: Geoff's Projects - The Colour Maximite

    1. Download "Duinomite MMbasic firmware Version 4.3" (or whichever is the latest version at the time) and also download "Special version of V4.3 with CAN commands (controller area network)" from this website Geoff's Projects - The Colour Maximite. Save it to your desktop.

    MMbasic_web.JPG

    2. Using the WINzip program (or any other kind of ZIP program) to extract "MMBasic with CAN.ZIP" and save the file "Duinomite_MMBasic_V4.3 with CAN.hex" to your computer desktop.

    MMbasic with CAN files.JPG

    3. Using the Winzip program unpack the zip file "Duinomite_MMBasic.ZIP" and save the file "BootLoader.exe" to your desktop.

    Duinomite_mmbasic_files.JPG

    4. Now run the program "BootLoader.exe". Should look like this:

    BootLoader.JPG

    5. Connect the miniUSB cable from your computer to your Duinomite Mega. Now the Duinomite Mega is powered by the miniUSB cable only.

    MiniUSB_cable.jpg

    6. Connect miniUSB cable from your computer to your Duinomite Mega. Press the black button on the side of the Duinomite Mega (there are two black buttons, so use the one closest to the USB plug) at the same time as you plug in the miniUSB cable. You should see the green LED and amber LED flashing. This indicates that the Duinomite Mega is ready for firmware download.

    BootLoader_2.JPG

    7. Using your mouse click the button "Load Hex File". Now should look like this:

    Bootloader_3.JPG

    8. Using your mouse select the file "Duinomite_MMBasic_V4.3 with CAN". Select the button "Open". Should now see the following:

    BootLoader_4.JPG

    9. Using your mouse now press the button "Program Device". Now you should see the following:

    BootLoader_5.JPG

    10 . Now follow the instructions by restarting the device. This can be done by replugging the miniUSB cable.

    You can see this Youtube video which shows you how the green LED and the amber LED flash when it is ready to accept a new firmware download (online mode) :


    11. Download my latest files to go into the microSD card root directory i.e.http://priuschat.com/attachments/canview_v4_bms-_nc_29032013-zip.48759/. You will need to UNZIP the files. It is attached in the first post of this thread. Note the numbers 29032013 is the date, so use the latest date. Read the readme.txt file included.

    The basic program is called "AUTORUN.BAS" and will run automatically when the Duinomite Mega is booted/rebooted or when the Prius READY signal becomes true.

    You will also need to purchase a seperate microSD card, miniUSB cable, PS2 keyboard and a VGA monitor.

    Good luck!!

    microSDcard.jpg


    DSC04894.jpg
     
    dave77 and [email protected] like this.
  8. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    Video has been updated on first post to show faster updates and the different pages.
     
  9. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    I guess it is better late than never. I measured about 79.7mA @13.8volts DC = 1.10 watts when the basic program was in standby mode.
    DMcomsumption_program_strandby_mode.jpg

    I also measured about 105.3mA @13.8Vdc = 1.45 watts in run mode with a VGA screen and a PS2 keyboard..

    DMcomsumption_program_run_mode.jpg

    That is a good low power consumption!!
     
  10. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    My latest basic program for the Duinomite Mega is now available in my first post of this thread. It includes a few extras.

    The default end voltage is now 210v, same as Norm's Canview.

    There is a instant clearing of DTC for OutOfGas mode users. After pressing the Prius power button the Canview will do a DTC check and if the OutOfGas DTC is returned it will automatically clear the DTC.

    The F2 - "Warning Active" is now visible on most pages.

    The PHEV battery Amp Hours is now shown on most pages.

    The F3 keyboard button now toggles between most pages for easy access.

    F5.JPG
    Added the highest, lowest, difference and Delta SoC of the NiMH to the F5 page.
    F6.JPG
    Added four time values of battery volts high, battery volts low, battery temperature high and DC inhibit.
    GAUGE13.jpg
    GAUGE16.jpg
    Added gauges, self explanatory.
    GAUGE17.jpg
    Gauge17 is a bar graph showing OEM NiMH module voltages. 17.3 volts represents the 100% charge value or SoC of 80%. The value of 13.2 volts represents a charge of 10%.
     
  11. SynEco@eVehicle.co.nz

    Joined:
    Jan 9, 2007
    139
    19
    0
    Vehicle:
    2004 Prius
    Model:
    II
  12. mrbigh

    mrbigh Prius Absolutum Dominium

    Joined:
    Sep 6, 2005
    3,686
    699
    2
    Location:
    Long Island, NY
    Vehicle:
    Other Electric Vehicle
    I missed this post, very nice job man.
    Congratulation for all the efforts made
     
  13. Flying White Dutchman

    Flying White Dutchman Senior Member

    Joined:
    Dec 29, 2007
    4,374
    313
    0
    Vehicle:
    Other Non-Hybrid
    Model:
    N/A
    yes also missed it ( but then again not online a lot )
    shame i am ( possibly ) going to sell my prius because thise really wants me to have this working again ;-)
     
    lopezjm2001 likes this.
  14. SynEco@eVehicle.co.nz

    Joined:
    Jan 9, 2007
    139
    19
    0
    Vehicle:
    2004 Prius
    Model:
    II
    Has it been updated for Maximite/DM Basic 4.4 ? Want to make use of the new WatchDog feature. Thanx.
     
  15. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    Have you tried downloading my latest basic program from the first post dated 30/08/2013. It works with mmbasic 4.3. Let me know if it works with mmbasic 4.4.
     
    [email protected] likes this.
  16. SynEco@eVehicle.co.nz

    Joined:
    Jan 9, 2007
    139
    19
    0
    Vehicle:
    2004 Prius
    Model:
    II
    OK ... thnx .. JIT :) Also want to change the AHT reset , I find other drivers manage to reset the AHT to zero when they try to clear the WARNING msg using ESC ...
     
  17. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    Maybe increase the ESC count to six (or higher) instead of three to reset the AHT.

    Other option is use a different key e.g. F1 to clear the warning page.

    Cannot think of a better solution. Let me know if you can think of a better idea.
     
  18. SynEco@eVehicle.co.nz

    Joined:
    Jan 9, 2007
    139
    19
    0
    Vehicle:
    2004 Prius
    Model:
    II
    I Was thinking press "R" key to reset with msg "Press Enter to Confirm reset of AHr or ESC to ignore"
     
  19. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    I am using a small keyboard with 21 keys (it fits nicely on top of the cup holder) which does not include a "R" key. Maybe just a confirmation will be suffice.

    At the moment I think the best solution is to use the KEYDOWN function which empties the keyboard buffer together with the DO/LOOP function should stop the accidental resetting of the AHT.
     
  20. lopezjm2001

    lopezjm2001 Senior Member

    Joined:
    Apr 14, 2009
    1,146
    407
    5
    Location:
    Sydney Australia
    Vehicle:
    Other Electric Vehicle
    Model:
    N/A
    I have made some mods to the basic program to address this problem. Give it a try for a while and let me know if it works.
    Changes:
    1. Added
    Code:
    DO WHILE KEYDOWN AND K$ <> "" : LOOP
    This code ignores keyboard input whist the same key is constantly pressed. Also empties keyboard buffer.
    2. PSD page is now the main page when powered up. PSD page also shows the temperature of MG2. I figured that the temperature of MG2 may need to be observed when running Prius in OutOfGas mode.
    3. When the depleted battery pack warning page now comes up you "Press F4 then F1 to exit" instead of "Press F4 and ESC to exit". Pressing F1 whilst warning is active will not change EV auto/manual mode of F1.

    New basic program has been uploaded to first post.