Lift and tilt project

Power wheelchair board for REAL info!

POWERCHAIR MENU! www.wheelchairdriver.com/powerchair-stuff.htm

Re: Lift and tilt project

Postby Irving » 02 Apr 2020, 21:46

Hi Lenny,

Yes, I was aware of that. Currently its all manually driven by dragging with the mouse, so hard to move the lower 2 slots in tandem. In fact you've partly answered some questions I had, as I was aiming to implenent the leadscrew tomorrow. Am I right in thinking the leadscrew is 2 or 3mm pitch? I was planning to include it as accurately as possible in the simulation. What RPM?

Is the tilt motor leadscrew pitch & revs similar? I can see it acts on the sliding arms on the top frame. It appears to sit and act solely in the plane of the top frame.
C5/6 A (complete)
Puma 40, 75Ah LiFePO4 (pic is on tour @ Whistler, BC)
Puma 40 backup, 73Ah MK (for now)
Spectra Plus (weedy 40Ah MK)
User avatar
Irving
 
Posts: 2114
Joined: 04 Dec 2012, 11:51
Location: NW London

Re: Lift and tilt project

Postby LROBBINS » 03 Apr 2020, 02:38

Lift lead screw is 3 mm pitch, 14 mm diam. Lift motor no-load speed is 220 RPM, speed at 4 Nm is 180 RPM.

Tilt lead screw is 2 mm pitch, 12 mm diam. Tilt motor no-load speed is 330 RPM, speed at 3 Nm is 250 RPM.

Linear translation speeds are similar: 11 mm/sec for both no load, 9 mm/sec for one 8.3 mm/sec for the other at rated loads.

The tilt motor is NOT in the plane of the upper frame. It is as close as physically possible without hitting anything to the plane of the front lift/tilt bars and pivots on the same top front dowels as those bars. See Overview1.pdf. See tilt drive.jpg for actual dimensions (POM nut was enlarged because eccentric loading was causing excessive wear).
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby Irving » 06 Apr 2020, 19:24

Hi Lenny

Simulation with lift motor only. Not sure the dimensions are exactly yours, it never gets to the end of the bottom slots before a lock-up situation occurs. Also because the central pivot is off-centre there is a distinct increasing tilt so I'm guessing that the tilt motor plays an active role in keeping the seat level as it rises! How does this compare with reality?

Image
C5/6 A (complete)
Puma 40, 75Ah LiFePO4 (pic is on tour @ Whistler, BC)
Puma 40 backup, 73Ah MK (for now)
Spectra Plus (weedy 40Ah MK)
User avatar
Irving
 
Posts: 2114
Joined: 04 Dec 2012, 11:51
Location: NW London

Re: Lift and tilt project

Postby LROBBINS » 06 Apr 2020, 20:41

It's close. The reason you get the lockup of the lift track is because you allow tilt to go over-center. That's why I have a fifth limit switch (as well as a physical hard stop). The front bars are not allowed to go past 90o.

The change in tilt with change in height (when not level) is intrinsic to the geometry and is countered by sensing change of angle and using PWM control of both motors to keep that to zero (or nearly so). Actually, only movement of the tilt motor is needed except at the stretch where this tilt/lift action is most severe and the tilt motor is at maximum power, when the lift motor is slowed some as well.

So, if already up, tilt is limited by the 5th switch, and if tilted and then moved up (whether it be at maximum tilt or an intermediate tilt), the active control keeps the tilt from increasing.

I should have room on my bench in the next few days to take some non-orthogonal photos for you.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby shirley_hkg » 07 Apr 2020, 04:07

cheers
Attachments
IMG-20200407-WA0003.jpg
IMG-20200407-WA0004.jpg
shirley_hkg
 
Posts: 3946
Joined: 31 Dec 2010, 13:42

Re: Lift and tilt project

Postby LROBBINS » 07 Apr 2020, 09:43

Hi Shirley. Yes, the first coupling I tried was exactly that and as soon as the device went from tilted to untilted the two halves separated as expected. Hence the solid coupling now on there.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby LROBBINS » 09 Apr 2020, 17:00

