Go Back   EcoModder Forum > EcoModding > Fossil Fuel Free
Register Now
 Register Now
 

Reply  Post New Thread
 
Submit Tools LinkBack Thread Tools
Old 04-30-2018, 02:02 PM   #3171 (permalink)
PaulH
 
MPaulHolmes's Avatar
 
Join Date: Feb 2008
Location: Maricopa, AZ (sort of. Actually outside of town)
Posts: 3,832

Michael's Electric Beetle - '71 Volkswagen Superbeetle 500000
Thanks: 1,362
Thanked 1,202 Times in 765 Posts
Could you do:

stream-poscnt 1
data-stream-period 100

then slowly turn the motor shaft by hand to see if you get smoothly changing position. That will show that the encoder is working properly.

__________________
kits and boards
  Reply With Quote
The Following User Says Thank You to MPaulHolmes For This Useful Post:
wootwootman (05-01-2018)
Alt Today
Popular topics

Other popular topics in this forum...

   
Old 04-30-2018, 02:06 PM   #3172 (permalink)
Master EcoModder
 
Join Date: Sep 2010
Location: Saskatoon, canada
Posts: 1,488

Ford Prefect - '18 Ford F150 XLT XTR

Tess - '22 Tesla Y LR
Thanks: 746
Thanked 565 Times in 447 Posts
Quote:
Originally Posted by MPaulHolmes View Post
Could you do:

stream-poscnt 1
data-stream-period 100

then slowly turn the motor shaft by hand to see if you get smoothly changing position. That will show that the encoder is working properly.
I can do that! I could not remember which variable to turn on to check on the encoder. The mechanical rpm seems to be a random number generator when the output of the controller is not on

That will likely happen tonight as well
__________________
In THEORY there is no difference between Theory and Practice
In PRACTICE there IS!
  Reply With Quote
Old 04-30-2018, 04:27 PM   #3173 (permalink)
EcoModding Lurker
 
Join Date: Apr 2018
Location: UK
Posts: 7
Thanks: 0
Thanked 3 Times in 1 Post
Quote:
Originally Posted by MPaulHolmes View Post
Yes I would very much like to do nissan leaf board. I have a leaf board, and have been figuring out the pinouts, and am almost done. I could get a board working pretty quickly. I just need to do a prototype. I'll do that this month. Well, next month. it's the 30th haha.

That would be great Paul, I will defiantly buy one if/when you produce them. here in the UK the breakers/dismantlers only sell leaf motor complete

If in the future you can hack the charging and the DC/DC convertor you will be onto a real winner
  Reply With Quote
Old 05-01-2018, 12:52 AM   #3174 (permalink)
Master EcoModder
 
Join Date: Sep 2010
Location: Saskatoon, canada
Posts: 1,488

Ford Prefect - '18 Ford F150 XLT XTR

Tess - '22 Tesla Y LR
Thanks: 746
Thanked 565 Times in 447 Posts
Quote:
Originally Posted by thingstodo View Post
I can do that! I could not remember which variable to turn on to check on the encoder. The mechanical rpm seems to be a random number generator when the output of the controller is not on

That will likely happen tonight as well
Results for April 28, 29, 30

I attached the raw logs. I typed a few notes while hyperterm was capturing. see if they make sense. I'll go through them a bit more tomorrow night, but I found out I have training tomorrow night so I only have about an hour.

Didn't get the firmware loaded in.

stream-poscnt 1 is a not a valid command, so I guess I need to load the firmware to get that command.

At the end of the April 30 log I rotated the wheels by hand. First back and forth several times. Lastly in the same direction for several seconds and it looks like I seem to have gotten a consistent direction and speed.

I think the encoder signal is coming through OK.

I still can't figure out why the controller is not putting out current when I move the throttle signal. Weird.

The base config from Andrew's siemens AC motor is in the logs in a couple of places. It should at least TRY to rotate! SIGH!
Attached Files
File Type: zip April_28_29_30.zip (27.5 KB, 25 views)
__________________
In THEORY there is no difference between Theory and Practice
In PRACTICE there IS!

Last edited by thingstodo; 05-01-2018 at 12:53 AM.. Reason: Attach logs ;)
  Reply With Quote
Old 05-01-2018, 07:48 PM   #3175 (permalink)
EcoModding Lurker
 
