GHI EMX User Manual

G H I E l e c t r o n i c s
EMX User Manual
Rev.1.3 September 23, 2011 User Manual
EMX Module Top EMX Module Bottom
Document Information
Information Description
Abstract This document covers information about the EMX Module,
specifications, tutorials and references.
Rev.1.3 Page 2 of 52 www.ghielectronics.com
Revision History
Date Modification
09/21/11 Changed WiFi module information and various updates
03/10/11 Various updates
09/14/10 Updated In-field update section
08/03/10 Updated power functions
07/21/10 Updated information for NETMF 4.1
04/28/10 Pin-out table updated
04/26/10 Updated network section
04/02/10 Updates / Fixes
03/05/10 First full version
03/02/10 Preliminary document
GHI Electronics,LLC EMX User Manual
Table of Contents
Table of Contents
1.Introduction...................................................................................4
1.1.What is Microsoft .NET Micro Framework (NETMF)?.........4
1.2.NETMF - Porting vs. Using..................................................4
1.3.GHI's .NET Micro Framework Based Solutions..................5
1.4.What is EMX Module?.........................................................5
1.5.Extended Features with EMX Module.................................6
1.6.EMX Module Key Features.................................................6
1.7.Example Applications..........................................................6
2.EMX Development System...........................................................7
3.EMX Module Architecture H/W & S/W..........................................9
3.1.Block Diagram.....................................................................9
3.2.LPC2478 Microcontroller...................................................10
3.3.SDRAM..............................................................................10
3.4.FLASH...............................................................................10
3.5.Ethernet PHY.....................................................................10
3.6.Runtime Loadable Procedure (RLP).................................10
4.Pin-Out Description.....................................................................11
4.1.EMX Module Pin-out Table................................................12
5.EMX on boot up..........................................................................15
5.1.GHI Boot Loader vs. TinyBooter vs. EMX Firmware.........17
5.2.EMX Access Interface.......................................................18
Emergency GHI Boot Loader Access...............................18
Other Interfaces.................................................................18
6.GHI Boot Loader.........................................................................19
6.1.GHI Boot Loader Commands............................................19
6.2.TinyBooter Update through GHI Boot Loader...................19
7.TinyBooter...................................................................................22
7.1.EMX Firmware Update Through TinyBooter.....................22
8.EMX firmware..............................................................................26
8.1.Getting Started with EMX..................................................26
All you need to start up.....................................................26
First Power-up...................................................................27
Adding GHI NETMF Library..............................................30
8.2.EMX Emulator...................................................................33
9.EMX Module Features................................................................34
9.1.Application Flash/RAM/EWR.............................................34
Extended Week References (EWR).................................34
9.2.Debugging Interface (Access Interface)............................34
9.3.Digital Inputs/Outputs........................................................36
9.4.Serial Peripherals..............................................................36
Serial Port (UART)............................................................36
SPI.....................................................................................36
I2C.....................................................................................37
CAN...................................................................................37
One-wire............................................................................37
9.5.Networking (TCP/IP)..........................................................37
MAC address setting.........................................................37
IP address (DHCP or static):.............................................38
Ethernet.............................................................................38
Wireless LAN WiFi (IEEE 802.11b)...................................39
PPP (TCP/IP access through serial modems)..................40
SSL....................................................................................40
9.6.Graphics............................................................................40
9.7.Touch Screen Control........................................................41
9.8.USB Client (Device) ..........................................................41
USB cable connection detection.......................................43
9.9.USB Host and Supported Class Drivers...........................43
9.10.Storage Devices (SD, USB MS) / File System................43
SD/MMC Memory..............................................................43
USB Mass Storage............................................................44
9.11.Analog Inputs/Outputs.....................................................44
9.12.PWM................................................................................44
9.13.Output Compare..............................................................44
9.14.Battery RAM....................................................................45
9.15.Power Control / Hibernate...............................................45
Power Control....................................................................45
Hibernate...........................................................................45
9.16.Real Time Clock..............................................................45
9.17.Processor Register Access.............................................45
9.18.In-Field Update................................................................45
9.19.Managed Application Protection......................................46
9.20.Runtime Loadable Procedure RLP.................................46
9.21.Watchdog.........................................................................46
10.Advanced Users........................................................................47
11.EMX design Consideration........................................................47
11.1.Hardware.........................................................................47
11.2.Software...........................................................................47
11.3.EMX Placement...............................................................48
Machine Placement...........................................................49
Appendix A: MFDeploy Tool...........................................................50
Legal Notice...................................................................................51
Licensing..................................................................................51
Disclaimer................................................................................51
Rev.1.3 Page 3 of 52 www.ghielectronics.com
Introduction

