RETIS Lab Real-Time Systems Laboratory FLEX Developement Environment Mauro Marinoni [nino@evidence.eu.com [ nino@evidence.eu.com] ]
Overview The Microcontroller The Flex Board Expansion boards Multibus board Demo board How to: Compile demo Flash & Run Demos
The Microcontroller The Microchip 16bit microcontrollers present: 16 bit (data) modified-harvard RISC architecture; High-performance MCU capability; Integrated DSP capability (dspic families); Separate program and data buses; Powerful peripherals on chip; Idle &Sleep modes; Switch between clock sources in real-time time; Flexible Interrupt t structure. t
dspic microcontroller Microcontrollers t basic features: 16-bit core up to 40 MIPS a 80 MHz; Integrated DSP Module; 6KB-256KB Flash Program Memory; 256B-32Kb RAM Data Memory; Up to 4 DMA channels; Up to 8 16-bit Comparators; Up to 8 PWM Generators; Upto816bit 16-bit Timers (32 bit mode).
dspic microcontroller Microcontroller I/O capabilities: Up to 86 I/O pins16 channels; A/D module with: Up to 2 A/D converters; 500KSPS@12-bit 1MSPS@10-bit Motor Control PWMs Quadrature Encoder Interface Analog l Comparators
dspic microcontroller Microcontroller Connectivity: UART ports (IRDa support) CAN bus version 2.0A/B Data D t Convert Interface (I 2 S/AC97) Parallel Master Port I 2 C / SMBus SPI bus
Why another Evaluation Board? Typically, y, demo boards are: big! limited pin counts MCU most of the pins used for LEDs, buttons, difficult to expand! poor connection with development PC FLEX: small size (7x10 cm) 100 pin dspic all pins free on connectors 2.54 pitch, no SMD expertise required! PIC18 for USB connection
FLEX: other features switching power supply resettable fuses dspic programming g from USB daughter boards (Thru Hole, CAN, SPI, Ethernet, RS232, RS485 485, RS422 422, [other coming soon] ) support fot ERIKA O.S.
FLEX: versions Full Light g
FLEX: add-on boards Available: Thru Hole Multibus (CAN, SPI, I2C, Serial, Ethernet, Konnex) DemoBoard D B d
FLEX: Multibus board 1 - Serial port 2 (RS232 / RS422 / RS485 / TP-UART) 2 - Serial port 1 (RS232 / RS422 / RS485) 3 - CAN port 1 4 - CAN port 2 5 - I2C port 6 - SPI port 7-10Mbit Ethernet 8 - RJ45 Ethernet
FLEX: Demo Board LCD 2x16 8 LED 4 buttons 3-Axis Accelerometer 2 channels DAC Temperature sensor Light sensor Infrared I/O RS232/485/422 socket
Why an embedded O.S.? It reduces the complexity of the application; It increases the reusability of the code; It simplify the SW debugging; g It reduces the time to market:...
Why a Real-Time embedded O.S.? An embedded applications typically presents a lot of interactions with the environment; That requires a management of the response time to an external event.
ERIKA Enterprise ERIKA Enterprise OSEK-like RTOS for minimal embedded systems 1-4 4KbROMf footprint t enhanced scheduling algorithms support for debug tools (Lauterbach, ICD2) RT-Druid RTOS configuration using OSEK OIL schedulability analysis integrated in eclipse.org
Erika - supported MCU Currently available as a product for: Microchip dspic Atmel AVR Altera NIOS II (with multi-core support!) Also available for: ARM7TDMI (Samsung KS32C50100, Triscend A7, ST Janus, ST STA2051) Hitachi H8 (RCX/Lego Mindstorms) Tricore 1 PPC 5xx (PPC 566EVB) C167/ST10 (Ertec EVA 167, tiny/large mem. model)
Development Chain To obtain a running demo: Hardware: FLEX Board; Microchip ICD2; Software Software: Microchip MPLab IDE; Microchip C30 compiler; Evidence Erika Enterprise.
Erika Package It contains: Cygwin Environment; Eclipse p 3.3; RT-Druid plugin; Erika Enterprise Kernel; Erika Eik support tf for Scicos code generator.
Eclipse Environment Editor Projects Output
My Demo Create from template File New RT-Druid Oil and C/C++ Project
My Demo Compile the code It uses makefile and C30 compiler executable for the target architecture. to produce the
My Demo Import and Flash in MPLab Configure Select Device Choose dspic33fj256mc710 Programmer Select Programmer MPLAB ICD2 File Import Find the pic30.cof cof inside ProjectDir/Debug Programmer Connect Programmer Program Programmer P Release from Reset
My Demo View the code in MPLab
My Demo Debug the code in MPLab Stack Pointer Run Menu BreakPoint Menu BreakPoint RAM Status
HW demos XBee, compass, ultrasound receiver er TCP/IP demo DC Motor identification
HW demos Image transfer using 802.15.4 FLEX Board ERIKA Enterprise Chipcon 2420 Transceiver CMOS Camera Microchip MAC Layer
Questions
RETIS Lab Real-Time Systems Laboratory Retis: Evidence: Scilab: Mauro Marinoni [nino@evidence.eu.com] http://retis.sssup.it http://www.evidence.eu.com http://www.scilab.org