c172p-team / c172p

A high detailed version of the Cessna 172P aircraft for FlightGear
GNU General Public License v2.0
82 stars 43 forks source link

160 HP engine is under-powered for pontoons and amphibious #273

Closed dany93 closed 9 years ago

dany93 commented 9 years ago

As several people noticed, the 160 hp-powered c172p is under-powered, which makes it "lazy" at full load. Floats and amphibious worsen everything (added drag). I tried to fiddle the propeller pitch angle, at no avail. The original one is not far from the best.

I have a test version with a 180 hp engine. On my c172-180hp branch https://github.com/dany93/c172p-detailed/tree/c172-180hp

Easy for the engine.

The propeller is much more questionable. It is the result of compromise between climbing rate, short field takeoff, and cruise or max velocity. For the propeller, I use the NACA 640 data http://naca.central.cranfield.ac.uk/reports/1938/naca-report-640.pdf. They worked rather well for DR400, DC3, Cap10B. But everything is never certain... And I refuse to cheat the values. I check their consistency, I (re-)calculate the efficiency when I extract them from the curves.

Positive:

No so positive:

My reasoning is that, even if this propeller is still questionable, the result is better than with the 160 hp engine. More pleasant.

onox commented 9 years ago

Ah, in that case you would have to do git pull --rebase master I think.

dany93 commented 9 years ago

I don't mind, I don't understand the effect. What is the best I should do? From which branch?

onox commented 9 years ago

Ok, lets first update your "master" branch. Can you do that?

onox commented 9 years ago

The latest commit should then become Merge pull request #318 from Juanvvc/bug-311.

dany93 commented 9 years ago

As usually (from my master branch) git pull upstream master or git pull --rebase master?

onox commented 9 years ago

No, git pull upstream master. (Do this in your master branch, not your c172-eng160-180hp branch)

dany93 commented 9 years ago

OK, done. My branch: master, last commit Merge pull request #318 from Juanvvc/bug-311

onox commented 9 years ago

Yes, ok, now switch back to your c172-eng160-180hp branch using git checkout c172-eng160-180hp.

onox commented 9 years ago

And then do git pull --rebase master.

dany93 commented 9 years ago

git pull --rebase master fatal: 'master' does not appear to be a git repository fatal: Could not read from remote repository.

Please make sure you have the correct access rights and the repository exists.```

onox commented 9 years ago

Sorry, git rebase master.

dany93 commented 9 years ago

Seems OK: "Current master branch is up to date" (in French, my english translation)

onox commented 9 years ago

What are the two top commits? Use git log --oneline.

dany93 commented 9 years ago
git log --oneline
8ad2589 Merge pull request #318 from Juanvvc/bug-311
c8621bc Transmit rollspeed-ms of (amphibious) gear over multiplayer

What will it do, and what should I do (or not do) later to update?

onox commented 9 years ago

Is this in your c172-eng160-180hp branch?

dany93 commented 9 years ago

No, it was in my master branch.

In my c172-eng160-180hp branch:


Sur la branche c172-eng160-180hp
Votre branche est à jour avec 'origin/c172-eng160-180hp'.

rien à valider, la copie de travail est propre
dany@dellinux ~/FG/github/c172p $ git log --oneline
2f9f036 engine and propeller for 160 or 180 hp, test version
9dc86bc Merge pull request #292 from Juanvvc/bug-fix-284-and-288```
onox commented 9 years ago
  1. Switch back to your c172-eng160-180hp branch using git checkout c172-eng160-180hp
  2. Do: git rebase master
dany93 commented 9 years ago

git status Sur la branche c172-eng160-180hp Votre branche est à jour (up to date) avec 'origin/c172-eng160-180hp'.