As per Irving's request, here are some photos not taken head on: three at mid lift & 20o tilt, and one (in next message) mid lift and level
Fr_abv_20_lbl.jpg
Sd_abv_20_lbl.jpg
Fr_20_lbl.jpg
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby LROBBINS » 09 Apr 2020, 17:01

level_lbl.jpg
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby LROBBINS » 18 Nov 2020, 13:09

It's time, or past time, to update y'all on this project. I now, after making numerous stupid mistakes and a lot of re-work, have a working prototype of Rachi's new chair that's been tested with her aboard and with a neighbor who's >twice her weight. First a pic, and them some comments about design choices:
prototype 2020_11_17 c80.jpg
Perhaps the most obvious oddity here is the placement of the drive motors. That was done because, although Rachi is very light - ca. 30kg, she's very short so has to sit way forward to reach the footplate and the only way to get the CG far enough back was to move the motor weight as far back as I could. This is only temporary, however. Right now it has 50 kg of old and very tired Odyssey batteries. When they are replaced with LiFePO4, the 20 kg motors will be rotated forward and down placing the fore-aft CG back to where it is now and moving it much lower as well.

The third motor between the two drive motors is for the lift screw, and the tilt motor is under the seat. The seat back folds by pulling 2 quick release pins, and the electronics are all in a crowded space at the back and can be removed by pulling 4 smaller pins. The batteries then slide out the rear. The back panel also has the Anderson charging connector, circuit breaker and a XT30 fused at 10A for when I need an external 24V (for example, to run a lift or tilt motor if the electronics are out of the chair). There is a fused XT60 inside for connecting her computer.

The drive motors are industrial units chosen after many inquiries to manufacturers here, in the U.S. and in China and Taiwan. No brushless units, even with gearing, had adequate starting torque, the Linix (sp?) distributor had almost no 4-poles to offer, and most had one or another out-of-my-specs problem. The brushless motors Will is using would certainly meet torque and speed specs, but the mfr. says they can't supply them with both a manual-release brake and encoder (or other sensor for sin-cos commutation). Hence, I chose these industrial units with brushed motors and hypoid gearcase. They are efficient, heavy and rather loud, as are the industrial-sized brakes. Compared with her current FWD with overloaded rear casters, however, it steers like a dream, especially noticeable for turn-in-place.

Total weight with the Pb batteries, tilt and lift is 102kg, but I suspect it will get a little heavier because the structure will need reinforcement for more adult-sized users or after I start to see fatigue cracking. Seat to floor pan is minimum 43 cm (17") to maximum 74 cm (29") and ground clearance with tires at 8psi is 10 cm (4").

CIao,
Lenny
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby Burgerman » 18 Nov 2020, 14:40

Thats super light considering its also inc seat lift/tilt etc.

And a lot of work. I note you are using the same? Sized front tyres as I have ordered for the salsa. For reasons of load capacity and footrest space? (8x3.00-4)
User avatar
Burgerman
Site Admin
 
Posts: 65288
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: Lift and tilt project

Postby LROBBINS » 18 Nov 2020, 15:20

No, these are similar but larger - Carlisle 9 x 3.50 - 4. I had used the Kenda version of these for the current chair and they worked out well, so am using the same size on the new chair. They were chosen for the FWD because they fit the geometry of the rear swing-transom suspension, and on this chair the caster mount was designed around the tires. I like the smooth tread because the scrubbing action is anti-shimmy and doesn't try to force the caster onto a particular track. With relatively low pressure 20 to 25 psi they also have a pretty big footprint, though on the FWD with > 30-35% weight on the casters they still dig into soft dry sand. Will probably be the same on the new chair, but maybe less so with ca. 15% weight on the casters.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby stevelawiw » 21 Nov 2020, 10:16

Impressive! what does Rachi think of her new bespoke Chair?
stevelawiw
 
Posts: 664
Joined: 21 Jul 2012, 20:55
Location: Isle of Wight, UK

Re: Lift and tilt project

Postby LROBBINS » 23 Nov 2020, 07:58

Unimpressed.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby LROBBINS » 28 Nov 2020, 17:19

SUSPENSION ADVICE NEEDED

Yesterday Rachi made her first "excursion" in the project chair and we found a problem.

There is very little weight on the casters, but the chair is statically stable even with seat raised and tilted. It becomes unstable, however, when entering a combined up and side slope. For the moment, I've increased caster loading by moving the seat forward 37.5 mm, but haven't yet tried it out so don't know whether this quashes the instability and/or makes for an unpleasant turning response. All I know at this point is that steering is still quite snappy with the CG moved, but without Rachi's weight aboard.

However, I think that there has to be a better solution, but I have little knowledge of suspension design and I'd like some input. Here's a simplified diagram of the way the casters are mounted, and of two alternatives:
caster suspension.JPG


(1) This is the present situation. With no articulation, the down-slope caster is lifted off the ground, and if there's enough increased height of the front end the chair tilts back further and turns hard toward the up-slope side. The caster barrels remain at right angles to the ground.

(2) If there's a center pivot instead of a fixed mounting, the down-slope wheel is not lifted off the ground and the height change is less. Camber changes for both wheels.

(3) If instead of a single center pivot, the casters were mounted on two pivoting half arms, the down-slope wheel again remains on the ground and the height change is even less. The down-slope barrel remains vertical, but there's an even more severe camber change for the up-slope barrel.

In both (2) and (3) the pivoting will need to be snubbed. I figure on using rubber blocks (as in the trailing arm suspension used on Mooney aircraft). With the snubbing, articulation is reduced at least some - (2) becomes a bit closer to (1) and (3) gets closer to (2).

Although (3) involves more pieces than (2), it would actually be easier for me to build given the basic structure of the chair. However, I don't know how the camber changes in either would affect the chair. It will probably increase flutter tendency (with the current setup and fat, smooth tires there's none), but I don't know what other effects this would have. I certainly don't want the negative camber to make the chair behave like the original VW beetle, but free swiveling casters are very different from swing axles on a rear-engine car.