1. Introduction

1.1. What is Microsoft .NET Micro Framework (NETMF)?

Microsoft's .NET Micro Framework is a lightweight implementation of the .NET Framework. It focuses on the specific requirements of resource-constrained embedded systems. Supporting development in C# and debugging on an emulator or the device, both using Microsoft's Visual Studio. The .NET Micro Framework is also open source, released under the Apache 2.0 license and completely free.
Developers already experienced with .NET and Visual Studio can take advantage of their skills immediately reducing the learning curve. The actual C# application development process is completely shielded from the low-level design details of the hardware platform. Combining the benefits with off-the-shelf, low-cost, network-enabled embedded systems creates a rapid product development solution.

1.2. NETMF - Porting vs. Using

There are two sides to working with NETMF, porting it and using it. For example, writing a JAVA game on a cell phone is much easier than porting the JAVA virtual machine (JVM) to the phone. The phone manufacturer did all the hard work of porting JAVA to their phone allowing the game programmers to use it with ease. NETMF works the same way, porting is not easy but using it is effortless.
NETMF can be split into two major components, the core (CLR – Common Language Runtime) and HAL (Hardware Access Layer). The core libraries are made so they are hardware independent. Usually, no modifications are needed on the core libraries. A developer porting NETMF for a hardware platform will need to make the HAL to handle interfacing the hardware control to upper layers.
According to GHI's own experience with NETMF porting, it is not feasible to work on porting NETMF to your new hardware in case you are targeting medium or low quantities annually (less than 100,000 units). A faster-to-market option is by using one of the available OEM modules/chipsets. These OEM devices have everything you need built in the hardware and software.
Rev.1.3 Page 4 of 52 www.ghielectronics.com
Introduction

1.3. GHI's .NET Micro Framework Based Solutions

With GHI Electronics, you're getting an experienced partner that offers a wide range of .NET Micro Framework hardware and software capabilities using the various drop-in modules/chipsets such as ChipworkX, Embedded Master, EMX and USBizi. In addition, our free unlimited support is available to assist you at any point. New features and fixes come seamlessly to your product at no cost to you.
On top of the great features that the .NET Micro Framework provides, such as Ethernet, graphics and touch screen, GHI solutions has additional exclusive features such as USB host, PPP (GPRS/3G), database and native code runtime libraries (RLP). All these exclusive features are included for you at no extra cost.

1.4. What is EMX Module?

The EMX Module is a combination of hardware (ARM Processor, Flash, RAM, Ethernet PHY...etc) on a very small (1.55”x1.8”) SMT OEM 8-Layer board that hosts Microsoft's .NET Micro Framework with various PAL/HAL drivers. In addition to the benefits of the .NET Micro Framework, EMX includes exclusive software and hardware features, such as support for USB host, PPP networking and more.
The EMX Module is a vastly sophisticated piece of hardware. This complexity provides the end-user with a remarkably simple platform to implement in any hardware design. Looking at the EMX Development System schematic shows just how simple it really is. All you need is 3.3 volts and some connections to bring the latest technologies to your products. With manageable features
Rev.1.3 Page 5 of 52 www.ghielectronics.com
Introduction
like USB host and WiFi, the possibilities are boundless.

1.5. Extended Features with EMX Module

EMX supports a complete set of .NET Micro Framework features such as TCP/IP, SSL, FAT, USB device and more. Including support for other exclusive GHI features such as full USB host stack, CAN, ADC, DAC,PPP, GPRS, 3G, etc. EMX also allows developers to load their own compiled native code. EMX includes protection against firmware or user application piracy.

1.6. EMX Module Key Features

.NET Micro Framework
72Mhz 32Bit Processor
16MB RAM
4.5MB FLASH
Embedded LCD controller
Embedded Ethernet PHY with fast
DMA communication.
Runtime Loadable Procedure
Full TCP/IP Stack
Web Services
SSL
ZG2100 WiFi Driver
PPP ( GPRS/ 3G )
DPWS
Embedded USB host/device
76 GPIO Pins
39 Interrupt Inputs
2 SPI (8/16bit)
I2C
4 UART
2 CAN Channels
7 10Bit Analog Inputs.
10Bit Analog Output
4Bit SD/MMC Memory card interface
6 PWM
160 mA current consumption with
everything enabled
40mA Hibernate Mode
-40ºC to +85ºC Operational
RoHS Lead Free

1.7. Example Applications

Designs with intensive processing or time-critical routines (using RLP)
Vending machine
Measurement tool or tester
Network server device
Robotics
GPS navigation
Medical instrument (with a color touch screen display).
Central alarm system
Smart appliances
Industrial automation devices
Windows SideShow devices
Rev.1.3 Page 6 of 52 www.ghielectronics.com
EMX Development System

2. EMX Development System

The EMX Development System is the official kit from GHI Electronics for the EMX module. This kit exposes the various peripherals and interfaces that make it an ideal starting point for any .NET Micro Framework project. Furthermore, most of the EMX module signals such as GPIO, SPI and UART are accessible on a 0.1" header for rapid prototyping.
The EMX Development System Brochure and Pin-outs Document provides for a more detailed view of this system.
Front View
Rev.1.3 Page 7 of 52 www.ghielectronics.com
RJ45
Ethernet
USB Host
USB Client
JTAG
(Disabled by Default)
XBee
Socket
Power
Indicator
LED
RTC
Battery
Power
Connector
6Volts
Two
Programmable
LEDs
3.5 TFT Display
With Touch Screen
SD/MMC
Connector
LCD
Header
JP2 Header
Buttons Pad
RS232 D-SUB
UEXT
Reset
CAN
D-SUB
RS232
D-SUB
Two
Programmable
LEDs
CAN
D-SUB
XBee
Socket
JP2 Header
UEXT
Power
Indicator
LED
Power
Connector
6Volts
USB Host
LCD
Header
3.5” TFT Display
With Touch Screen
USB Client
RJ45
Ethernet
JTAG
(Disabled by Default)
RTC
Battery
Reset
SD/MMC
Connector
Buttons Pad
EMX Development System
Back View
Rev.1.3 Page 8 of 52 www.ghielectronics.com
RS232
converter
CAN Physical
Layer Chip
EMX Module
Display
Back Light
Circuit
Display
Back Light
EMX Module
Circuit
RS232
converter
CAN Physical
Layer Chip
EMX Module Architecture H/W & S/W

3. EMX Module Architecture H/W & S/W

The EMX Module is a combination of hardware (ARM Processor, Flash, RAM, Ethernet PHY...etc) that hosts Microsoft's .NET Micro Framework with various PAL/HAL drivers. In addition to the benefits of the .NET Micro Framework, EMX includes exclusive software and hardware features, such as support for USB host, PPP networking and more.
The small 1.55"x1.8" module contains everything needed to run the .NET Micro Framework. We also designed the module to be incredibly flexible while keeping costs low. Applications ranging from simple data loggers to high-end security systems and industrial controls can be created. The module is a sophisticated piece of hardware developed with a complex 8-layer BGA design. This complexity provides the end-user with a remarkably simple platform to implement in any hardware design. Looking at the EMX Development System schematic shows just how simple it really is. All you need is 3.3 volts and some connections to bring the latest technologies to your products.

3.1. Block Diagram

