Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Basic System Manager #25

Open
wants to merge 22 commits into
base: main
Choose a base branch
from
Open

Basic System Manager #25

wants to merge 22 commits into from

Conversation

TheSpaceDragon
Copy link
Contributor

Description

What was completed, changed, or updated?

Basic System Manager is now complete!! This manager now takes input and executes them on motor outputs in an infinite loop. All that is needed to be done is instantiation and the call of the function, flyManually().


Why was this done (if applicable)?

N/A


Testing

What manual tests were used to validate the code?

Need help with on-site members with testing :p


What unit tests were used to validate the code?

To be written...

Documentation

Milestone 1: Manual Fixed Wing
Link to Asana task:
https://app.asana.com/0/1203458353737758/1204799650722171


Reminders

  • Add reviewers to the PR

  • Mention the PR in the appropriate discord channel

.DS_Store Outdated Show resolved Hide resolved
Boardfiles/discoveryl562qe/Core/Src/main.c Outdated Show resolved Hide resolved
Boardfiles/nucleol552zeq/Core/Src/usart.c Show resolved Hide resolved
Drivers/rc_receiver/Inc/rcreceiver_datatypes.h Outdated Show resolved Hide resolved
SystemManager/Src/SystemManager.cpp Outdated Show resolved Hide resolved
SystemManager/Src/SystemManager.cpp Outdated Show resolved Hide resolved
SystemManager/Src/SystemManager.cpp Outdated Show resolved Hide resolved
SystemManager/Src/SystemManager.cpp Outdated Show resolved Hide resolved
this->throttleMotorChannel_.set(rcInputs_.throttle);
this->yawMotorChannel_.set(rcInputs_.yaw);
this->rollMotorChannel_.set(rcInputs_.roll);
this->pitchMotorChannel_.set(rcInputs_.pitch);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 notes

  1. This assumes we only have 1 motor per axis, which wont be true for a plane. We will likely have 2 motors for roll.
  2. There is no provision here for arm/disarm. The throttle motor will spin up if the throttle stick on the controller is bumped, and is not safe at all. (this is something that happens all the time, please add an arm/disarm check. Typically you can only arm if the throttle is down and a switch is hit.)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. I believe for M1 I was asked to assume that each axis has its own motor.
  2. Just added a provision to check for arm/disarm

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can say with near certainty that you will need to add a second motor for the roll axis that is inverted (1 motor per aileron)

Tools/Firmware/CMakeLists.txt Outdated Show resolved Hide resolved
Aidan-B
Aidan-B previously requested changes Aug 3, 2023
Drivers/rc_receiver/Inc/rcreceiver_datatypes.h Outdated Show resolved Hide resolved
Drivers/rc_receiver/Src/sbus_receiver.cpp Outdated Show resolved Hide resolved
Drivers/rc_receiver/Inc/sbus_receiver.hpp Outdated Show resolved Hide resolved
SystemManager/Inc/SystemManager.hpp Outdated Show resolved Hide resolved
SystemManager/Src/SystemManager.cpp Show resolved Hide resolved
@Chrisc110 Chrisc110 dismissed Aidan-B’s stale review November 16, 2023 01:49

Fixed, aidan is busy

Co-authored-by: Anthony Bertnyk <anthony.bertnyk@gmail.com>
Co-authored-by: TheSpaceDragon <developerskytech@gmail.com>
Co-authored-by: Navtaj Hundal <n2hundal@uwaterloo.ca>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet