Modifications

Sauter à la navigation Sauter à la recherche
59 octets supprimés ,  23 septembre 2018 à 19:47
Ligne 2 : Ligne 2 :     
== Forewords ==  
 
== Forewords ==  
{{traduction}}
   
One of the most exciting feature of the M0 Express board is this small FLASH chip wired on the SPI bus. That memory could be used to provide lot of services like storing files, python script and many more.
 
One of the most exciting feature of the M0 Express board is this small FLASH chip wired on the SPI bus. That memory could be used to provide lot of services like storing files, python script and many more.
   Ligne 203 : Ligne 202 :     
== Access to the SPI Flash ==
 
== Access to the SPI Flash ==
Arduino n'est malheureusement pas capable d'exposer un périphérique de stockage (dit "''mass storage''" en anglais). Par conséquent, il faut utiliser CircuitPython qui, lui, est capable de faire cela pour nous. Voici la technique à utiliser.Here's the full technique:
+
Arduino is not able to expose himself as a storage device (a "''mass storage''" device). Instead you will have to switch to CircuitPython to expose the SPI Flash as storage device. Here is the technique to use:
* Démarrer le bootloader de votre carte Express. Faites un glisser/déposer de la dernière version du fichier uf2 '''circuitpython'''.
+
* Start the bootloader of the Express board. Drag and drop the last version of the '''circuitpython''' (the UF2 file).
* Après un moment, vous devriez voir apparaître le lecteur '''CIRCUITPY''' contenant un fichier '''boot_out.txt'''. Voilà, le système de fichier est initialisé sur la Flash SPI.
+
* After a while, you should see a '''CIRCUITPY''' drive containing the file '''boot_out.txt'''. Great, the Circuit Python filesystem is initialized on the SPI Flash.
* Ouvrez maintenant Arduino IDE et téléversez l'exemple '''fatfs_circuitpython''' disponible dans la bibliothèque SPI d'Adafruit. Ouvrez la console série pour démarrer le croquis. Voilà, le système de fichier CircuitPython sera correctement monté et le fichier '''data.txt''' créé et initialisé.
+
* Open the Arduino IDE and upload the '''fatfs_circuitpython''' sketch available in the Adafruit's SPI FLASH library. Open the serial console and start the sketch. Voila! the CircuitPython file system is properly mounted and the file '''data.txt''' created and initialized.
 +
 
 +
{{ambox|text=So, the Arduino Sketch did manipulated a file onto the SPI Flash owning the CircuitPython filesystem!}}
    
{{ADFImage|FEATHER-M0-ArduinoIDE-SPI-Flash-02.png}}
 
{{ADFImage|FEATHER-M0-ArduinoIDE-SPI-Flash-02.png}}
   −
* Revenons sur notre ordinateur, redémarrez le bootloader de la carte Express --ET-- re-glissez/re-déposez '''circuitpython.uf2''' sur le lecteur '''BOOT''' rendu accessible par le bootloader. Voilà, CircuitPython est résintallé sur la carte Express.
+
This time, we will open the file created by the Arduino sketch.
* Au bout d'un moment, le lecteur '''CIRCUITPY''' redevient accessible. Celui-ci expose a nouveau le système de fichier MicroPython de la Flash SPI. Vous pouvez maintenant voir le fichier '''data.txt''', l'ouvrir et en consulté le contenu!
+
 
 +
* Let plug again the board on the computer, restart the bootloader on the Express board --AND-- drag/drop  the '''circuitpython.uf2''' on the drive '''BOOT''' made accessible by the bootloader. Great, CircuitPython is now installed (again) on the board.
 +
* After a a while, the '''CIRCUITPY''' drive is made available by CircuitPyhton. This would expose the SPI Flash content as a Mass Storage device. You can now see the file '''data.txt''' created by our Arduino Sketch, Open it and read it's content :-) !
    
{{ADFImage|FEATHER-M0-ArduinoIDE-SPI-Flash-03.png}}
 
{{ADFImage|FEATHER-M0-ArduinoIDE-SPI-Flash-03.png}}
   −
Une fois que votre croquis de datalogging Arduino fonctionne comme attendu, vous pouvez simplifier la procédure en copiant '''CURRENT.UF2''' depuis le lecteur '''BOOT''' pour faire une copie de sauvegarde de votre programme Arduino. Vous pourrez ensuite charger CircuitPython pour accéder au système de fichier de la Flash SPI et enfin recopier votre '''CURRENT.UF2''' sur le lecteur '''BOOT''' de la carte Express pour réactiver votre croquis Arduino!
+
Once your datalogging sketch finish, you can simplify the procedure by copying the '''CURRENT.UF2''' from the '''BOOT''' drive to make "ready to use copy" of your sketch. You could now load the CircuitPython to access the CircuitPython file system and then switch back to you Arduino sketch by restoring the '''CURRENT.UF2''' on the Express Board!
    
{{ENG-CANSAT-TRAILER}}
 
{{ENG-CANSAT-TRAILER}}
29 836

modifications

Menu de navigation