If you have any advice at all to offer, or can point me to some basic links for suspension design relevant to free casters, please, please let me know.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby Burgerman » 28 Nov 2020, 18:06

Most of my chairs have you fig1 setup and zero suspension on the front. One wheel lifts off the deck if I ride it over an edge like a curb, but the soft large low pressure tyres mean all 4 stay on the deck almost all of the time. If one lifts, it doesent change directional stability in any way. The chair goes where the rear drive wheels tell it regardless of what the casters do. They just go where they are pushed. So I am a little confused by your post. Casters dont steer a chair. They go where pushed. There no reason the chair should change direction at all. Only the drive wheels do this directional control.
User avatar
Burgerman
Site Admin
 
Posts: 65288
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: Lift and tilt project

Postby LROBBINS » 28 Nov 2020, 18:21

It's changing direction only because it's over-tilting suddenly with motor compensation having been working to keep the front from going down-hill. Maybe the CG change will be enough. Rachi's FWD has a canted swing axle and rubber damper for the rear casters - it is very effective. If one wheel hits an obstacle it swings both back and up, with the other wheel going forward and down. Between the relative loading change and the damping of the rubber block it absorbs a lot of shock. Of course, on that chair her feet aren't between the casters (where the space is taken by that device) so I can't use it on the new RWD. Just hoping to get a bit of the same effect if possible. The semi-monocoque design (no tubular frame) with transverse support bar for the casters let's me at least think about that, at least reducing the tilt angle change so it doesn't flip into unstable mode.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby foghornleghorn » 28 Nov 2020, 18:24

2 will give you the most balanced ride. You are effectively on a tripod like a milkmaids chair. It takes away the tendency to lift a wheel and wander off downhill.

Both my indoor chair and older outdoor one are built like this. In the indoor one when I am outside I can feel uneven ground like smoothed out waves rather than being tipped around. In the outdoor chair I go places most people wouldn't, and the tripod effect keeps the chair a lot more stable constantly having all 4 wheels on the ground whatever the surface.
User avatar
foghornleghorn
 
Posts: 638
Joined: 20 Mar 2018, 16:29
Location: South East England

Re: Lift and tilt project

Postby Swan T.W. » 28 Nov 2020, 18:55

LROBBINS wrote:SUSPENSION ADVICE NEEDED

Yesterday Rachi made her first "excursion" in the project chair and we found a problem.

