Imaginous / Cowboy_Untamed

An Android app to lift the speed limit of your Cowboy Bike.
187 stars 58 forks source link

No support with speed limit mode #10

Closed belgi4n closed 2 years ago

belgi4n commented 2 years ago

I have a weird problem with my V1+

Initially I was only using the presets function with Untamed to start my bike and it was working perfectly

But now, when I try to start the bike with either the official cowboy app or with the “torque and speed limit mode” in Untamed, I have no support at all from the motor. Prior to that problem, I’ve never use the flash option, only the presets. So it’s still the original settings that are flashed in the bike.

When I try to start the bike with the “no speed limit” option from Untamed, I have support from the motor and it’s working normally.

I tried to reset the PCB with the Untamed app and I tried to flash the “torque and speed limit mode” but it didn’t change anything. I’m using the latest version of the Untamed app. Any idea how I could solve this problem ?

Imaginous commented 2 years ago

When you unlock the bike with the original app is assistance enabled?

This is my first idea. I don't see another logical explanation at this point.

sketch-1640287235641

belgi4n commented 2 years ago

Yes it is

Imaginous commented 2 years ago

Can you check the set speed in the Expert Functions menu?

Screenshot_20211223-212904

Select the 2 top selectiond as shown in the screenshot and press read. Please let me know the shown speed.

What speed is selected in the original app? Regular or offroad mode? Does it help switching between them?

belgi4n commented 2 years ago

In the original app, the bike is in off road mode.

In the expert menu, the speed is the same as your screenshot.

I tried to switch between off road and 25km/h in the official app but it didn't change anything

Imaginous commented 2 years ago

Please check the values in the screenshots:

Screenshot_20211223-215624

Screenshot_20211223-215545

belgi4n commented 2 years ago

I have an error "read register operation failed" for those. So a hardware problem with the motor controller ?

belgi4n commented 2 years ago

Screenshot_2021-12-23-22-08-03-618_nl imaginous freecowboy Screenshot_2021-12-23-22-07-30-308_nl imaginous freecowboy

Never mind, I tried again and now I can read the values

Imaginous commented 2 years ago

Just a recap. When you disable the speed limit and set a field weakening value (you might try 0) the bike works.

When you enable the speed limit it doesn't work. Right?

Does the speedometer work in the original app? It seems to me the speed limit is set incorrectly. My app doesn't change it. Did you use Bronco?

There are 2 scenarios in my mind.

  1. The maximum speed is 0 in the motor controller. The register you read was the PCB speed, I have to look up the register in the motor controller. So when enabling the speed limit you're directly at the maximum so the support will be cut out.
  2. The speed sensor registers a insane high speed so it cuts out.

The only thing I change is if the motor controller must obey a set speed limit. And field weakening, but this can't turn off support.

belgi4n commented 2 years ago

Correct, with speed limit it doesn't work, without speed limit with any field weakening value it works.

The speedometer works normally in both cases in the original app.

I installed Bronco but never used it. I've just tried today after the problem came up to see if the motor would work with it, but it doesn't.

belgi4n commented 2 years ago

Here are some values related to the speed limit from the motor controller : Screenshot_2021-12-23-22-58-15-325_nl imaginous freecowboy Screenshot_2021-12-23-22-58-46-818_nl imaginous freecowboy Screenshot_2021-12-23-22-58-55-010_nl imaginous freecowboy Screenshot_2021-12-23-22-59-11-499_nl imaginous freecowboy

Imaginous commented 2 years ago

I will have a look tomorrow at the motor registers to see which register is used in the motor controller for the speed limit. Normally this value is overwritten by the original app.

Did anything happen before you noticed this? The communications between the motor, motor controller and main PCB seems okay. Your torque sensor base readingvis normal. The maximum torque sensor value is normal.

It's strange.

Imaginous commented 2 years ago

I have to check with my bike tomorrow to see what the defaults are.

Your speed limit seems correct.

leinardi commented 2 years ago

I read on reddit that a new firmware was related, could this issue be related?

Imaginous commented 2 years ago

@leinardi as far as I know there is no new firmware available for C1 bikes, it's V4.8.17.

belgi4n commented 2 years ago

I will have a look tomorrow at the motor registers to see which register is used in the motor controller for the speed limit. Normally this value is overwritten by the original app.

Did anything happen before you noticed this? The communications between the motor, motor controller and main PCB seems okay. Your torque sensor base readingvis normal. The maximum torque sensor value is normal.

It's strange.