Rev.1.3 Page 9 of 52 www.ghielectronics.com
.NET Micro Framework
CLR
PAL
.NET and GHI
Managed Library
16 MB SDRAM
User Runtime Loadable
Procedure (compiled C or
assembly) region
GHI RLP
loader
HAL
EMX Module
Hardware
User Managed
Code
4.5MB Flash
GHI Extended features:
USB Drivers, Hardware Access
LPC2478 72 MHz ARM7
Peripherals:
Digital IOs, Interrupts,
PWM, A/D,
USB HC, USB Device,
MCI,LCD Controller,
Ethernet Controller ...etc
10/100
Ethernet PHY
EMX Module Architecture H/W & S/W

3.2. LPC2478 Microcontroller

The LPC2478 72Mhz ARM7 32Bit processor is the core of the EMX Module. The LPC2478 contains a memory acceleration interface with 128Bit internal FLASH memory. This lets the processor core run with zero wait states. Comparing to executing code from 16Bit external FLASH we see over 10 times the execution speed. The internal FLASH is 0.5MB that is used to run the complete .NET Micro Framework core very efficiently. Also, the processor includes an RTC that can operate while while the processor is off. The EMX Module already has the needed circuitry to run the RTC. Users only need to add a battery or a super capacitor to VBAT pin.
Further more, the LPC2478 has a wide range of peripherals that adds a lot of functions and features to EMX such as PWM, GPIO, LCD Controller, USB HC, etc.

3.3. SDRAM

16MB of SDRAM comes standard with EMX Module.

3.4. FLASH

4MB of external flash is available on EMX Modules. This doesn't include the 0.5MB internal flash used for Micro Framework CLR execution. External flash is used for system assemblies, boot loader, user deployment and EWR storage. About 1MB of the external FLASH is used for boot loader, system assemblies and other internal GHI resources. About 3MB is reserved for deployed managed applications, including resources. 256KB is reserved for two EWR (Extended Week References) regions, each region being 128KB and one of them is reserved for CLR use.

3.5. Ethernet PHY

The EMX Module hardware includes an industrial Ethernet PHY along with the needed circuitry. The Ethernet oscillator is controlled by the processor allowing the user to control it's power consumption. The designer only needs to wire the signals to the Ethernet connector. The recommended Ethernet connector is J0011D01BNL.

3.6. Runtime Loadable Procedure (RLP)

A highly useful and unique feature in EMX is allowing users to load their own compiled native code (C or assembly) and run it directly through managed code. This feature is similar to the use of DLLs on PCs. RLP can be used to implement processing intensive and time-critical routines.
Rev.1.3 Page 10 of 52 www.ghielectronics.com
Pin-Out Description

4. Pin-Out Description

The LPC2478 72Mhz ARM7 32Bit processor is the core of EMX. The processor has a wide range of peripherals that add a lot of functions and features to EMX such as PWM, GPIO, USB HC, LCD Controller, etc.
Most signals on EMX are multiplexed to offer more than one function for every pin. It is up to the developer to select which one of the functions to use. GHI drivers and .NET Micro Framework does checking to make sure the user is not trying to use two functions on the same pin. The developer should still understand what functions are multiplexed so there is no conflict. For example, analog channel 3 (ADC3) and the analog output (AOUT) are on the same pin IO7. Either function can be used but not both of them simultaneously. See the Advanced Users section for more details.
The schematics of EMX Development System board should be used as a reference
design.
Advanced details on oscillator and power tolerance can be found in the LPC2478
datasheet from NXP website.
Digital I/O pins are named IOxx, where xx is an assigned number.
Rev.1.3 Page 11 of 52 www.ghielectronics.com
Pin-Out Description

4.1. EMX Module Pin-out Table