rien à valider, la copie de travail est propre (clean) dany@dellinux ~/FG/github/c172p $ git rebase master Premièrement, rembobinons head pour rejouer votre travail par-dessus... (firstly, let's rewind head to play your work again above it...) Application : engine and propeller for 160 or 180 hp, test version

onox commented 9 years ago

Ok, show me top two commits from git log --oneline again.

onox commented 9 years ago

@dany93 Are you having troubles? :worried:

dany93 commented 9 years ago


a9d4b9f engine and propeller for 160 or 180 hp, test version
8ad2589 Merge pull request #318 from Juanvvc/bug-311```
onox commented 9 years ago

Ok. Do you see you have brought in the latest stuff from master and then put your own stuff (1 commit) on top of it?

dany93 commented 9 years ago

Yes. But the effect? Hopefully, there was no conflict. What I should do or not do later?

onox commented 9 years ago

That is the effect. You put your own stuff on top of the stuff from master. Now you have the latest and greatest from master and still you have your extra 180hp engine :smile:

Ok, now try to push, it should fail. When it fails, try to push again but with --force.

dany93 commented 9 years ago

Seems OK To https://github.com/dany93/c172p-detailed.git

onox commented 9 years ago

Yes, compare:

  1. https://github.com/dany93/c172p-detailed/commits/c172-eng160-180hp
  2. https://github.com/Juanvvc/c172p-detailed/commits/master

Your branch is just 1 extra commit on top of master now.

dany93 commented 9 years ago

I see and I understand that I have a repository with updated juanvvc and my last commit for 160-180hp above it, like if my commit had been added to juanvvc.

onox commented 9 years ago

Yes.

onox commented 9 years ago

Btw, is there a particular reason that /controls/engines/engine/master-bat is located within /controls/engines/ instead of /controls/switches/?

dany93 commented 9 years ago

Now, for my updates from juanvvc master, as usual? And if I add a commit in c172-eng160-180hp, git push and that's all?

onox commented 9 years ago

If you add another commit to your c172-eng160-180hp branch, you can just do a regular git push.

dany93 commented 9 years ago

And I understand that the current content from juanvvc which is in my c172-eng160-180hp branch will not be changed by the future updates of my master from juanvvc, true?

onox commented 9 years ago

No, unless you do git checkout master, git pull upstream master, git checkout c172-eng160-180hp, git rebase master again.

onox commented 9 years ago

That will do the same trick again that you just did.

dany93 commented 9 years ago

OK. Thank you onox, and sorry for my ignorance.

onox commented 9 years ago

Don't worry, you have never done a rebase before, so I understand it may be difficult.

onox commented 9 years ago

Anyway, can I move controls/engines/engine/master-bat to controls/switches/master-bat? And do the same thing for master-alt?

onox commented 9 years ago

I'll do it in a copy of your c172-eng160-180hp branch and push it later to juanvvc repository so that you can just pull it and it will fast-forward (no merge commits).

dany93 commented 9 years ago

Anyway, can I move controls/engines/engine/master-bat to controls/switches/master-bat? And do the same thing for master-alt?

I have no opinion, I do not understand what is does, how and why you do that. If it works from you point of view, you are better than me.

onox commented 9 years ago

Well, master-avionics sits already in /controls/switches/ and it might make switching between the two engines easier.

dany93 commented 9 years ago

In fact, I was just able to do the FDM part and the fuel.xml file to give the necessary tool. Beyond that, I trust you and hope (am almost sure) you and wlbragg can make it work.

onox commented 9 years ago

I have your commit locally here, so we can take it from here then.

dany93 commented 9 years ago

Do not forget that I wrote above: https://github.com/Juanvvc/c172p-detailed/issues/273#issuecomment-111828903

In the future, the engine activation can be done by one or the other of the properties:

  • magnetos: /controls/engines/engine[0 or 1]/magnetos = 0 or 3 (engine[0] for 160 hp, [1] for 180 hp)
  • float chamber: fdm/jsbsim/propulsion/tank[2 or 3]/priority = 0 or 1 (tank[2] for 160 hp, [3] for 180 hp).
onox commented 9 years ago

The procedures you mean?

dany93 commented 9 years ago

No. The properties that can be used in your code to switch engines (unless you prefer another way) .

onox commented 9 years ago

I have pushed branch bug-273.

onox commented 9 years ago

@dany93 For the primer and throttle, we are currently using /controls/engines/engine/primer and /controls/engines/engine/throttle, but it seems we can move these out of /controls/engines/engine[0] as well, right?

Although we can probably keep them there (and use them for both engines)

dany93 commented 9 years ago

I do not understand, cannot respond. It seems that the originals are by default. And I don't see neither the consequences, nor why. Merely, try to keep the code understandable for the future developpers.

What can I do with https://github.com/Juanvvc/c172p-detailed/commits/bug-273 ?

onox commented 9 years ago

Another question: If I set /controls/engines/engine[1]/magnetos to 1, 2, 3, does that mean I must set /controls/engines/engine[0]/magnetos to 0?

onox commented 9 years ago

I don't quite yet understand which code is reading /controls/engines/engine[1]/magnetos.