Cheap FOCer 2 (Open-source, Low-cost, VESC 6 based ESC) (v0.9 Release. Beta testing ongoing)

Same firmware version as in both 5.02 or 5.03. I think they can use the same configuration (XML) files that are used for motor and app parameters.

But I’m confused by this statement above…

The source code for all VESC’s and it’s derivatives is the same. When you want the compile this source code for specific hardware you just uncomment it here. This gives you a binary that is only usable for you’re specific hardware. This is what I mean by the firmware (binary) for the v0.9 and v1 not being the same.

OK - that makes more sense to me now. But… I don’t see different lines for v0.9 and v1.0 in that file. Also, when I do a binary diff on the .bin files in the v0.9 tree and the v1.0 tree, they come out as identical (for firmware 5.01)

2 Likes

The differences are very small. The important difference is this:

#define CURRENT_AMP_GAIN 10 is 20
https://github.com/vedderb/bldc/blob/master/hwconf/hw_Cheap_FOCer_2.h (v1.0)
https://github.com/shamansystems/Cheap-FOCer-2/blob/master/firmware/Source%20Code/bldc-master%205.01/bldc-master/hwconf/hw_Cheap_FOCer_2.h (v0.9)

This is because of the different resistor values in the guide I linked to above.
The v1.0 binary isn’t included on the github of the cheap focer 2. It’s here

3 Likes

Thanks! I found firmware in the v1.0 distribution, but it must not have actually been updated. This is perfect.

Can you tell me which version of firmware that is? You had mentioned 5.02 and 5.03 above.

The last link I posted was to the main branch of the VESC project, so that would be v5.02. This is the link to the development branch for version v5.03. It’s not stable yet though.

1 Like

I took the mountain board back out today. I was curious to see if this problem would happen again. It did, but more so. I tried disconnecting power for about 20 seconds, and that didn’t help. So I let it sit for a bit more than 10 minutes (with it powered, but not touching the throttle). That didn’t help. So I unplugged it and gave it another 10 minutes. That got me back on the road for about 3 more minutes before it failed again. After this next failure nothing will make it go again.

A couple of weird things… I’m using 2 v0.9 CFOC2’s connected by canbus. The master is the one that fails and gives faults. The slave keeps working - kind of. I can spin the motor, but it won’t produce enough torque even to let me crawl home (I have run the board on a single motor before and it normally has plenty of torque for that - but not when this problem occurs).
So the slave wheel will turn, but not with enough torque to do anything. It also behaves weird. If I give it throttle, it will spin, but it won’t stop or brake immediately if I release the throttle or apply brake. There’s what feels like a 1 second delay. I was wondering if that’s the fail-safe timeout kicking in. I also wondered whether the slave one behaving badly was due to having traction control enabled (though I can’t recall whether I actually do). But that doesn’t seem right, because it presumably wouldn’t spin one wheel while the other isn’t turning. Dunno.

In any event here’s the current status…

  • The master controller won’t drive the motor.
  • The slave will spin the motor, but not with any torque.
  • If I power the master on and check for faults, I find none.
  • But if I power it on, hit the throttle, and then check for faults, I reliably get an over-current fault - even though the motor never even spun. I wondered if it’s possible the motor itself, or problems with the power wire connections or Hall wire connections could cause the over-current faults. I could try swapping motors and controllers, to see if that makes a difference.

But whatever it is, it’s gotten much worse, so it kind of seems like a component that’s either failing or coming unsoldered. Anyone like this theory? Any idea which component would be the most likely culprit?

Here’s one of the fault dumps…

after reset and hit throttle - bottom

Two bizarre things here…

  • It shows 156 A, but it never even spun the motor. The motor doesn’t feel as if it has a short, but I suppose it could.
  • The report indicates that this is “motor: 1”. But this is my master vesc, and I’ve specified that it’s VESC 0. Perhaps that’s different than the motor number(?)

Any insights would be greatly appreciated - even if it’s just to suggest which components I should likely replace.

Thanks!

1 Like

By any chance do you have traction control enabled? That would limit the power to the one working motor.

1 Like

Sorry for the delayed response. That’s a good theory. And to be honest, that’s what I assumed, but when I look at my setup, traction control is not enabled.

Update…
I removed the offending CFOC2 and noticed it had a fair bit of grime on it from road and trails. Because of the bizarre nature of the problem (complaining of pulling 175A when I’m tooling along a level road), I wondered if maybe some of that grime might be partially shorting one of the sensor pins. So I gave it a good cleaning with a toothbrush and alcohol.

It’s too early to say, but so far (about 10 minutes of riding) it’s acting OK.

3 Likes

Got my 2 CFOC working. Updated 0.9 board to 1.0 following this:

and it works just fine.
Regarding binary, used the one mentioned here:

Vesc tool 5.2 shows no outdated firmware and everything works. Currently running @ 12s 50A, but will be pushing it to 70 this weekend.

@shaman github firmware folder needs to be updated. It took me a while to dig through forums and find binaries that should be used (in folder there are 3 and they are outdated)

Other than that, really fantastic project, love the result. Will give feedback after more field testing. :slight_smile:

3 Likes

Which one are you referring to - the v0.9 link or the “Here” link?

Thanks.

I’m reffering to ‘‘here’’ link.

Another updated. Tested it more with @rusins pushing the absolute limits of current setting and so far so good. Cooling plate and motors get barely warm and everything works well in FOC. Will be making it sensored at some point (turns out finding small 6pin waterproof plug is not easy)

2 Likes

Thanks! I ran unsensored briefly. Never again. I wonder if you can just use regular 0.1" pin headers and bury the connector in a small grease-filled enclosure. It should be pretty rare that you have to disconnect it - right?

Has anyone designed a 3D-printed enclosure or dust cover for the CFOC2 v1.0?

Further update…
I took the board around the neighborhood yesterday for about 20 mins and it worked perfectly.

I took it on the trails today and the controller died again and currently remains dead. Still don’t know why it’s getting outrageous over-current faults. :frowning:

You can easly make it up in fusion360 from files provided in github and cut it out of 1mm plastic that you can find on bookkeeping covers, wanted to get on road quicker before winter starts so I opted for fishpaper and conformal coating on top instead. Will make one eventually if youre interested.

Hard to say straight away whats the issue, but things I would check.
1.Basics, recheck vesc settings and compare it to batt ones.
1.1Did you did 10k resistor upgrade on the board to update it to 1.0
1.2Did you soldered 220n capacitor on the on/off switch?
2.Check wiering on CFOC, for any small loose wires that come from phasewires on the board (before putting it in case i managed to catch some stray ones.)
3.Before running it, did you you went over DRV solder joints on bottom and top?
4.When mounting it on heatsink was the board perfectly straight? In my instance I had to add 1mm washers on all of the bolts because my thermally conductive tape was a bit thicker than in tutorial.

If you can, post some pictures of the board, maybe there is some obviously bad solder joint

1 Like

You can easly make it up in fusion360 from files provided in github…

Yup. I just figured there was probably already one out there.

Hard to say straight away whats the issue, but things I would check.
1.Basics, recheck vesc settings and compare it to batt ones.

This thing has been working perfectly for a long time, so unlikely the settings.

1.1Did you did 10k resistor upgrade on the board to update it to 1.0

Nope. I’m not aware of it, but I’d love to fix this thing if possible. I just now configured a couple of HW1.0 CFOC2’s for the board, but it would be great to have the HW0.9’s as backups.

1.2Did you soldered 220n capacitor on the on/off switch?

Probably not. Was that an update?

3.Before running it, did you you went over DRV solder joints on bottom and top?

Yeah - I think they’re pretty solid.

4.When mounting it on heatsink was the board perfectly straight?

Yup.

If you can, post some pictures of the board, maybe there is some obviously bad solder joint

I’ve gone over it pretty closely and haven’t seen anything, but maybe I can get a good pic and post it. Thanks.

1 Like