There is very little weight on the casters, but the chair is statically stable even with seat raised and tilted. It becomes unstable, however, when entering a combined up and side slope. For the moment, I've increased caster loading by moving the seat forward 37.5 mm, but haven't yet tried it out so don't know whether this quashes the instability and/or makes for an unpleasant turning response. All I know at this point is that steering is still quite snappy with the CG moved, but without Rachi's weight aboard.

However, I think that there has to be a better solution, but I have little knowledge of suspension design and I'd like some input. Here's a simplified diagram of the way the casters are mounted, and of two alternatives:
caster suspension.JPG


(1) This is the present situation. With no articulation, the down-slope caster is lifted off the ground, and if there's enough increased height of the front end the chair tilts back further and turns hard toward the up-slope side. The caster barrels remain at right angles to the ground.

(2) If there's a center pivot instead of a fixed mounting, the down-slope wheel is not lifted off the ground and the height change is less. Camber changes for both wheels.

(3) If instead of a single center pivot, the casters were mounted on two pivoting half arms, the down-slope wheel again remains on the ground and the height change is even less. The down-slope barrel remains vertical, but there's an even more severe camber change for the up-slope barrel.

In both (2) and (3) the pivoting will need to be snubbed. I figure on using rubber blocks (as in the trailing arm suspension used on Mooney aircraft). With the snubbing, articulation is reduced at least some - (2) becomes a bit closer to (1) and (3) gets closer to (2).

Although (3) involves more pieces than (2), it would actually be easier for me to build given the basic structure of the chair. However, I don't know how the camber changes in either would affect the chair. It will probably increase flutter tendency (with the current setup and fat, smooth tires there's none), but I don't know what other effects this would have. I certainly don't want the negative camber to make the chair behave like the original VW beetle, but free swiveling casters are very different from swing axles on a rear-engine car.

If you have any advice at all to offer, or can point me to some basic links for suspension design relevant to free casters, please, please let me know.

orthofab.com/produits/fauteuils-roulants/oasis Something like this?
Swan T.W.
 
Posts: 330
Joined: 20 Jan 2010, 17:03
Location: Ontario,Canada

Re: Lift and tilt project

Postby LROBBINS » 28 Nov 2020, 20:25

SWAN T.W.
Yes, a bit like that, but the shared spring and shock between the two sides will make it behave more like my example (2).

Foghornleghorn,

Could you get some pics of your two chairs?

On my project chair it doesn't take of downhill, but uphill when there's zero weight on both casters after motor compensation has increased power on the down-hill side and it comes to an up hill and tilts back. One case is going along a narrow sidewalk and crossing the cut for a driveway. The slope of the driveway toward the street is steep so there's lots of motor compensation and perhaps some unconscious stick correction, and when you come to the end the chair goes nose up and that compensation (and stick correction?) turns the nose uphill.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby Burgerman » 28 Nov 2020, 20:36

Doesent do that without the roboteq.

I have long thought that motor load compensation on most mobility controllers works much faster than the normal settings we program for acceleration and deceleration. Or turn accelerations. And in my case I have turn acceleration and deceleration almost real time. If you did the same, then the compensation would be able to rise and fall way faster.

Whats happening I think in your case is that compensation builds when needed, to hold the chair straight and is still there (slowly decaying) when you dont need it. And its throwing you off course. If I watch the current rise and fall due to compensation on say r-net in real time, its way faster than the stock slow typical 35% (around 2 seconds) that you can move the current by moving the stick. I think its got nothing to do with casters. Or suspension.

It is not a problem on my bot, or my BM3, because I have way faster turn acc/decelerations than you do. Maybe 1/10th of a second from straight to max turn rate and back to straight ahead. That allows the motor compensation to increase or decay fast as needed.
User avatar
Burgerman
Site Admin
 
Posts: 65288
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: Lift and tilt project

Postby foghornleghorn » 28 Nov 2020, 22:24

Indoor, RWD Invacare Fox:
https://invacaredocs.com/assets/documen ... 8b45da.pdf
Pendulum - page 11

