x y z Body frame Goal vector y x y Body frame Goal vector x z Body frame Goal vector x Body frame
Sun normal: Spin mode (assume omega x= omega y=0) omega x, omega y =\=0 If we want to eliminate them, we need to estimate them. Rad/sec 4 rpm Sun elevation near 90 degree (random)
Elevation=0 (not ecliptic normal) Sun normal: precession mode (assume omega x= omega y=0) Not good for initial conditions with high elevation
The sun ECI vector Ecliptic plane
High elevation The sun ECI vector
One strategy: only using one side controller (elevation >0 or elevation <0) elevation Open controller
Omega change Because we only use one coil in z axis, the effects to the spin rate are small 4 rpm omega x, omega y
Conclusion: 1 The storage of battery for the ACS is ok (0.7 w for each “turn on” operation ) 2 test other initial conditions for sun normal mode Issue: 1 need to figure out what happen in the high elevation 2 PIC operation temperature -40 o C~ 85 o C 3 If there are two fixed vectors in the ECI frame, is it possible to know the angular velocities of the three dimension (without any information from the ground )? B field sun B field sun In the view of the body t1t A hour at 8 volt
x y z Body frame Goal vector y x y Body frame Goal vector x z Body frame Goal vector x Body frame
based on the same fixed vector in ECI x z Body frame Goal vector x Body frame x z Y ECI frame Goal vector is fixed If there exists omega x or omega y, the goal vector is no longer fixed in the ECI frame
Time frame =0.01Time frame =0.1 Solver problem Time frame =0.01
Different model structure may produce the errors ! Give the Sun ECI initial condition Give the initial attitude Elevation of the sun in the body frame Due to omega x,omega y Give the Sun ECI initial condition
ground Revolute around local x Revolute around local y Revolute around local z Equator plane Mass: 10e-9 kg Moment of inertia: 10e-7 kgm^2
ground Revolute around local x,y,z And allow slide in x,y,z direction ECI Equator plane
detumble Sun normal :spin up Sun normal: precession Omega x,y,z4 rpm Elevation=0
Precession Sun normal precession elevation Deviation of the attitude (ecliptic normal) Sun normal precession
Average: 27 mins
Z x y bx by bz Rotation matrix: Y(90 degree) Z(180 degree) Assume: local b field not change much
simulation Local b field ECEF local b field body frame local magnetometer frame ACS module rotation matrix and normalized module In PIC
Power from each solar panel (total six panels) 1: with 10 degree constraints for each panel 2: the energy is proportional to the area 3: 15% efficiency for each panel 4: also including the power from the albedo 5 assume in each panel, the power is uniform 6 the area of the solar panel, right now: (10x10 cm) meter square 7 assume the storage: 3.75 A hour at 8 volt= =10 o Z+ X+ Y+ elevation Z- Y- X-
“for the (-X) side, the magnetic dipole moment is estimated to be 0.87 Am 2 consuming 6.43 Watts and drawing 0.80 Amperes. The projected values for the (-Z) side [which has not been built yet] are 0.85 Am2 for the magnetic dipole, 8.63 Watts for power and 1.08 Amperes for current.” Assume 10 duty cycle Sun+albedo Coil zCoil x Results: J for every 0.1 second Error attitude
Max PIC energy consumption W=250 mA*4.0V=1W
1: W=(125-(-40))/40=4.125w maximum allowed power Dissipation or the chip will melt away. 2: W=(100-80)/40=0.5w <1w ?
Indirect access values: With pointers assigning specific address Receive from Rs232, don’t care which memory the compiler assigned … Transmit through Rs232
Data from RS232 Store in the specific memory HSK read values from the specific memory ACS reads values from the specific memory other work ACS store values to the specific memory HSK read values from the specific memory other work Data to RS232 (Torque command) In the future, replaced by other modules, like sun sensor module, MAG module, etc. Just write to the same memory write to the specific memory In the future, replaced by toque command module Int main (){ } Fixed, no change
PIC simulink Another issue: 1:0.7 =real time: simulink
Indirect access values: With pointers assigning specific address Receive from Rs232, don’t care which memory the compiler assigned … Transmit through Rs232
Protocol design and tasks ….. Serial data Begin byte Data set data1data Each variable (total 17) is float, each float includes 4 bytes (17x4=68) Begin byte ….. 1 separate each variable (float->byte) 2 transmit them in the serial port of Simulink 3 receive them in the serial buffer of PIC 4 combine them in the PIC (byte-float)
Structure for parallel testing (run PIC and simulink at the same time, at the same simulink file) Space Environment, Sensor, CINEMA Serial encode Simulink serial interface Serial decode ACS in PIC (c code) ACS in simulink(c code) Serial encode Serial decode Serial encode Serial decode Coil status Simulink serial interface Guarantee all the initial conditions are the same torque Guarantee, the time of switching mode are the same
simulinkPIC Experiment results for the controller (new version)
Power from each solar panel (total six panels) 1: with 10 degree constraints for each panel 2: the energy is proportional to the area 3: 15% efficiency for each panel 4: also including the power from the albedo 5 assume in each panel, the power is uniform 6 the area of the solar panel, right now: (10x10 cm) meter square (x+-:3, y+-:1, z+-:1) 7 assume the storage: 3.75 A hour at 8 volt= =10 o Z+ X+ Y+ elevation Z- Y- X-
The day is longer than the night Accumulating energy
Z+ X+ Y+ elevation Ecliptic normal
Magnetometer sample time: 2 Hz extrapolation Norm of the error in 3 direction
2 Hz
Magnetometer sample time: 5 Hz extrapolation Norm of the error in 3 direction
10Hz 5 Hz
Detumble Detumble+ spin up 2Hz sample time Raw edge
Model Predictive Control MPC slides from Prof. Francesco Borrelli
Do control only for s>0(spin) s>0 s<0 (spin) Least square Using one coil
MPC—using the information of the future and current B field Least square—using the current B field with two coils and various duty cycle Solution sets One coil with fixed duty cycle Two coils with fixed duty cycle
Example--- Get the maximum profits from the Banks in 2 years Need the transfer fee from one bank to the other. The interest rates also depend the total saving in each account One coil: BOA, only allowed to put the all of the money in or out Two coils: Citi, BOA, only allowed to put all of the money in one account Least square: : Citi, BOA, allowed to adjust the money in each account. MPC: Citi, BOA allowed to adjust the money in each account and know the interest rates in the future. This method can also consider other situations.
Linearized the nonlinear systems continuous model continuous model discrete model Set the system structure and parameters for the solver Set the translate target set Solver produce the control command Update the current state and insert to the nonlinear system k=k+1 N=N+1
Can update B field for each k
Discrete Model
Final target set Nonlinear system Initial state Translate target set wz wx wy N=1 N=2 N=3 N=0 K=1 K=2
Results: polytope for the feasible region The geometry will update for each k
Detumble mode
Advantage: easy to implement for off-line computation, very flexible and guaranteed optimization in some local region. If the system has no complexity, the optimization no longer exists. Disadvantage: Not good implementation for PIC, it needs more power for the computation for each iteration. Next Step: set the environment of parameters of MPC near the real environment. Investigate the hybrid system. Build the spin up and precession modes in MPC Objection function: consider which variables we want to weight, power, settling time, final step, etc. Control Strategy: Design any controller or adjust parameters in the current controller in the PIC and try to make the results near the results from MPC
Controller 5 Hz: with two coils controller Spin rateattitude
Controller :5 Hz with one coils controller Average: precession over 100 mins
Controller :2 Hz with one coils controller
Sun position 2 HZSun position 5 HZ
MAG data 2 HZ MAG data 5 HZ
Way to eliminate the effects of the albedo Method 1 shadow 1.Measure the minimum power (only from the sun) 2.Get the position of the sun 3.Know the dynamics of the satellite, torque command 4.compute the position of the sun in the future 5.Do Precession, until in the FOV of the sun sensor Disadvantage: hard to keep the initial attitude fixed
Way to eliminate the effects of the albedo Method 2 shadow 1.Set the minimum power band (only from the sun) 2.Get the position of the sun 3.Know the dynamics of the satellite, torque command 4.compute the position of the sun in the future 5.Precession, until in the FOV of the sun sensor advantage: no need to keep the initial attitude fixed
Before switch to the estimator
Rotation matrix Error of Normal 1 of the rotation matrix will disconvenge
Random rotation abound the orbit
42degree, 5 degree 42 o 5o5o
Sun: unit vector Albedo power in x+ Albedo power in x- Albedo power in y+ Albedo power in y- Albedo power in z+ Albedo power in z- Solar Panel module in the simulink Albedo power vector Controller + normalize
X,Y Z+ Z- precession
Extreme case
X,Y Z+ Z- precession
Z+ X,Y 4 rpm Z-
Sun: unit vector Albedo power in x+ Albedo power in x- Albedo power in y+ Albedo power in y- Albedo power in z+ Albedo power in z- Solar Panel module in the simulink Albedo power vector Controller + normalize
Sun: unit vector Albedo power in x+ Albedo power in x- Albedo power in y+ Albedo power in y- Albedo power in z+ Albedo power in z- Controller + normalize separate Solar Panel module in the simulink Convert to a vector
Fix the code for in the controller
Sun: unit vector Albedo power in x+ Albedo power in x- Albedo power in y+ Albedo power in y- Albedo power in z+ Albedo power in z- Controller + normalize separate Solar Panel module in the simulink Convert to a vector Arbitrary disturbance disturbance
Without albedo Without un-viewable angle
Only use Mag data in the spin up B field Body frame: omega=[ ] B field Body frame: omega=[ ] B field Body frame: omega=[ ]
Only use Magnetometer in the spin up B field Body frame: omega=[ ]B field Body frame: omega=[ ] B field Body frame: omega=[ ] B field Body frame: omega=[0 0 0 ]
B field Body frame: omega=[ ] B field Body frame: omega=[ ]
Global weather satellite: rotating Earth rotating Earth with animated clouds covering the most recent 3 week showing current clouds
Conclusion: 1 need to fix the dynamics equation for the sun estimator or compensate it with MAG data—(maybe not necessary) 2 Build the global weather dynamic cloud model in the simulink 3 investigate the determination for the sun position with the info of the geometry of the CINEMA at one instant.
Spin mode without any information from the ground. inititally,w1,w2,w3=0
Assume we can get correct omega z Initial omega x,y,z=[ ]Initial omega x,y,z=[0 0 0]
How to get omega(Wiki) I modify the above as Skew matrix Not invertible Infinity solutions for omega
R(t)R(t-1) (R(t)-R(t-dt)) W=V/R=(R(t)-R(t-dt))/(dt*R(t)) dt 0 The problem is R not perpendicular with w, we need to separate the vector to horizontal and vertical direction. However, we don’t know the direction of w R(t) w R’ R’’
The above skew matrix (n=3) is rank 2 combine the information with solar panels to make it becomes rank 3 Algorithm omega estimator by Y.T Mao
Simulation results Omega xOmega y Omega z Initial Omega=[ ]
Denominator vs omega x
A approach to fix it Consider the all the combination from B field and Sun position (body frame) Results for combination: b field, sun (1,2)(1) (1,2)(2) (1,2)(3) Omega x Omega y Omega z Chose the biggest determinant
Include with solar panel module (assume Mag is prefect) Omega x Omega y Omega z
Do spin up with the estimate omega (without any information from the ground station) Estimate omega x Estimate omegay Estimate omega z
With static albedo(ice) Error angle between the real sun and the effected sun Albedo power in the x +plame
Conclusion: 1 It is ok to use the solar panels and Mag to do spin up without ground station. 2 Try to only use historical data of Mag for the next task. 3 incorporate new omega estimation module in the ACS module of the PIC. 4 investigate the determination for the sun position with the info of the geometry of the CINEMA at one instant. 5 try to use only B field (ground), B field(body), sun position(body) to do the attitude determination(without sun position(ground) estimator, need the exactly launch time)
Detumble Detumble+ spin up 2Hz sample time Raw edge
R(t)R(t-1) (R(t)-R(t-dt)) W=V/R=(R(t)-R(t-dt))/(dt*R(t)) dt 0 The problem is R not perpendicular with w, we need to separate the vector to horizontal and vertical direction. However, we don’t know the direction of w R(t) w R’ R’’