Modifications

Sauter à la navigation Sauter à la recherche
aucun résumé de modification
Ligne 1 : Ligne 1 :  
{{ENG-CANSAT-PICO-NAV}}
 
{{ENG-CANSAT-PICO-NAV}}
   −
== Inroduction ==
+
== Introduction ==
{{traduction}}
   
Until now, we have worked with the emitter linked to a computer via USB cable.
 
Until now, we have worked with the emitter linked to a computer via USB cable.
   Ligne 17 : Ligne 16 :  
This approach is very efficient but can lead to plateform lock-up when the script is buggy or contains an infinite loop.
 
This approach is very efficient but can lead to plateform lock-up when the script is buggy or contains an infinite loop.
   −
At MCHobby we do use a slide switch name "RunApp" as recovery method.
+
{{ambox|text=At MCHobby we do use a slide switch name "RunApp" as recovery method.}}
    
The aim is to check the status of a given pin (eg: GP22) before starting the user script (say {{fname|user.py}}).
 
The aim is to check the status of a given pin (eg: GP22) before starting the user script (say {{fname|user.py}}).
Ligne 23 : Ligne 22 :  
In case of trouble during testing/development we just switch-off the "RunApp" and press the reset button to restart the Pico.  
 
In case of trouble during testing/development we just switch-off the "RunApp" and press the reset button to restart the Pico.  
   −
[[Fichier:ENG-CANSAT-PICO-MISSION1-AUTONOMOUS.jpg|150px]]
+
[[Fichier:ENG-CANSAT-PICO-MISSION1-AUTONOMOUS.jpg|250px]]
    +
Here is the content of {{fname|main.py}} script.
    +
<syntaxhighlight lang="python">
 +
from machine import Pin
 +
run = Pin( 22, Pin.IN, Pin.PULL_UP )
 +
if run.value() == 1:
 +
    import user # load user.py file and execute it
 +
</syntaxhighlight>
 +
 +
To resume:
 +
* If the RunApp switch is on the '''Run''' position at power-up the {{fname|user.py}} script does start.
 +
* If the RunApp switch is on the '''Stop''' position at power-up the {{fname|user.py}} script will not start.
 +
 +
{{ambox|text=TIPS: Light-up the onboard LED as first {{fname|user.py}} operation. If is a good way to know if the user script is running.}}
 +
 +
== Power It ==
 +
 +
To work autonomously, the CanSat must be powered with a battery. This point have been adressed with a {{pl|534|Adafruit PowerBoost 500}} breakout board:
 +
 +
{{ADFImage|PowerBoost-500-Chargeur-01.jpg|320px}}
 +
 +
The {{pl|534|Adafruit PowerBoost 500}} is a breakout board able:
 +
* to discharge a Lipo battery to generates 5V output (500mA max)
 +
* to charge the Lipo battery when connected to an external 5V supply
 +
* to do the both operations at the same time.
 +
 +
The great thing about the PowerBoost is that it can use the Pico VBUS to recharge the Lipo. So, no need of an external power connexion to refill the Lipo (just plug you Pico to an USB Power source).
 +
 +
All of this have been adressed with great details in the '''Pico Powering''' section.
 +
 +
 +
{{ttuto-begin}}
 +
 +
{{ttuto
 +
  |label=Pico Powering
 +
  |descr=How to properly power up your Pico
 +
  |img=tlogo-pico-power.jpg
 +
  |link=ENG-CANSAT-PICO-POWERING
 +
}}
 +
 +
{{ttuto-end}}
 +
 +
== Sparing Power ==
 +
The best approach to spare the energy is to consume the LiPo power as the last moment (to keept as must as power as possible for the launch).
 +
 +
There are several options for that:
 +
# Keeping the Pico Powered via USB as much as possible (with a computer or a powerbank).
 +
# Disabling the PowerBoost (and power down the complete projet):
 +
#* '''WITHOUT''' Cansat Kit: Use a slide switch (or a jumper) to tie the '''PowerBoost EN''' to the GND
 +
#* '''With''' Cansat Kit: The slide switch (or jumper) can be placed near of the border of the board.
 +
 +
[[Fichier:ENG-CANSAT-PICO-CONTENT-14.jpg|640px]]
 +
 +
{{dbox-orange|Keeping the Pico Powered before launch have the advantage of having the software already running.<br />Powering-up at the last moment is also the risk of discovering an unespected issue (depending on how the setup have been tested). }}
    
{{ENG-CANSAT-PICO-TRAILER}}
 
{{ENG-CANSAT-PICO-TRAILER}}
29 917

modifications

Menu de navigation