Go Back   EcoModder Forum > EcoModding > Fossil Fuel Free > Open ReVolt: open source DC motor controller
Register Now
 Register Now
 

Reply  Post New Thread
 
Submit Tools LinkBack Thread Tools
Old 02-17-2011, 09:48 AM   #11 (permalink)
EV Builder
 
Freyguy's Avatar
 
Join Date: Nov 2010
Location: Macungie, PA
Posts: 157
Thanks: 15
Thanked 64 Times in 40 Posts
Thanks Jackbauer! As is the work I've seen you post.
Got the image link thing working with Paul's help, so you can see the pcb in my previous post.
As for the code- Well, I'm a guy that does things the hard way, that is... ALL of this is done in PIC assembler. I'm not a glutton for punishment, I just never learned C. I worked in new product development for 14 years and as a hardware designer, I only had to design the schematic & pcb, then write a specifications document for the software engineer. Sure, I'd write little assembly routines to verify functions on all I/O in my designs, but they did all the heavy lifting.
This probably represents the most code I've written since school (think Intel8088). That being said, making this have a serial command interface to change parameters would be a significant undertaking for me.
A $35 investment in a PIC programmer along with downloading the free MPLAB IDE is the only option. You open up the project, go to the declared variables section and change parameters. I have this well commented in the code and I plan on doing a step by step writeup showing how to change, recompile and reprogram the part.
However, anyone with a background in programming PICs in C and who is interested in this project is welcome to add the serial command interface. While they'd need to purchase all the hardware themselves I would donate my spare PCB (I had 2 done by BatchPCB).

  Reply With Quote
Alt Today
Popular topics

Other popular topics in this forum...

   
Old 02-17-2011, 10:06 AM   #12 (permalink)
Custom EV Builder...
 
Join Date: Jul 2009
Location: Ohio
Posts: 57
Thanks: 8
Thanked 1 Time in 1 Post
Quote:
Originally Posted by Freyguy View Post
Hey Thanks guys!
Mr Bigh- the display is easily readable at 3'. Reason I chose the oversized character version. It could work in parallel with RTD Explorer only if RTD is used to receive data from the Cougar. Both RTD and the LCD can't transmit unless you incorporate some kind of A/B distribution switch. More than 2 profiles gets complicated and now you need an indicator showing which one you're running with.

Wakinyantanka- As long as the status message sent from the high amp version is formatted the same it should be compatible. If the configuration parameters are different, it shouldn't matter since the user programs in the serial data he wants transmitted as his "profile".
DCB- Yes, every pin is used up. You could drop in a PIC18F2420 which is the same part without the CANbus. The two I/O lines for CAN then become standard I/O.
So the crazy people like me that are shooting for 2000 amps with our controllers could set it up to read the amperage draw? That would be awesome!!!
  Reply With Quote
Old 02-17-2011, 10:25 AM   #13 (permalink)
dcb
needs more cowbell
 
dcb's Avatar
 
Join Date: Feb 2008
Location: ÿ
Posts: 5,038

pimp mobile - '81 suzuki gs 250 t
90 day: 96.29 mpg (US)

schnitzel - '01 Volkswagen Golf TDI
90 day: 53.56 mpg (US)
Thanks: 158
Thanked 269 Times in 212 Posts
For the budget minded, there is a $17.50 pickit 2 clone here that I have used successfully:
Build A PIC Programmer Based On PIC18A Prototyping Board
__________________
WINDMILLS DO NOT WORK THAT WAY!!!
  Reply With Quote
The Following 2 Users Say Thank You to dcb For This Useful Post:
DawidvC (02-17-2011), Freyguy (02-17-2011)
Old 02-17-2011, 01:24 PM   #14 (permalink)
Master EcoModder
 
Join Date: Nov 2008
Location: 18603, USA
Posts: 759

The Crimson Crawler - '04 Hyundai Elantra GLS
90 day: 36.71 mpg (US)
Thanks: 221
Thanked 60 Times in 45 Posts
Macungie, PA? A LOCAL! Well, sort of. I work in Allentown, but live northward. I'm working towards an EV conversion of my own - this will be a great addition!
  Reply With Quote
Old 02-17-2011, 01:40 PM   #15 (permalink)
Master EcoModder
 
jackbauer's Avatar
 