EMX Module is based on LPC2478 from NXP.
Name
No. LPC2478
H/W Name
EMX IO 2
nd
Feature EMX Module
Pin Description
1 3.3V Connect to 3.3 volt source.
2 GND Connect to Ground.
3 P0.4 IO0* CAN2/
Down Button
RD CAN Channel 2 Data Receive pin (In) and TinyBooter/Firmware Down Button (Check hardware design consideration).
4 P0.5 IO1* CAN2 TD CAN Channel 2 Data Transmit pin (Out).
5 P0.3 IO2 * COM1 Serial port (UART) RXD receive signal (In) for COM1.
6 P0.2 IO3* COM1 Serial port (UART) TXD transmit signal (Out) for COM1.
7 P2.5 IO4* UP Button General purpose digital I/O
and TinyBooter/Firmware Up Button (Check hardware design consideration).
8 P0.24 IO5* ADC1/
Touch_Y_UP
ADC1 (10Bit Analog to Digital Input) or Touch Screen Y-axis Up analog signal.
9 P0.25 IO6* ADC2/
COM4
ADC2 (10Bit Analog to Digital Input) or Serial port (UART) TXD transmit signal (Out) for COM4.
10 P0.26 IO7* ADC3/ DAC/
COM4
ADC3 (10Bit Analog to Digital Input) or DAC (Digital to Analog Output) or Serial port (UART) RXD receive signal (In) for COM4.
11 P0.23 IO8* ADC0/
Touch_X_Left
ADC0 (10Bit Analog to Digital Input) or Touch Screen X-axis Left analog signal.
12 P4.29 IO9 N/A General purpose digital I/O
13 P4.28 IO10 Piezo Piezo hardware control.
14 P0.28 IO11* I2C (open drain pin) I2C Interface SCL
15 P0.27 IO12* I2C (open drain pin) I2C Interface SDA
16 P3.16 IO13 PWM0 PWM0 (Pulse Width Modulation Output) LPC2478 PWM Timer 0.
17 P3.24 IO14 PWM1 PWM1 (Pulse Width Modulation Output) LPC2478 PWM Timer 1.
18 P3.25 IO15 N/A General purpose digital I/O
19 P1.19 IO16 N/A General purpose digital I/O
20 P2.21 IO17* N/A General purpose digital I/O
21 P0.11 IO18* N/A General purpose digital I/O
22 P2.22 IO19* N/A General purpose digital I/O
23 P0.1 IO20* CAN1 TD CAN Channel 1 Data Transmit pin (Out)
24 P0.10 IO21* N/A General purpose digital I/O.
25 P0.0 IO22* CAN1 RD CAN Channel 1 Data Receive pin (In)
26 P1.30 N/A USB_VBUS1USB device power detect signal. Connect to power pin on USB device.
27 P2.10 IO23* N/A General purpose digital I/O
28 RTC_VBAT Connect to 3.3 volt backup battery to keep the real-time clock running.
29 USBD- USB Host Feature USB negative data line of the USB hosting feature.
30 USBD+ USB Host Feature USB positive data line of the USB hosting feature.
31 P0.12 IO45* ADC6 ADC6 (10Bit Analog to Digital Input).
32 P0.13 IO46* ADC7 ADC7 (10Bit Analog to Digital Input).
33 P1.31 IO47 ADC5 ADC5 (10Bit Analog to Digital Input).
34 3.3V Connect to 3.3 volt source.
35 P3.27 IO48 PWM4 PWM4 (Pulse Width Modulation Output) LPC2478 PWM Timer 1.
36 GND Connect to Ground.
37 3.3V Connect to 3.3 volt source.
38 N/C Not Connected.
Rev.1.3 Page 12 of 52 www.ghielectronics.com
Pin-Out Description
Name
No. LPC2478
H/W Name
EMX IO 2
nd
Feature EMX Module
Pin Description
39 P3.26 IO49 PWM3 PWM3 (Pulse Width Modulation Output) LPC2478 PWM Timer 1.
40 P3.17 IO50 PWM2 PWM2 (Pulse Width Modulation Output) LPC2478 PWM Timer 0.
41 USBD- device USB negative data line of the USB debugging interface and for the USB client feature.
42 USBD+ device USB positive data line of the USB debugging interface and for the USB client feature.
43 Ethernet RD- Ethernet receive data minus.
Recommended Ethernet connector is
J0011D01BNL.
Ethernet PHY is not needed since it is
embedded in EMX hardware.
44 Ethernet RD+ Ethernet receive data plus.
45 Ethernet TD- Ethernet transmit data minus.
46 Ethernet TD+ Ethernet transmit data plus.
47 P0.18 IO24* SPI1 SPI master bus interface MOSI signal (Master Out Slave In) for SPI1.
48 P0.17 IO25* SPI1 SPI master bus interface MISO signal (Master In Slave Out) for SPI1.
49 P0.16 IO26* N/A General purpose digital I/O.
50 P0.15 IO27* SPI1 SPI master bus interface SCK signal (Clock)for SPI1.
51 P4.23 IO28 COM3 Serial port (UART) RXD receive signal (In) for COM3.
52 P4.22 IO29 COM3 Serial port (UART) TXD transmit signal (Out) for COM3.
53 P2.11 IO30* Select Button General purpose digital I/O
and TinyBooter/Firmware Select Button (Check hardware design consideration).
54 P3.30 IO31 COM2 Serial port (UART) RTS hardware handshaking signal for COM2.
55 P2.1 IO32* COM2 Serial port (UART) RXD receive signal (IN) for COM2.
56 P0.6 IO33* N/A General purpose digital I/O.
57 P3.18 IO34 COM2 Serial port (UART) CTS hardware handshaking signal for COM2.
58 P0.7 IO35* SPI2 SPI master bus interface SCK signal (Clock)for SPI2.
59 P0.9 IO36* SPI2 SPI master bus interface MOSI signal (Master Out Slave In) for SPI2.
60 P2.0 IO37* COM2 Serial port (UART) TXD transmit signal (Out) for COM2.
61 P0.8 IO38* SPI2 SPI master bus interface MISO signal (Master In Slave Out) for SPI2.
62 P1.12 IO39 SD_DAT3 SD card 4Bit data bus, data line no. 3.
63 P1.11 IO40 SD_DAT2 SD card 4Bit data bus, data line no. 2.
64 P1.7 IO41 SD_DAT1 SD card 4Bit data bus, data line no. 1.
65 P1.2 IO42 SD_CLK SD card 4Bit data bus, clock line.
66 P1.6 IO43 SD_DAT0 SD card 4Bit data bus, data line no. 0.
67 P1.3 IO44 SD_CMD SD card 4Bit data bus, command line.
68 SD_PWR SD memory power (connect directly to SD socket power pin).
69 GND Connect to Ground.
70 RESET# Hardware reset signal, Reset state is on Low.
T1 P2.12 IO69* LCD R0 TFT Display, Red signal bit 0.
T2 P2.6 IO65* LCD R1 TFT Display, Red signal bit 1.
T3 P2.7 IO66* LCD R2 TFT Display, Red signal bit 2.
T4 P2.8 IO67* LCD R3 TFT Display, Red signal bit 3.
T5 P2.9 IO68* LCD R4 TFT Display, Red signal bit 4.
T6 P1.20 IO51 LCD G0 TFT Display, Green signal bit 0.
T7 P1.21 IO52 LCD G1 TFT Display, Green signal bit 1.
T8 P1.22 IO53 LCD G2 TFT Display, Green signal bit 2.
T9 P1.23 IO54 LCD G3 TFT Display, Green signal bit 3.
T10 P1.24 IO55 LCD G4 TFT Display, Green signal bit 4.
T11 P1.25 IO56 LCD G5 TFT Display, Green signal bit 5.
T12 P2.13 IO70* LCD B0 TFT Display, Blue signal bit 0.
T13 P1.26 IO57 LCD B1 TFT Display, Blue signal bit 1.
T14 P1.27 IO58 LCD B2 TFT Display, Blue signal bit 2.
Rev.1.3 Page 13 of 52 www.ghielectronics.com
Pin-Out Description
Name
No. LPC2478
H/W Name
EMX IO 2
nd
Feature EMX Module
Pin Description
T15 P1.28 IO59 LCD B3 TFT Display, Blue signal bit 3.
T16 P1.29 IO60 LCD B4 TFT Display, Blue signal bit 4.
T17 P2.2 IO61* LCD CLK TFT Display, Clock.
T18 P2.4 IO63* LCD EN TFT Display, Enable.
T19 P2.5 IO64* LCD
H-Sync
TFT Display, Horizontal sync.
T20 P2.3 IO62* LCD
V-Sync
TFT Display, Vertical sync.
J1 ALARM The alarm pin is an RTC controlled output. This is a 1.8 V pin.
J2 P3.23 IO71 LMODE General purpose digital I/O is used to choose the access interface for EMX between
USB (Low) or COM1(High or not connected) on startup (refer to EMX access interface section).
J3 P2.23 IO72* T_X_Right Touch Screen X-axis Right digital output signal.
J4 P3.31 IO73 T_Y_Down Touch Screen Y-axis Down digital output signal.
J5 P3.29 IO74 PWM5 PWM5 (Pulse Width Modulation Output) LPC2478 PWM Timer 1 .
J6 P4.31 IO75 N/A General purpose digital I/O
J7 JTAG TMS JTAG TMS signal.
J8 JTAG TCK JTAG TCK signal.
J9 JTAG TDO JTAG TDO signal.
J10 JTAG TRST JTAG TRST signal.
J11 JTAG RTCK JTAG RTCK signal.
J12 JTAG TDI JTAG TDI signal.
J13 Ethernet Speed Connect to Ethernet Connector Speed LED.
High = 100 Mbps Low = 10 Mbps
J14 Ethernet Link Connect to Ethernet Connector Link LED.
High = Ethernet activity.
J15 GND Connect to Ground.
* Interrupt capable input.
Rev.1.3 Page 14 of 52 www.ghielectronics.com
EMX on boot up

