FlexSEA Wiki

A WEARABLE ROBOTICS TOOLKIT

User Tools

Site Tools


actpackfirmware

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
actpackfirmware [2019/05/22 16:12]
jfduval
actpackfirmware [2020/07/13 18:00] (current)
jfduval [Mn]
Line 1: Line 1:
 ====== Actuator Package Firmware Update ====== ====== Actuator Package Firmware Update ======
  
-Please note that in many situations only Mn needs to be changed. Mn's connector is typically exposed, and it uses a large pitch FFC connector.+Please note that in many situations only Mn needs to be changed. Mn's connector is typically exposed, and it uses a 1-mm pitch FFC (Flexible Flat Cable) ​connector.
  
 ===== Full upgrade ===== ===== Full upgrade =====
  
-If you are provided with three hex files, the order of operations is the following:+If you are provided with three hex files, the order of operations is listed below. If you are new to this process please read the sections below and make sure that you fully understand each step.
  
-  ​- Power the circuit with a USB cable +==== High-level order of operations: ==== 
-  - Connect the MiniProg ​to Re and program it + 
-  - Connect the MiniProg ​to Ex +  - Program Re 
-  - Turn the circuit ON with the pushbutton +  - Program Ex 
-  - Program Ex then remove ​the programmer +  - Program Mn 
-  - Connect the ST-Link to Mn and program it + 
-  - Do a full power cycle (not just with the button, remove USB power)+==== Detailed order of operations: ==== 
 + 
 +  ​- Power the FlexSEA-Rigid ​circuit with a USB cable. Do not use battery power. 
 +  - Connect the FFC from the MiniProg3 ​to the Re connector ​and program it. See [[#​ex_or_re|section "Ex or Re"]] below for details. 
 +  - Connect the FFC from the MiniProg3 ​to the Ex connector. 
 +  - Turn the circuit ON with the pushbutton. Make sure that the LEDs are ON. 
 +  - Program Ex then disconnect ​the programmer. 
 +  - Connect the ST-Link to Mn and program it. See [[#​mn|section "​Mn"​]] below for details. 
 +  - Do a full power cycle (not just with the button, remove USB power)
 + 
 +For all the details please refer to the sections below.
  
 ===== Ex or Re ===== ===== Ex or Re =====
  
-If an update is needed, Dephy will provide you with a hex file. You will need three tools:+Ex and RE use Cypress Programmable System on Chip (PSoC) microcontrollers. ​If an update is needed, Dephy will provide you with a hex file. You will need three tools:
   * [[http://​www.cypress.com/​products/​psoc-programming-solutions|PSoC Programmer]] software. Please note that Programmer gets installed when you install PSoC Creator; you may already have it.   * [[http://​www.cypress.com/​products/​psoc-programming-solutions|PSoC Programmer]] software. Please note that Programmer gets installed when you install PSoC Creator; you may already have it.
-  * A [[http://​www.cypress.com/​documentation/​development-kitsboards/​cy8ckit-002-psoc-miniprog3-program-and-debug-kit|MiniProg3]] ([[https://​www.digikey.com/​products/​en/​development-boards-kits-programmers/​programmers-emulators-and-debuggers/​799?​k=miniprog3|Digikey #​428-2975-ND]])+  * A [[http://​www.cypress.com/​documentation/​development-kitsboards/​cy8ckit-002-psoc-miniprog3-program-and-debug-kit|MiniProg3 ​(about $99)]] ([[https://​www.digikey.com/​products/​en/​development-boards-kits-programmers/​programmers-emulators-and-debuggers/​799?​k=miniprog3|Digikey #​428-2975-ND]])
   * A [[progadapt|Programming Adapter]]   * A [[progadapt|Programming Adapter]]
  
-Step-by-step: +Before following the step-by-step guide make sure to have all of the tools listed above. We assume that the programmer is connected to your computer, that its drivers are installed, and that you have the correct programming adapter for the task at hand. 
-  - Connect the FFC to the right connector. You will have to remove the enclosure. The FFC contacts have to face the PCB (ie. not visible from above). + 
-  - Power the circuit via USB - no battery +__Step-by-step:__ 
-  - Ex only: Turn the device ON, otherwise Re will keep your device under reset and prevent connection.+  - Connect the FFC (Flat Flexible Cable) from the MiniProg3 ​to the appropriate Ex or Re connector ​on the Actuator Package. You will have to remove the enclosure. The FFC contacts have to face the PCB (ie. not visible from above). 
 +  - Power the circuit via USB - no battery. 
 +  - Ex only: Turn the device ON, otherwise Re will keep your device under reset and prevent connection. For Re the circuit can be on or off, as long as it's receiving power it's OK.
   - Open Programmer and load the hex. Make sure that the settings match the following picture: {{ :​ps1.png?​200 |}}   - Open Programmer and load the hex. Make sure that the settings match the following picture: {{ :​ps1.png?​200 |}}
-  ​- Click program {{ :ps1.png?200 |}}+    * Note 1: You might have select your programmer under Port Selection. 
 +    * Note 2: the screenshot shows 5V detected. Some circuits use 3V3. As long as 3V3 or 5V is detected you are good to go. 
 +  ​- Click the "​Program " icon on the toolbar.
   - When it's done, power cycle.   - When it's done, power cycle.
- 
-Re can hold Ex and Mn in reset. To program Ex you have to turn Re on first (with the user switch). 
  
 ===== Mn ===== ===== Mn =====
  
-The Mn code is publicly available (see [[fx-rigid-mn|Compile fx-rigid-mn for your project]])You can compile your own version of the code and generate a hex file, and you can program it directly from Eclipse. On this page we will only cover the scenario where you have a hex file (provided by Dephy or generated by you) and you are not using Eclipse + OpenOCD to program the STM32. You will need three tools:+Mn uses an STM32 microcontrollerTo program it you will need three tools:
   * [[http://​www.st.com/​en/​development-tools/​stsw-link004.html|STM32 ST-LINK utility (STSW-LINK004)]] software. You might have to register to download it.   * [[http://​www.st.com/​en/​development-tools/​stsw-link004.html|STM32 ST-LINK utility (STSW-LINK004)]] software. You might have to register to download it.
 +    * The new ST-Link v3 can also be used. Please note that it uses a different connectors. That means you will need a different programming adapter.
   * An [[http://​www.st.com/​content/​st_com/​en/​products/​development-tools/​hardware-development-tools/​development-tool-hardware-for-mcus/​debug-hardware-for-mcus/​debug-hardware-for-stm32-mcus/​st-link-v2.html|ST-Link/​v2]] ([[https://​www.digikey.com/​product-detail/​en/​stmicroelectronics/​ST-LINK-V2/​497-10484-ND/​2214535|$23 on Digikey]])   * An [[http://​www.st.com/​content/​st_com/​en/​products/​development-tools/​hardware-development-tools/​development-tool-hardware-for-mcus/​debug-hardware-for-mcus/​debug-hardware-for-stm32-mcus/​st-link-v2.html|ST-Link/​v2]] ([[https://​www.digikey.com/​product-detail/​en/​stmicroelectronics/​ST-LINK-V2/​497-10484-ND/​2214535|$23 on Digikey]])
   * A [[progadapt|Programming Adapter]]   * A [[progadapt|Programming Adapter]]
  
-Step-by-step:+Before following the step-by-step guide make sure to have all of the tools listed above. We assume that the programmer is connected to your computer, that its drivers are installed, and that you have the correct programming adapter for the task at hand. 
 + 
 +__Step-by-step:__
   - Connect the 1mm FFC to the right connector. The connector is exposed, you do not need to remove the enclosure. The FFC contacts have to face the PCB (ie. not visible from above).   - Connect the 1mm FFC to the right connector. The connector is exposed, you do not need to remove the enclosure. The FFC contacts have to face the PCB (ie. not visible from above).
-  - Power the circuit via USB - no battery+  - Power the circuit via USB - no battery.
   - Turn the device ON, otherwise Re will keep your device under reset and prevent connection.   - Turn the device ON, otherwise Re will keep your device under reset and prevent connection.
   - Open the STM32 ST-Link Utility and load the hex {{ :​st1.png?​200 |}}   - Open the STM32 ST-Link Utility and load the hex {{ :​st1.png?​200 |}}
   - Click Program, then Start {{ :​st2.png?​200 |}} {{ :​st3.png?​200 |}}   - Click Program, then Start {{ :​st2.png?​200 |}} {{ :​st3.png?​200 |}}
   - When it's done, power cycle.   - When it's done, power cycle.
-  - Re can hold Ex and Mn in reset. To program Mn you have to turn Re on first (with the user switch). 
  
-===== Notes and Conventions ​=====+If you are having trouble programming Mn please review the [[manage:​debugger_tips#​settings|Settings]] and [[manage:​debugger_tips#​option_bytes|Option Bytes]] section of the [[manage:​debugger_tips#​Settings|Settings]] page. 
 +===== Notes, conventions,​ tips and tricks ​===== 
 +  * FlexSEA_Rigid is the circuit used for Actuator Packages and Dephy Exoskeletons. 
 +    * Re, Ex and Mn are respectively Regulate, Execute and Manage, three sub-circuits of FlexSEA-Rigid. They each have a microcontroller that may need new firmware at some point.
   * If you receive a hex/bin file with "​HWXX"​ in the name:   * If you receive a hex/bin file with "​HWXX"​ in the name:
     * "​HW"​ is short for Hardware version     * "​HW"​ is short for Hardware version
     * The following numbers are the version: 01 is 0.1, 10 is 1.0, etc. It refers to the [[rigid|FlexSEA-Rigid]] PCB version.     * The following numbers are the version: 01 is 0.1, 10 is 1.0, etc. It refers to the [[rigid|FlexSEA-Rigid]] PCB version.
   * Unless otherwise advised by Dephy, only flash a binary on the proper PCB (HW01 on Rigid 0.1)   * Unless otherwise advised by Dephy, only flash a binary on the proper PCB (HW01 on Rigid 0.1)
 +  * Re can hold Ex and Mn in reset. To program Ex or Mn you have to turn Re on first (with the user switch).
actpackfirmware.1558541559.txt.gz · Last modified: 2019/05/22 16:12 by jfduval