Outdoor, FWD Pride Quantum 1400
https://www.southwestmedical.com/replac ... -flat-free
Articulating Beam Assembly - This is a bit over complicated but the casters can flex backwards when you hit a bump and also sideways a bit so they are upright when the beam is at an angle.
User avatar
foghornleghorn
 
Posts: 638
Joined: 20 Mar 2018, 16:29
Location: South East England

Re: Lift and tilt project

Postby LROBBINS » 29 Nov 2020, 13:02

foghornleghorn:
Thanks for the links for your chairs. The Invacare "pendulum" seems like a pure type-2 arrangement, while the Quickie adds some shock damping and reduces the camber change.

John (Burgerman):
Your observations about motor compensation are more than a little interesting. In the Roboteq compensation is calculated and applied to motor command essentially instantaneously, but motor command's effect on motor power is directly tied to ACCEL & DECEL. I think I can get around this by doing roughly the same thing as was done to increase turn acceleration while keeping fore-aft acceleration as set when both turn rate and fore-aft speed are changing. Haven't looked at code yet, but it would be something like this:
(1) Keep track of amount of motor compensation on last cycle through the loop and on current cycle.
(2) If there's a change in compensation > CompChangeTrigger, multiply ACCEL & DECEL by CompBoost (an integer, equivalent for changing comp to TurnBoost for changing turn)
So there are two values to set: CompChangeTrigger (set in the script) and a user-chosen setting for CompBoost.

I will have to empirically see what sort of compensation changes are produced by different loadings to set CompChangeTrigger, which will also have to vary with motor impedance (= MotorResistance) - the lower MotorResistance the smaller the compensation for a given mechanical loading, so we need something like CompChangeTrigger = (MotorResistance/150)*BaseCompTrigger; If BaseCompTrigger = 60, the trigger for a 50 milliohm motor would be 20, for a 100 milliohm motor would be 40 etc. In other words, I have to figure out what's a reasonable BaseCompTrigger by experiment for one motor, but it would work for other motors as well.

CompBoost will be user programmed to an integer value: 1=no accel boost for changing comp, 2=accel and decel doubled while comp is changing, 3= tripled etc.

Lastly: here's a slightly updated version of yesterdays sketches showing the amount the nose is raised in the 3 cases in terms of the obstacle height. In (1: the current setup), nose height goes up by a distance equal to obstacle height, in (2) it goes up by half as much, and in pure, un-damped (3) it doesn't go up at all. So, flipping tendency is 1-highest, 2-in the middle, 3-lowest.
caster suspension.JPG
Camber change is the reverse (1) none, (2) medium, (3) strongest and negative camber will cause the caster to swivel - pointing the nose toward the uphill side, making it even more important to quickly get rid of excess motor compensation.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby Burgerman » 29 Nov 2020, 13:53

Why do casters, or raising the nose, have ANY affect at all on directional stability?

They dont. Thats purely down to the slow turn acceleration, and turn deceleration, (and the motor compansation tied to this speed of change) that you are using.

My turn accelerations/decelerations are really fast. Practically instant. 0.1 sec approx. Because I cannot drive like I stole it and still have any kind of accuraccy otherwise. So the compensation reacts almost instantly too.

I set forward acc and dec slow. Maybe 5 seconds to reach 16mph. With this I can feel the comensation ramp up, and after the threshhold or whatever is cleared, the extra speed (from the increased motor compensation with load now gone) take a while to drop. Turns would be the same if you set these acc/dec too slow.
User avatar
Burgerman
Site Admin
 
Posts: 65288
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: Lift and tilt project

Postby foghornleghorn » 29 Nov 2020, 14:32

This isn't about crossing thresholds or doing wheelies in your kitchen :roll:
User avatar
foghornleghorn
 
Posts: 638
Joined: 20 Mar 2018, 16:29
Location: South East England

Re: Lift and tilt project

Postby LROBBINS » 29 Nov 2020, 17:06

John,

My Roboteq accel and decel are set at 2100 and 3100 which corresponds to about 1/2 second from 0 to full motor power and 1/3 second from full motor power to 0. Turn accel/decel are 3 times higher so quite snappy and precise. Physical accelerations will be less because of inertia, but the new chair is light weight, the motors are pretty powerful and Rachi is a feather weight.