Join Date: Mar 2018
Location: Sacramento, CA
Posts: 17
Thanks: 9
Thanked 4 Times in 4 Posts
Hmmm I might be having a problem along the same lines as thingstodo

Quote:
Originally Posted by MPaulHolmes View Post
Could you do:

stream-poscnt 1
data-stream-period 100

then slowly turn the motor shaft by hand to see if you get smoothly changing position. That will show that the encoder is working properly.
I tried this but still only saw 0s. I was able to get my hands on a scope, so I hooked it up to the resolver and then encoder outputs, captures of which I've attached. From what I can tell, the encoder output seems to be fine (90deg shift between QEA-QEB, 0-5V, Index pulse every 1/4 turn, etc).



However, this was done without current sensors or throttle connected, so there were faults triggered. Are these faults preventing the "poscnt" variable from being updated/streamed properly? Or can there be another issue at play here?
Attached Thumbnails
Click image for larger version

Name:	Enc_CCW_I_QEA_QEB.png
Views:	41
Size:	24.6 KB
ID:	24065   Click image for larger version

Name:	Enc_CW_I_QEA_QEB.png
Views:	27
Size:	24.5 KB
ID:	24066   Click image for larger version

Name:	Res_1_EX_SIN_COS.png
Views:	29
Size:	76.2 KB
ID:	24067   Click image for larger version

Name:	Res_2_EX_SIN_COS.png
Views:	31
Size:	81.1 KB
ID:	24068   Click image for larger version

Name:	Res_3_EX_SIN_COS.png
Views:	26
Size:	80.9 KB
ID:	24069  

  Reply With Quote
The Following User Says Thank You to wootwootman For This Useful Post:
MPaulHolmes (05-01-2018)
Old 05-01-2018, 11:33 PM   #3176 (permalink)
PaulH
 
MPaulHolmes's Avatar
 
Join Date: Feb 2008
Location: Maricopa, AZ (sort of. Actually outside of town)
Posts: 3,832

Michael's Electric Beetle - '71 Volkswagen Superbeetle 500000
Thanks: 1,362
Thanked 1,202 Times in 765 Posts
If the motor type is set to 1 (induction motor), streaming poscnt won't do any good. if the motor type is like 3 (leaf nissan leaf), then stream-poscnt should work. What motor do you have? I am sick today and can't think straight, and am still trying to help my job transition smoothly to being without me, so I won't be much use for a couple more days.
__________________
kits and boards

Last edited by MPaulHolmes; 05-02-2018 at 12:33 AM..
  Reply With Quote
The Following User Says Thank You to MPaulHolmes For This Useful Post:
wootwootman (05-02-2018)
Old 05-02-2018, 02:43 PM   #3177 (permalink)
EcoModding Lurker
 
Join Date: Mar 2018
Location: Sacramento, CA
Posts: 17
Thanks: 9
Thanked 4 Times in 4 Posts
I verified that it's a 2013 Nissan Leaf motor (EM57), so it should be compatible. As far as the motor-type, I haven't looked at the config settings in a while so I'll take another look at them this evening after work.

Going over the schematic again, I don't think I populated C8,C9, or C10 (the LPF caps before the I/QEA/QEB inputs on the PIC). This would leave the signals basically unfiltered, but since I'm not running the motor or any voltage higher than board level (24VDC), I don't think this is the issue.

I'll be sure to populate them before I start powering the motor, just gotta choose the right values.

512ticks/rev * 10,000rpm (max EM57 rpm) = 5.12Mticks/min ~= 85kticks/sec

Since the encoder signals are square waves (which i believe need fast rise/fall times?), I'll raise the cutoff frequency like....four times? So 340kHz. Since there's already a 1k resistor, that leaves me with ~470pF for a cap value. Someone please correct me if I'm wrong
  Reply With Quote
Old 05-02-2018, 02:58 PM   #3178 (permalink)
PaulH
 
MPaulHolmes's Avatar
 
Join Date: Feb 2008
Location: Maricopa, AZ (sort of. Actually outside of town)
Posts: 3,832

Michael's Electric Beetle - '71 Volkswagen Superbeetle 500000
Thanks: 1,362
Thanked 1,202 Times in 765 Posts
I never use caps there but it wouldnt hurt if they were sufficiently small capacitance. The chip has a noise rejection feature built into the QEI module.
__________________
kits and boards
  Reply With Quote
