Cortex-M + RTOS整合環境 (uC/OS II + EWARM)
Transcription
Cortex-M + RTOS整合環境 (uC/OS II + EWARM)
Cortex-M + RTOS整合環境 (uC/OS II + EWARM) 主講人: 新華電腦業務經理 黃瑞安 台北公司:台北市111承德路4段222號4F 高雄公司: 高雄市806中山二路91號9F之6 TEL:02-28811791; 07-3300818 Email: bright@microtime.com.tw WEB: http://www.microtime.com.tw 1 嵌 入 式 ARM 整 合 發 展 方 案 IAR Embedded Workbench IAR visualSTATE Design Verify, Validate, Implement Compile I-Jet JTAGjet-Trace J-link, Flasher Debug Deploy Target application Idea RTOS & Middleware Micrium uC/OS II, III, Middleware Cortex M IAR Kit, PTK 訓練, 設計 2 IAR visualSTATE – design & test tools • IAR visualSTATE • Micrium uC/OS II/III, Middleware • IAR Embedded Workbench ARM • Power optimization • KickStart Kit, PTK 3 Documentation Design by means of Graphical programming Event1() / A Event3() / Event6() / B Event4() / Event2() / C D Event5() / This TV set has been developed for a Motorola platform... Automatic test (Verification) Error if Event1 and state1 and state2 Event1() / A Event3() / B Event6() / Event4() / Event2() / C D Event5() / Manual test Event1 Event3 Event7 Event4 ... Event6() / Event1() / A Event3() / B Event4() / Event2() / C D Event5() / Prototyping on top of design Event1() / A Event6() / Event3() / B Event4() / Event2() / C D Event5() / { if (SEM.CSV [4] == 0x05) SEM.WSV [3] = 0x0F; .... } 4 RTOS & middleware - Micrium • IAR visualSTATE • Micrium uC/OS II/III, Middleware • IAR Embedded Workbench • Power optimization • KickStart Kit, PTK 5 Advantages of using an Commercial RTOS • Creates a professional product architecture • Free from implementing a scheduler/related services • Simplifies product design • Simplifies product upgrades and maintenance • Allows team development • Lowers total cost of development • Allows focus on ‘time to market’ 6 Micriµm’s Reputation #2 RTOS for new designs TechInsights 7 Micrium Competitively • An average project with Micrium software and tools costs a fraction of the industry average. • It is also clear that the savings expected when using “free” software does not make it to the bottom line. Source: Embedded Forecast 8 8 What is Source Available? ‘Source Available’ – a Micriµm Innovation Commercial Micriµ m Commercial Free-ware Source Available Robust, Supported, But ‘closed’ Robust Supported, And ‘Free for Evaluation’ Questionable quality, Limited support, But ‘open’ 9 µC/OS-II v.s. µC/OS-III 10 µC/OS-II v.s. µC/OS-III 11 Micrium ─ Product Portfolio 12 Complexity in TCP/IP TCP/IP represents a series of protocols • Standards-based (RFCs) • High performance • Built-in SSL API • Extremely Complex • 100s of thousands of lines of code! • Micriµm spent 20 man-years to develop and test TCP/IP Application layer components: • DHCP (client), DNS (client) • FTP (client and server), TFTP (client and server) • HTTP (web server), SMTP (client), POP3 (client) • SNTP (client), Telnet (server), Shell, Clock • Many others 13 Complexity in File Systems Typically based on Microsoft FAT12, 16, 32 • Highly Complex • Tens of thousands of lines of code! • Micriµm spent 4 man-years to develop and test • DOS and Windows compatible Media: • RAM-disk • SD/MMC/eMMC, microSD • CompactFlash and IDE • NOR and NAND Flash (SLC and MLC) • MSC Driver 14 Highly complex: • • • • • Tens of thousands of lines of code 20+ man years to develop and test B/W, Grayscale, Color 2D/3D Graphics Touch-screen interface uC/GUI S/W Suite Must work with: • • • • • 100s of CPUs Wide range of LCD-controllers Hundreds of controllers -> drivers Wide range of display sizes With or without an RTOS Expected features: • • • • • • GUIBuilder Dialogs, virtual screen Multiple buffering Multilayer/Multi-Display Pointer input devices Fonts, Color management 15 Complexity in USB Device Simple to use … Complex to develop • Tens of thousands of lines of code • Complex drivers • Able to run on 8-, 16-, 32- or 64-bit CPUs and DSPs • Must work with or without an RTOS • Long develop and test cycle Your Application HID Mass Storage CDC Device Stack Core Other OS Interface Drivers OS Abstraction Expected Classes: • MSD • CDC • HID • PHDC • Vendor • Other Device Controller Port Device Controller (Hardware) 16 Complexity in USB Host Simple to use … Complex to develop … Complex to test • Tens of thousands of lines of code • Complex drivers • Must run on 8-, 16-, 32- or 64-bit CPUs and DSPs • Work with or without an RTOS • Man years to develop and test Expected Classes: • MSD • CDC • HID • FTDI • Printer • Other 17 uC/Probe – Graphical Live Watch • uC/Probe graphically visualizes the internals of any embedded system effortlessly, with just a few mouse clicks. • A Windows application allows you to read/write memory of embedded target during run-time. • Absolutely no programming – simply drag and drop graphic components into place, and watch them go. • Works with wide embedded processors, e.g. via J-Link, TCP/IP, RS-232 or Proxies, etc. • To extend capabilities of debugging software by running both at the same time. 18 IAR Embedded Workbench – C/C++ compiler & debugger tools • IAR visualSTATE • Micrium uC/OS II/III, Middleware • IAR Embedded Workbench ARM • Power optimization • KickStart Kit, PTK 19 EWARM features update • Improved optimizations – V6.40 & V6.50 • Complete integration of Eclipse tool suite plug-in • Code generation for execute-only code memory systems • Allowed to invoke external static analysis tool e.g. PC-lint • I-Scope supported to measure current and voltage • uC/Probe plug-in for graphical live watch with EWARM • New license management system (LMS2) 20 ARM Core Support • • • • • • • • • • • • • Cortex A15 Cortex-A9 Cortex-A8 Cortex A7 Cortex-A5 Cortex R7 Cortex R5 Cortex-R4(F) Cortex-M4 Cortex-M3 Cortex-M1 Cortex M0+ Cortex-M0 • • • • • • • ARM7 ARM9 ARM9E ARM10 ARM11 SecurCore XScale • • • • Support for ARM, Thumb and Thumb2 processor modes Support for ARM DSP and SIMD extensions Intrinsic NEON support Generates code for ARM VFP series of floating-point coprocessors • IAR EWARM now supports more than 2,500 devices and 3,700 project examples 21 STM32 device Support • Cortex M0, M3, M4; 300+ part no. fully supported • Cover 7 product lines: 1) STM32F05X 2) STM32F10X 3) STM32F20X STM32F21X 4) STM32F30X STM32F37X 5) STM32F40X STM32F41X STM32F42X STM32F43X 6) STM32L15X 7) STM32W10X • Support levels in EWARM Core support, Header/DDF files, Flash loader, Project examples 22 What is IAR Embedded Workbench? 23 Embedded Workbench - Quick Summary • Powerful – Features comprehensive and capable tools enable you to develop new competitive products. • User friendly – Focused on embedded applications to ensure efficient development • Reliable – Proven in use with over 120,000 installed licenses worldwide • Standardize – A complete tool chain and an excellent enabler for standardization of programming of 8-, 16-, 32-bit embedded systems 24 High-performance C/C++ compiler • Optimizing C/C++ compiler • Language standards • – Pre-built and in source – Thread safe libraries for multitasking applications – C89 and C99 – C++ 2003 – CMSIS DSP Library for CortexM3/M4 – Embedded C++ – ARM EABI – CMSIS • Customizable C/C++ libraries • Automatic selection of smallest printf/scanf formatter IEEE-754 floating point representation 25 Powerful optimizations - code size benchmark 35,9% smaller 32,4% smaller ARM 33,5% smaller Thumb IAR Embeded Workbench Thumb2 GCC 26 Coremark and Speed Optimization Coremark for STM32F417: 27 Comprehensive IAR C-SPY Debugger • Integrated – • Simulator – • Extensive hardware target system support including JTAG, SWD and ETM RTOS awareness – • Built-in instruction simulator Hardware debugging – • Fully integrated debugger for source and disassembly debugging Kernel awareness plugins for debugging systems using RTOS Macro system – C like macro system extends debugger capabilities 28 Hardware debug support • Available hardware drivers: – IAR I-Jet, JTAGjet, JTAG-Trace – IAR ROM-monitor – J-Link, J-Trace, Flasher – RDI (Remote Debug Interface) – Macgraigor JTAG/OCDemon – GDB server – Jeeni EPI – mIDASLink (Analog device) – P&E Micro JTAG – SAMICE (Atmel AT91SAM) – ST-LINK JTAG probe – ST-LINK V2 – FTDI/ICDI JTAG – XDS100 – DIGI JTAG – Angel debug monitor – Nulink • • ETM Trace support – Full instruction trace – Complex start and stop triggers – IAR J-Trace probe JTAG/SWD – SWO trace – IAR J-Link and IAR J-Link Ultra – Third party probes • Images are exportable to third party debugger systems • Direct flash erase and download 29 Extensive portfolio for debug 30 Integrated RTOS Partners in EWRAM • Debugger awareness for Integrated RTOSes and other software components • Micrium • FreeRTOS • Freescale MQX • Express Logic • CMX • Micro Digital • eForce • AVIX • Sciopta • eSysTech X • SEGGER • NORTi MiSPO • Quadros • OSEK (ORTI) • Wittenstein • Unicoi Fusion 31 Power Optimization • IAR visualSTATE • Micrium uC/OS II/III, Middleware • IAR Embedded Workbench ARM • Power optimization • KickStart Kit, PTK 32 The third dimension of Optimization 33 Power debugging • Integrated measuring of power consumption correlated to source code • Enables tuning of the application to minimize power consuming use of hardware reources • Functional on all supported ARM cores • Enabled by J-link/J-link Ultra, ST-link, IAR I-Jet/JTAGjet or other hardware with power debugging support 34 What we did Debug API JTAG / SWO PCB ARM Cortex J-link or IAR I-Jet JTAG / SWO JTAG / SWO IAR Embedded Workbench ARM Power Sampling Power Power Power Power API Power on Pin19 35 Monitoring power consumption • Power profiling – Function level power profiling using statistic sampling • Power graph – Integrated in the Timeline window with interrupts and variable graphs • Power log – Detailed data for each power sample 36 IAR I-jet JTAG probe 主要特點~ 支援 ARM7/ARM9/ARM11, Cortex-A/R/M核心 • 可完全整合至 IAR Embedded Workbench • Hi-speed USB 2.0介面 (480Mbps) • 目標電源上至400Ma可由I-Jet提供,具有過載 保護 • 目標電源消耗可用200µA於200KHZ量測 • JTAG及Serial Wire Debug (SWD)時脈可至 32MHz (MCU時脈速度並未限制) • Serial Wire Viewer (SWV)具有UART及 Manchester編碼 • 支援Support for SWO速度可至60MHz • • • • • • 支援Embedded Trace Buffer (ETB) 下載速度可達1MByte/sec 支援JTAG adaptive時脈 (RTCK) 自動JTAG/SWD 偵測 提供JTAG電壓量測及監看 支援目標電壓範圍自1.65V至5V <Power debug> J-link – Sampling 10KHz, Resolution: 7mA I-Jet – Sampling 200KHz, Resolution: 200uA 37 I-Scope now shipping 38 EWARM and I-Scope 39 User friendly -- Easy workflow • WEB-based information center – • Quick get start, Tutorial, sample project… Powerful Project Manager – Multiple projects within the same workspace • Edit-while-debug – Edit source files without leaving the debug session and set breakpoints while editing the code before starting the debugger • Pre-integrated and fully tested – Provide integration wide range of partners, e.g. silicon vendors, real time operating systems and middleware vendors. Starter kits to enable to start development. 40 Eclipse build chain plugin • Eclipse IDE fully integration for IAR Compiler & Debugger • Build chain – IAR C/C++ compiler – IAR Assembler – IAR ILINK Linker • C and C++ Libraries • Parsing of error massages • Options settings from Eclipse 41 Reliable -- Proven in use • Over 120,000 licenses shipped – A common technology platform for all products ensures maximum exposure of the code base • 30 years experience of developing and providing customers with tools – Experiences made are incorporated in the desgin of new products • Use in safety critical applications – IAR Embedded Workbench is used in projects with special requirements on tool testing and conformance – MISRA checker, Function safety 42 Certified for Functional Safety 43 Embedded Standardization Our customers require a simplified, seamless development workflow, more flexibility in their development process, and reliable support at hand when and where they need it. 44 KickStart a project • Templates – • IAR KickStart Kits Ready-made templates for C/C++ and assembler projects • Examples – 3,700 example projects for various ARM devices and evaluation boards • Tutorials – Tutorials guiding through all project stages 45 System solution platform - PTK • • From Tool solution to Application solution What’s the offer of PTK? – Modular design, e.g. STM32F207/407 – Offer an basic solution Platform by EVB, RTOS(uC/OS), Middleware(uC/FS, uC/USB, uC/TCP/IP), visualSTATE, EWARM-EV, J-link-lite – Application areas: Gaming, IoT, BioMedical, Industrial control, Automotive…, etc 46 技術訓練課程、整合設計服務 47 Thank you! 48