simIncludeRW
simIncludeRW
class simIncludeRW.rwFactory[source]
: Bases: object
code
Reaction Wheel Factory Class
BCT\_RWP015(*RW*)[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.BCT_RWP015)
: BCT RWP015
RW Information Source:
<https://storage.googleapis.com/blue-canyon-tech-news/1/2019/10/BCT_DataSheet_Components_ReactionWheels_F2.pdf>
Not complete; fields not listed are estimates.
Parameters:
: **RW** – reaction wheel configuration message
Returns:
NanoAvionics\_RW0(*RW*)[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.NanoAvionics_RW0)
: NanoAvionics RW0
RW Information Source:
<https://nanoavionics.com/cubesat-components/cubesat-reaction-wheels-control-system-satbus-4rw/?utm_source=chatgpt.com>
Not complete; fields not listed are estimates.
Parameters:
: **RW** – reaction wheel configuration message
Returns:
addToSpacecraft(*modelTag*, *rwStateEffector*, *sc*)[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.addToSpacecraft)
: This function should be called after all RW devices are created with createRW()
It creates the C-class container for the array of RW devices, and attaches
this container to the spacecraft object
:param :
:type : param modelTag: string with the model tag
:param :
:type : param rwStateEffector:
:param :
:type : param sc: spacecraft object
create(*rwType*, *gsHat\_B*, *\*\*kwargs*)[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.create)
: This function is called to setup a RW device in python, and adds it to the RW factory
list rwList{}. The function returns a copy of the device that can be changed if needed.
The first 2 arguments are required, the remaining arguments are optional with:
Parameters:
: - **rwType** (*string*) – RW manufacturing name.
- **gsHat\_B** (*list*) – Spin axis unit vector gsHat in B-frame components
- **kwargs** –
Omega: float
: initial RW speed in RPM
Omega\_max: float
: maximum RW speed in RPM
rWB\_B: list
: 3x1 list of RW center of mass position coordinates
RWModel: integer
: RW model type such as BalancedWheels, JitterSimple and JitterFullyCoupled
useRWfriction: BOOL
: conditional to turn on RW internal wheel friction
useMinTorque: BOOL
: conditional to clip any torque below a minimum torque value
useMaxTorque: BOOL
: conditional to clip any torque value above a maximum torque value
u\_max: float
: the maximum RW motor torque
maxMomentum: float
: maximum RW wheel momentum in Nms. This is a required variable for some wheels.
P\_max: float
: the maximum allowed wheel power for changing wheel speed (does not include a base power requirement)
label: string
: with the unique device name, must be 5 characters or less
fCoulomb: float
: Coulomb friction torque model coefficient
fStatic: float
: Static friction torque magnitude
betaStatic: float
: Stribeck friction coefficient, positive turns Stribeck friction on, negative turns this friction off
cViscous: float
: Viscous friction coefficient
Js: float
: RW inertia about spin axis
Returns:
: **RWConfigSimMsg** – A handle to the RW configuration message
Return type:
: message structure
custom(*RW*)[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.custom)
: Creates an empty reaction wheel configuration message. This assumes the user provided the
RW maximum speed and maximum angular momentum information so that Js can be computed,
or the user provides the Js inertia value directly.
Parameters:
: **RW** – reaction wheel configuration message
Returns:
getConfigMessage()[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.getConfigMessage)
: Returns a FSW reaction wheel configuration message based on the current setup.
Returns:
: RWArrayConfigMsg
getNumOfDevices()[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.getNumOfDevices)
: Returns the number of RW devices setup.
Return type:
: return: int
setGsHat(*RW*, *gsHat\_B*)[[source]](https://avslab.github.io/basilisk/_modules/simIncludeRW.html#rwFactory.setGsHat)
: > Function to set the gsHat\_B RW spin axis vector. This function
> automatically computes to companion transfer axes to complete a
> wheel reference frame.
Parameters:
: - **RW**
- **gsHat\_B**