I started using untamed 1 month ago and I rarely used the official app to start the bike since then. So it's hard to say when it appeared for the first time. Nothing unusual happened in the past month and I did nothing special, just started the bike with the preset function, nothing else. So indeed, really strange... I'm also on firmware 4.8.17

Imaginous commented 2 years ago

Here are the values as found on my C1+:

Screenshot_20211224-070150 Screenshot_20211224-065746 Screenshot_20211224-065758 Screenshot_20211224-065815 Screenshot_20211224-065828 Screenshot_20211224-065841 Screenshot_20211224-065902 Screenshot_20211224-065926 Screenshot_20211224-065936 Screenshot_20211224-065952 Screenshot_20211224-070023 Screenshot_20211224-070040 Screenshot_20211224-070050 Screenshot_20211224-070102 Screenshot_20211224-070127 Screenshot_20211224-070135

belgi4n commented 2 years ago

I get the same value as you when the bike is in no speed limit mode. When my bike is in the speed limit mode (and not working), the following values are different: Speed limiter output is 0.01 pu vs 1 pu for you Speed mode is 2 vs 1 for you So I guess your bike was in the no speed limit mode ?

Imaginous commented 2 years ago

My was in no speed limit mode indeed. At work now, so can't check.

Speed mode 2 = with speed limit, 1 = without speed limit. So the only interesting value is the speed limiter output value. But according to the ASI documentation this should not influence speed mode 1. Which is default on the Cowboy.

You can also try to manually read address 236 of the motor controller. I wonder which value you get. probably 0. I'm also inerested in the value of address 241 and address 329.

You can enter the addresses manually and press read.

It's mind boggling why this happens. Since the bike seems to work fine without the speed limit. I know non Untamed users had the same problem. As far as I know the motor controller was replaced. But to me as developer it sounds like a misconfigured value.

The only question is which value and how can it be "corrupted". It must be a value related to the speed limit, since disabling this makes the bike normally.

I guess you're from Belguim, otherwise I would say just visit me and we can have a look together ;)

belgi4n commented 2 years ago

Address 236: 0 Address 241: 1474 Address 329: 4096

Do you think it might be an hardware issue with the motor controller that only has consequences if there is a speed limit (knowing that the speedometer is working as expected) ? Or you don't have any rationnal explanation for that theory with your knowledge of the bike ?

Imaginous commented 2 years ago

Since the speed is registered via the motor controller it seems the motor controller has knowledge of the speed.

You can try to adjust a preset with the power setting at 100 for up to, let's say, 15km/h and 0 for above. As soon as you hit the speed you should have no support. This way we can determine if de speed is registered correctly by the controller.

belgi4n commented 2 years ago

The motor cuts off at the speed where I set the power setting to 0, as it should. So the speed is correctly registered by the controller.

Imaginous commented 2 years ago

It feels like it must be something extremely simple.

What value has address 339, 213, 214, 258, 259? The last 2 are error registers.

I will verify your values when I get home. Now just summing up registers which might have influence.

belgi4n commented 2 years ago

339: 4096 213:15130 214: 3277 258: 0 259: 15

Imaginous commented 2 years ago

My values with speed limit (yours - mine): 236: 0 - 0 241: 1474 - 1474 329: 4096 - 4096 339: 4096 - 4096 213:15130 - 15130 214: 3277 - 3277 258: 0 - 0 259: 15 - 14

Only the value for the temperature differs, but that's not a problem. Just a check value.

I really don't get it.

Imaginous commented 2 years ago

First of all, a Merry Christmas!

I re-enabled the speed limit on my bike and drove with stock settings. Mine still functions fine.

In your case I technically don't understand what might go wrong. Since all logical tests seem to be okay.

Just some last tests:

What happens?

belgi4n commented 2 years ago

Merry Christmas to you too ! And thank you for your help so far !

I've already tried this and I've just tried it again and still the same problem...

Imaginous commented 2 years ago

@belgi4n did this problem got solved on your part?

I have no other users with the same problem and don't see any logical explanation for this.

belgi4n commented 2 years ago

No still the same problem... However, when I stopped using my bike over the Christmas period for some days and when I rode it again, it was working normally with the speed limit mode for 1 trip but on my way back, the assistance stopped working in the middle of the trip when I started at a red light (but still working with the no speed limit mode). Since then, it's still not working with speed limit mode... So maybe it's some weird hardware problem. I'll close the issue, I'll see if Cowboy can help me. But thank you for your help anyway and thank you for your great app !