5. EMX On Boot Up

EMX includes three pieces of embedded software: the GHI boot loader, TinyBooter and EMX firmware.
On system boot up, the GHI boot loader initializes Flash and RAM memory then it looks for a valid TinyBooter and lets it execute from RAM. After the TinyBooter takes over the hardware, it prepares the resources to be handled by the EMX firmware. The EMX firmware is the main software that runs the .NET Micro Framework core and the user managed application.
During boot-up, a user can interrupt the sequence to remain in boot loader, TinyBooter, or firmware by changing the state of the following signals on start-up:
Pin 7 Pin 3 Pin 53 Description
Up Button
signal
Down Button
signal
Select Button
signal
High or
unconnected
High or
unconnected
High or
unconnected
This indicates the user has no interference on boot up process, and the system will boot in normal mode sequence.
Low Low Low Hold the system in the GHI boot loader mode access
Low Low High or
unconnected
Hold the system in the TinyBooter mode access
These pins are exposed on the EMX Development System to Up, Down and Select buttons with a high default state. In other words, the pin is low when the button is pressed.
The following flow chart clearly explains the boot up sequence:
Rev.1.3 Page 15 of 52 www.ghielectronics.com
EMX on boot up
Rev.1.3 Page 16 of 52 www.ghielectronics.com
Application program exits
Execute application program
Valid application code?
Access EMX firmware
Valid EMX firmware
(TinyCLR?)
Access TinyBooter
Valid TinyBooter?
Access GHI Boot Loader
Are Up and Down
button signals low?
(pressed?)
EMX Boot-Up Sequence
Flow Chart
No
No
Yes
No
Are Up, Down and
Select Button signals low?
(pressed?)
Yes
Stay in EMX firmware and wait
for an action through Visual C# or
MFDeploy tool
e.g. Deploy and debug a new
program.
Stay in TinyBooter and wait
for an action through MFDeploy
tool e.g. Update EMX firmware.
Wait for GHI boot loader commands through terminal service program (Tera Term)
e.g. Update TinyBooter
System Power Up
Loading...
+ 36 hidden pages