The Following User Says Thank You to MPaulHolmes For This Useful Post:
wootwootman (05-02-2018)
Old 05-02-2018, 11:07 PM   #3179 (permalink)
EcoModding Lurker
 
Join Date: Mar 2018
Location: Sacramento, CA
Posts: 17
Thanks: 9
Thanked 4 Times in 4 Posts
These are my current settings. It seems the motor-type is correct, however I'm not so sure about the encoder-ticks value. If this is set wrong, what value would I need for the encoder board, 512?

Also, I think I'm getting 4 Index pulses per rotation. I've attached a screenshot taken of just under a full rotation and I can see 3 pulses. Is there any config setting I should change on the controller or encoder board to take this into account?

Edit: I'm an idiot, I wasn't actually streaming poscnt correctly. It seems to be increasing and decreasing from 0-511 along with cw/ccw rotation, but it goes from 0-511 in a quarter turn, with a corresponding index pulse. I may have to alter the resolutiom of the AD2S1210 on the encoder board
Attached Thumbnails
Click image for larger version

Name:	Screenshot_20180502-183113.jpg
Views:	56
Size:	42.5 KB
ID:	24082   Click image for larger version

Name:	Encoder_I_QEA_QEB.png
Views:	44
Size:	47.0 KB
ID:	24083  

Last edited by wootwootman; 05-03-2018 at 03:15 AM..
  Reply With Quote
Old 05-03-2018, 12:38 PM   #3180 (permalink)
Master EcoModder
 
Join Date: Sep 2010
Location: Saskatoon, canada
Posts: 1,488

Ford Prefect - '18 Ford F150 XLT XTR

Tess - '22 Tesla Y LR
Thanks: 746
Thanked 565 Times in 447 Posts
Results for May 2

Quote:
Originally Posted by thingstodo View Post
I still can't figure out why the controller is not putting out current when I move the throttle signal. Weird.
Umm ... .. I seem to have reversed the polarity of the battery pack.

The DC converter is powered by a separate small 12V battery, it is correct and powers up the control board correctly.

The DC+ bus was at 0V and the DC- bus was at 56V. Perhaps that had something to do with WHY the controller would not put out any AC to the motor? I would think that the gate signals to the IGBTs would have been the wrong voltage to allow current flow? And THIS is why the run-pi-test didn't appear to do anything?

Paul - did I break the controller? Is there anything polarity sensitive on the DC bus side of the controller? If the ring capacitor failed, I would expect a short circuit and many obvious bad things ... but I didn't even notice a spark ... it was pre-charged through a 5.6 ohm resistor up to 47 or 48V then I closed a breaker manually (I don't have the contactors set up properly for pre-charge from the controller)

No smoke. No heat. No black marks. Just a nin-com-poop that should not play with controllers after working all day ... without some Adult supervision!

I knew that my attention span was getting worse ... I guess I didn't realize just how bad it could get. Routing the battery cable extensions (I bolted the battery cables to the existing Polaris AC controller lugs) took maybe 3 minutes each - remove the bolts, add the battery cable extensions, route the cables nicely through the rest of the rat's nest of cabling, put the bolt back on. And in that short time I managed to reverse B+ and B- !!!!!

Planning to power up and try running the controller and motor tonight, with the old firmware and motor settings, just to see if it does anything. Unless I'm told that there is no point and I broke the whole thing.

With the wrong settings, I don't expect the motor to run well, but I expect the motor to try turning ...

Posted as a reminder to triple-check what you are doing. Perhaps I will make a check-list of important stuff before I begin, and verify it after I finish, before I power it up. I sort of did this informally before. Now I think the priority has been raised quite a bit!

__________________
In THEORY there is no difference between Theory and Practice
In PRACTICE there IS!
  Reply With Quote
Reply  Post New Thread




Similar Threads
Thread Thread Starter Forum Replies Last Post
Paul & Sabrina's cheap DIY 144v motor controller MPaulHolmes Open ReVolt: open source DC motor controller 7381 08-02-2023 11:55 PM
Paul & Sabrina's Cheap EV Conversion MPaulHolmes Fossil Fuel Free 542 11-12-2016 10:09 PM
Contest! Name Paul & Sabrina's controller MetroMPG Forum News & Feedback 120 10-22-2011 02:59 PM



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