So, I'm now thinking that there are three things that contribute to turning when doing an unplanned wheelie with changing side slope. One is the fact that motor compensation differences change motor power according to the base accel and decel values. Hence, as you've suggested it may not disappear quickly enough when the side slope disappears - I've started coding a fix for that. The second is that I probably, even unconsciously, hold a bit of up-hill stick going on a cross slope and that certainly doesn't go away if the chair suddenly tilts back. The third is that I'm driving from an attendant joystick and although I keep my hand as solidly locked to the box as I can, if the chair suddenly tilts back the stick surely gets moved forward and it's probably not centered either.

In the meantime, moving the seat forward 37.5 mm didn't seem to affect turn snappiness or precision, which is much better on her FWD with overloaded rear casters, especially for turn in place. Moreover Rachi's aide has just told me, after a couple km on our crappy sidewalks, that the tippyness is pretty much gone. I've not measured nor re-calculated weight and balance, but it's probably of the order of a 5% increase in weight on the casters. Seems that I'd rather exaggerated on getting the CG far back.

foghornleghorn:
no, not thresholds nor anything similar, nor even the 4 cm step at the local tabacco shop. The critical case is something like a steep driveway cut so there's a strong side slope. No problem going down into that, nor going along it on the tilted level. But there's fairly steep uphill and quick disappearance of the side slope at the other end and that's when the chair does its un-planned, un-intended, and un-expected wheelie.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby Burgerman » 29 Nov 2020, 17:16

The third is that I'm driving from an attendant joystick and although I keep my hand as solidly locked to the box as I can, if the chair suddenly tilts back the stick surely gets moved forward and it's probably not centered either.

So you are getting the equivelent of added motor compensation and more power added in a mechanical way... Just when it should drop.

That is why I keep on trying to get people to have a good arm, position, and technique when driving. I dont know how to do that with an attendant control.
User avatar
Burgerman
Site Admin
 
Posts: 65288
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: Lift and tilt project

Postby LROBBINS » 29 Nov 2020, 20:50

Yep. It's even more important for me than for you to avoid a flip over situation because my hand isn't "glued" to the chair.
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby LROBBINS » 02 Dec 2020, 21:23

John, as usual you hit the nail on the head! Boosting accel and decel whenever MotorCompensation is changing makes a major difference in feel, on the FWD with overloaded casters it got rid of the hesitation in turn-in-place, on the new chair it just "feels" better. It also turned out to be very easy to do, much simpler than I outlined above.

Here's all that was needed:

In the MixAccel: subroutine there are 2 tiny changes - one line added and 3 commented out:
Code: Select all
  IF TurnBoost > 1 THEN
    GoSub TurnMix
    GoSub CompMix
  END IF
'  IF LoadBoost > 0 THEN
'    GoSub LoadBoost
'  END IF

It turned out that the same boost that works for creating turn priority works well for MotorCompensation so no added user parameter is needed - just the added line GoSub CompMix. With rapid accel/decel when compensation changes there's also no need for LoadBoost which was my complex and only partially successful attempt to deal with slow initial acceleration, so I've commented out the call to the LoadBoost subroutine.

Then, there's a new CompMix subroutine:
Code: Select all
CompMix:
  DIM TotalComp AS Integer
  DIM CompChange AS Integer
  DIM LastTotalComp AS Integer
  TotalComp = abs(M1Comp)+Abs(M2Comp)
  CompChange = abs(TotalComp-LastTotalComp)
  IF CompChange > 1 THEN
    M1Accel = M1Accel*TurnBoost
    M2Accel = M2Accel*TurnBoost
    M1Decel = M1Decel*TurnBoost
    M2Decel = M2Decel*TurnBoost
  END IF
  IF (abs(GetValue (_MOTCMD, 1)-GetValue(_MOTPWR,1))<10) AND (abs(GetValue (_MOTCMD, 2)-GetValue(_MOTPWR,2))<10) THEN
    LastTotalComp = TotalComp
  END IF
RETURN 'END of CompMix

