User Tools

Site Tools


en:arm_programming

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
en:arm_programming [2013/07/28 10:56] fluktuaciaen:arm_programming [2013/11/08 13:05] – [Compiler] kaklik
Line 26: Line 26:
 To help you with the Ubuntu installation it is possible to used a ready-made [[https://launchpad.net/~terry.guo/+archive/gcc-arm-embedded|deb packages]]. A PPA repository currently works only for Ubuntu version 12.04.   To help you with the Ubuntu installation it is possible to used a ready-made [[https://launchpad.net/~terry.guo/+archive/gcc-arm-embedded|deb packages]]. A PPA repository currently works only for Ubuntu version 12.04.  
  
-== Quick installation using a __repository__ ==+== Quick installation using a software repository ==
  
   sudo add-apt-repository ppa:terry.guo/gcc-arm-embedded   sudo add-apt-repository ppa:terry.guo/gcc-arm-embedded
   sudo apt-get update   sudo apt-get update
-  sudo apt-get install gcc-arm-none-eabisudo+  sudo apt-get install gcc-arm-none-eabi
      
 == Compilation procedure ==   == Compilation procedure ==  
Line 80: Line 80:
 == Connecting the module == == Connecting the module ==
  
-In order to be able to use the bootloader, it in necessary to connect it to the serial link. In the case of using [[cs:usb232r|USB232R01B]] module, it is sufficient to have only RXD and TXD connected in a following way:+In order to be able to use the bootloader, it in necessary to connect it to the serial link. In the case of using [[en:usb232r|USB232R01B]] module, it is sufficient to have only RXD and TXD connected in a following way:
  
  
Line 144: Line 144:
 A __batch__ to call the dfu-util on Windows platform and the compiled version of dfu-until without the need to download other libraries can be found here: [[http://www.mlab.cz/WebSVN/listing.php?repname=MLAB&path=%2FModules%2FARM%2FSTM32F10xRxT%2FSW%2FUSB_bootloader%2FWin32%2F#_Modules_ARM_STM32F10xRxT_SW_USB_bootloader_Win32_/|dfu-util-static]]. Furthermore, to run the program on Windows, it is necessary to install some version of uslib. The easiest way to do it is to use [[http://www.mlab.cz/WebSVN/filedetails.php?repname=MLAB&path=%2FModules%2FARM%2FSTM32F10xRxT%2FSW%2FUSB_bootloader%2FWin32%2Fzadig.exe/|zadig]]. In the course of installation, the processor must be in DFU mode (see the key sequence mentioned above). A __batch__ to call the dfu-util on Windows platform and the compiled version of dfu-until without the need to download other libraries can be found here: [[http://www.mlab.cz/WebSVN/listing.php?repname=MLAB&path=%2FModules%2FARM%2FSTM32F10xRxT%2FSW%2FUSB_bootloader%2FWin32%2F#_Modules_ARM_STM32F10xRxT_SW_USB_bootloader_Win32_/|dfu-util-static]]. Furthermore, to run the program on Windows, it is necessary to install some version of uslib. The easiest way to do it is to use [[http://www.mlab.cz/WebSVN/filedetails.php?repname=MLAB&path=%2FModules%2FARM%2FSTM32F10xRxT%2FSW%2FUSB_bootloader%2FWin32%2Fzadig.exe/|zadig]]. In the course of installation, the processor must be in DFU mode (see the key sequence mentioned above).
  
-You can test the firmware loading using this sample binary, that creates the USB HID mouse out of STM32F107 processor. [[http://www.mlab.cz/WebSVN/filedetails.php?repname=MLAB&path=%2FModules%2FARM%2FSTM32F10xRxT%2FSW%2FUSB_bootloader%2Fsample%2FSTM32F107_mouse.bin/|STM32F107_mouse.bin]]+You can test the firmware loadingusing this sample binary, that creates the USB HID mouse out of the STM32F107 processor. [[http://www.mlab.cz/WebSVN/filedetails.php?repname=MLAB&path=%2FModules%2FARM%2FSTM32F10xRxT%2FSW%2FUSB_bootloader%2Fsample%2FSTM32F107_mouse.bin/|STM32F107_mouse.bin]]
  
      
 ==== J-TAG ==== ==== J-TAG ====
  
-K programování přes JTAG se potřebuje externí programátorNa modulu [[cs:stm32f10xrxt|STM32F10xRxT01A]] jsou JTAG dráty vyvedeny na zvláštním konektoru (J51). Jako externí programátor může být využit například modul [[http://www.mlab.cz/PermaLink/JTAGFT2232V02A|JTAGFT2232V02A]]+An external programmer is required to program through JTAG. In the case of [[cs:stm32f10xrxt|STM32F10xRxT01A]] module, the JTAG wires have a special __pin-out__ (J51). The [[http://www.mlab.cz/PermaLink/JTAGFT2232V02A|JTAGFT2232V02A]] module can be used as an external programmer.
  
-Programovat lze napřotevřeným programem [[http://openocd.sourceforge.net/|OpenOCD]], který podporuje většinu používaných JTAG programátorů a umí vytvořit back-end pro [[http://www.gnu.org/software/gdb/|GDB]], takže podporuje i debugování.+For programing is suitable eg. [[http://openocd.sourceforge.net/|OpenOCD]], an open programm that supports the majority of JTAG programmers and is able to create the back-end for [[http://www.gnu.org/software/gdb/|GDB]], thus supporting the debugging as well.
  
-OpenOCD má v Ubuntu sice nativně podporované balíčkyale jejich verze je obvykle značně opožděna za současným vývojemProto je lepší si zkompilovat aktualní verzi..  + 
 +=== Ubuntu === 
 + 
 +Though there already exist natively supported packages for OpenOCD in Ubuntu, their versions are usually  
 +quite old compared to the latest development. It is therefore recommended to compile the current version...
  
   sudo apt-get install libtool git gcc automake libftdi-dev texinfo   sudo apt-get install libtool git gcc automake libftdi-dev texinfo
Line 162: Line 166:
   make   make
   sudo make install   sudo make install
-   + 
-Tím máme v systému naistalováno OpenOCD. Pokud jej budeme chtít odinstalovatpoužije se příkaz +To uninstal the OpenOCD, use the following command  
  
   sudo make uninstall   sudo make uninstall
  
-Pokud máme k počítači připojený modul [[cs:jtagft2232v|JTAGFT2232V02A]] s nahraným schématem v FPGA, tak se můžeme připojit k nějakému ARMu.+If you have a [[cs:jtagft2232v|JTAGFT2232V02A]] module with __uploaded FPGA scheme__ connected to you computeryou can connect to ARM 
  
   sudo openocd -f "interface/busblaster.cfg" -f "target/stm32f1x.cfg"   sudo openocd -f "interface/busblaster.cfg" -f "target/stm32f1x.cfg"
Line 186: Line 190:
   Info : stm32f1x.cpu: hardware has 6 breakpoints, 4 watchpoints   Info : stm32f1x.cpu: hardware has 6 breakpoints, 4 watchpoints
  
-OpenOCD teď vytvořilo server ke kterému se můžeme přípojit přes telnet + 
 +Tho OpenOCD has created a server, that you can connect with through telnet
  
   telnet localhost 4444   telnet localhost 4444
Line 196: Line 201:
   >    > 
    
 +
 +=== Mac OS X ===
 +
 +
 +  ./configure --enable-ft2232_ftd2xx openocd -f busblaster.cfg -f /usr/local/share/openocd/scripts/target/stm32f1x.cfg\\
 +\\
 +busblaster.cfg:\\
 +  interface ft2232
 +  ft2232_device_desc "Dual RS232-HS"
 +  ft2232_layout jtagkey
 +  ft2232_vid_pid 0x0403 0x6010
 +
 +basic info: http://pramode.net/fosstronics/stm32-circle.txt
 +
 ===== RTOS ===== ===== RTOS =====
  
 ==== Chibios ==== ==== Chibios ====
  
-[[http://www.chibios.org/dokuwiki/doku.php|Webová stránka projektu]] +[[http://www.chibios.org/dokuwiki/doku.php|Webpage of the project]] 
-  + 
-Jde o základní relaltime operační systém s HAL zjednodušující práci s mikroprocesoremPro snazší práci byla vytvorena kofigurace Chibios přímo pro modul s ARM dostupná je na [[https://github.com/toxygen/mlab-chibios|githubu]] +Chibios is a basic realtime OS with HAL component that simplifies the work with a microprocessorTo facilitate the work, a Chibios configuration directly for module with ARM has been created, and it is available at [[https://github.com/toxygen/mlab-chibios|github]].  
 + 
 +In order to obtain more documentation use [[http://chibios.sourceforge.net/html/index.html|ChibiOS/RT]] site.
  
-Další programová dokumentace je dostupná [[http://chibios.sourceforge.net/html/index.html|ChibiOS/RT]] +=== LED blink demo ===
-=== Demo blikání LED ===+
  
   #include <ch.h>   #include <ch.h>
en/arm_programming.txt · Last modified: 2013/11/08 13:05 (external edit)