Join Date: Sep 2009
Location: Ireland
Posts: 734
Thanks: 26
Thanked 304 Times in 171 Posts
Started out with the 6809 myself back in the day. Did a lot of pic assembler starting on the 16C54. I'm not much good with c but find mikrobasic very easy to use. i am so building me one of these
__________________
Now, Cole, when you shift the gear and that little needle on the ammeter goes into the red and reads 2000 Amps, that's bad.
www.evbmw.com
  Reply With Quote
Old 02-17-2011, 08:39 PM   #16 (permalink)
EV Builder
 
Freyguy's Avatar
 
Join Date: Nov 2010
Location: Macungie, PA
Posts: 157
Thanks: 15
Thanked 64 Times in 40 Posts
Wakinyantanka,
Currently the range for CF and BA are 511.Most likely due to the 2.5~5V range of the LEM which corresponds to 511 steps of the 10-bit(1024) range of the Atmega A/D. This voltage range shouldn't change with Paul's Melexis part for high amp controller. So 1000A will still be conveyed over the same 511 steps. In my firmware there is a "scaler"parameter associated with motor amps. It was added because my custom Cougar firmware's full throttle range is 600A versus standard 500A, so I needed to scale CF's 511 range to 600. I see no problem with this being able to scale to 1000A.
  Reply With Quote
The Following User Says Thank You to Freyguy For This Useful Post:
wakinyantanka (02-18-2011)
Old 02-17-2011, 08:49 PM   #17 (permalink)
EV Builder
 
Freyguy's Avatar
 
Join Date: Nov 2010
Location: Macungie, PA
Posts: 157
Thanks: 15
Thanked 64 Times in 40 Posts
Quote:
Originally Posted by Nevyn View Post
Macungie, PA? A LOCAL! Well, sort of. I work in Allentown, but live northward. I'm working towards an EV conversion of my own - this will be a great addition!
Ya, Macungie is home of the car shows.....Wheels of Time, Das Awkscht Fescht, and don't forget the Macungie EV show. That one is April 30th this year. I hope to see you there Nevyn! I'll be there even if my car isn't ready
  Reply With Quote
The Following User Says Thank You to Freyguy For This Useful Post:
Nevyn (02-18-2011)
Old 02-17-2011, 08:58 PM   #18 (permalink)
EV Builder
 
Freyguy's Avatar
 
Join Date: Nov 2010
Location: Macungie, PA
Posts: 157
Thanks: 15
Thanked 64 Times in 40 Posts
Quote:
Originally Posted by jackbauer View Post
Started out with the 6809 myself back in the day. Did a lot of pic assembler starting on the 16C54. I'm not much good with c but find mikrobasic very easy to use. i am so building me one of these
16C series huh? I've worked with them and can tell you the 18F's are SO much better. Larger instruction set which includes compares, and 8x8 hardware multiplier which I use FREQUENTLY in my code. I'll have to look into mikrobasic.
  Reply With Quote
Old 02-18-2011, 09:18 AM   #19 (permalink)
Custom EV Builder...
 
Join Date: Jul 2009
Location: Ohio
Posts: 57
Thanks: 8
Thanked 1 Time in 1 Post
Quote:
Originally Posted by Freyguy View Post
Wakinyantanka,
Currently the range for CF and BA are 511.Most likely due to the 2.5~5V range of the LEM which corresponds to 511 steps of the 10-bit(1024) range of the Atmega A/D. This voltage range shouldn't change with Paul's Melexis part for high amp controller. So 1000A will still be conveyed over the same 511 steps. In my firmware there is a "scaler"parameter associated with motor amps. It was added because my custom Cougar firmware's full throttle range is 600A versus standard 500A, so I needed to scale CF's 511 range to 600. I see no problem with this being able to scale to 1000A.
Paul's quote of readable amperage was very funny. Could the scale be adjusted to 2000A?
  Reply With Quote
Old 02-18-2011, 11:47 AM   #20 (permalink)
Master EcoModder
 
Join Date: Nov 2008
Location: 18603, USA
Posts: 759

The Crimson Crawler - '04 Hyundai Elantra GLS
90 day: 36.71 mpg (US)
Thanks: 221
Thanked 60 Times in 45 Posts
Didn't know about the EV show - I'll have to put it on my calendar!

  Reply With Quote
Reply  Post New Thread






Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Content Relevant URLs by vBSEO 3.5.2
All content copyright EcoModder.com