The key variable here is the change in absolute value of total motor compensation = CompChange. That turns out to have so little noise, about 1 unit (out of 1000) when the chair is neither accelerating nor decelerating, that there was no need to set a trigger value, nor to adjust things for different motors. Whenever CompChange is >1 accel and decel are just multiplied by the same TurnBoost setting used for turning.

LastTotalComp is re-set when compensation is not changing, and that's when MotorCommand = MotorPower. As soon as the stick is moved from whatever position it's in, or as soon as a mechanical load chnage "tickles" MotorCompensation, LastTotalComp stays where it was, CompChange goes over 2 on the very next loop cycle and accel and decel go to TurnMix times their normal values.

I will incorporate this into the next release version of the CANbus system, but those who are still using the analog script will have to make the changes themselves - I just have too much to do and get too confused trying to maintain both scripts, uploads, backups and all the rest. If anyone yet has a working copy of the CANbus system, he/she can also go ahead and change these two subroutines in the script. (I'll eventually clean things up by removing the LoadBoost subroutine and the programming of its parameters from Master, but functionally just commenting out the calling lines in AccelMix does the job.)
LROBBINS
 
Posts: 5554
Joined: 27 Aug 2010, 09:36
Location: Siena, Italy

Re: Lift and tilt project

Postby Burgerman » 02 Dec 2020, 21:55

What is the latest script that you have for the non can bus capable like me!

I told you I just "get" physics... :thumbup:

This isn't about crossing thresholds or doing wheelies in your kitchen

It is. Its all about the control system and "feel". Feel, and speed and linearity of control, and programming are EVERYTHING when you are driving a chair.

If its right for me, and as linear and as accurate and responsive in every speed during back stick braking as I turn, or whole steering ttrough a doorway while acelerating on 2 wheel, at every turn, manoever, inc motor compensation response speed which needed to be faster in turns, then its better for everyone. The difference is that I can detect and "feel" tiny changes and can figure out what is wrong.But dont do code. So lenny can fix it! :lol:

As it turns out my initial thoughts were correct. Its not a suspension issue. Its a speed of motor compensation rise and decay time when turning. Or accelerating/decelerating.
User avatar
Burgerman
Site Admin
 
Posts: 65288
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: Lift and tilt project

Postby Burgerman » 03 Dec 2020, 12:03

I will simplyfy what was happening in lennys case.

In a powerchair the MOTOR LOAD COMPENSATION is 90% of everything.
When a rear drive powerchair for e.g is driving along the footpath, it may be at a transverse angle. So the thing drains water into the road gutter. Or may just badly constructed. This makes a rear drive powerchair try to head down towards the curb as the CG is ahead of the drive wheels. And so the casters "push" towards the low side. The motor compensation "feels" this uneven load, and applyies anything up to say 80% more power to the lower motor and even some REVERSE current if required to the opposite motor to keep you headed straight. You dont know this extreme difference in motor output between the left and right wheels, as you may ony be applying just 5mm of stick correction. This is happening behind the scenes. And is essential for control.

Now suddenly remove this uneven motor load. Level the footpath. Or make the ground go the opposite slope. And now we rapidly need to reverse this 80% motor power difference from left to right, to the opposite - right to left. In order to continue in a straight line.

Now if the load compensation cannot work quickly to do this, and is restricted to the same speed as your turn acceleration settings, you are buggered! The chair will take say .3 to .5 of a second or longer with the power applied in the wrong direction, before the motor Amps/voltages can change to the new settings required to drive straight. Meanwhile the chair now heads in the wrong direction as dictated by the old compensation it was applying previously for a short time. This is what lenny was seeing.

As you drive your chair, MOST of the power applied is determined by the motor load compensation. Not by the command that you give the chair. It is literally 90% of the chairs control or response in turn, in forward and reverse acceleration or deceleration as well as load correction and turn response. So it must be working correctly. So we just made a huge improvement to the roboteq algorythm. That was causing this odd behaviour. What the suspension or casters did was incidental, and not the cause.
User avatar
Burgerman
Site Admin
 
Posts: 65288
Joined: 27 May 2008, 21:24
Location: United Kingdom

PreviousNext

Return to Everything Powerchair

Who is online

Users browsing this forum: Burgerman, ex-Gooserider and 36 guests

 

  eXTReMe Tracker