Moxa ioPAC 5542-C-T — компиляция C приложений с использованием кросс-компилятора [49/52]
Превью страниц
Страница 49 /
52
![Moxa ioPAC 5542-IEC-T [49/52] Iopac rtu software rtu programming](/views2/1201435/page49/bg31.png)
ioPAC RTU Software RTU Programming
6-3
Compilation for Applications
To compile a simple C application, use the cross compiler instead of the regular compiler:
#arm-linux-gcc –o example –Wall –g –O2 example.c
#arm-linux-strip –s example
#arm-linux-gcc -ggdb –o example-debug example.c
Most of the cross compiler tools are the same as their native compiler counterparts, but have an additional
prefix that specifies the target system. In the case of x86 environments, the prefix is i386-linux-. In the case
of the ioPAC RTU controller, the prefix is arm-linux-.
For example, the native C compiler is gcc and the cross C compiler for ARM in the ioPAC is arm-linux-gcc.
Moxa provides cross compiler tools for the following native compilers. Simply add the arm-linux- prefix.
ar Manages archives (static libraries)
as Assembler
c++, g++ C++ compiler
cpp C preprocessor
gcc C compiler
gdb Debugger
ld Linker
nm Lists symbols from object files
objcopy Copies and translates object files
objdump
Displays information about object files
ranlib Generates indexes to archives (static libraries)
readelf Displays information about ELF files
size Lists object file section sizes
strings Prints strings of printable characters from files (usually object files)
strip Removes symbols and sections from object files (usually debugging information)
Содержание
150- Www moxa com product
- Iopac rtu software user s manual
- First edition july 2013
- Www moxa com support
- Trademarks
- Technical support contact information
- Iopac rtu software user s manual
- Disclaimer
- Copyright notice
- Table of contents
- Introduction
- Supported products
- Software architecture
- Related documents
- Overview
- Iopac rtu software introduction
- Journaling flash file system jffs2
- Iopac rtu software introduction
- Software package
- Iopac rtu software introduction
- Getting started
- Modifying network settings with the serial console
- Iopac rtu software getting started
- Hardware and software requirements
- Development procedure
- Developing the first program
- Configuring the ethernet interface
- Modifying network settings over the network
- Iopac rtu software getting started
- Connect an rtu to a linux pc
- Install the toolchain onto the pc
- Develop code compile the program
- Set cross compiler glibc environment variables
- Root localhost telnet 192 68 27 54 trying 192 68 27 54 connected to 192 68 27 54 escape character is moxa login
- Root localhost telnet 192 68 27 54
- Root localhost path usr local arm linux bin path
- Root localhost mount dev cdrom mnt cdrom root localhost sh mnt cdrom software toolchain arm linux_vx x sh
- Root localhost cd tmp root localhost tmp mkdir example root localhost tmp cp r mnt cdrom software sample hello_world tmp example
- Root localhost cd tmp example hello_world root localhost tmp example hello_world make
- Iopac rtu software getting started
- Upload run the program
- Root moxa home chmod x hello_world root moxa home hello_world
- Root moxa df h
- Root localhost tmp example hello_world make usr local arm linux bin arm linux gcc i usr local arm linux include i usr local arm linux include rtu o hello_world hello_world o l usr local arm linux lib lpthread lmxml l usr local arm linux lib rtu lmoxa_rtu lrtu_common ltag wl rpath lib rtu wl allow shlib undefined
- Root localhost tmp example hello_world ftp 192 68 27 54
- Root localhost telnet 192 68 27 54
- Put hello_world
- Iopac rtu software getting started
- Rtu management
- Upgrading the firmware
- System information
- Iopac rtu software rtu management
- Firmware upgrade and default settings
- Attention
- Iopac rtu software rtu management
- Recovering the firmware
- Iopac rtu software rtu management
- Loading factory defaults
- Iopac rtu software rtu management
- Enabling and disabling daemons
- Iopac rtu software rtu management
- Run level settings
- Iopac rtu software rtu management
- Iopac rtu software rtu management
- System time setting
- Setting the time manually
- Updating the time with ntp client
- Updating the time automatically
- Iopac rtu software rtu management
- Ntp server setting
- Iopac rtu software rtu management
- Executing scheduled commands with cron daemon
- Software lock
- Iopac rtu software rtu management
- Rtu communications
- Modbus tcp master and slave
- Iopac rtu software rtu communications
- Internet configuration
- Enabling the telnet ftp server
- Disabling the telnet ftp server
- Telnet ftp
- Iptables
- Iopac rtu software rtu communications
- Iopac rtu software rtu communications
- Observe and erase chain rules
- Iopac rtu software rtu communications
- Examples
- Iopac rtu software rtu communications
- Examples
- Define policy for chain rules
- Append or delete rules
- Nat snat
- Iopac rtu software rtu communications
- Iopac rtu software rtu communications
- Enabling nat at bootup
- Iopac rtu software rtu communications
- Ppp dial up service
- Port forwarding dnat
- Iopac rtu software rtu communications
- Example 1 connecting to a ppp server over a simple dial up connection
- Iopac rtu software rtu communications
- How to check the connection
- Example 2 connecting to a ppp server over a hard wired link
- Setting up a machine for incoming ppp connections
- Iopac rtu software rtu communications
- Iopac rtu software rtu communications
- Setting up the iopac rtu controller as an nfs client
- Sending mail
- Openvpn
- Nfs network file system client
- Iopac rtu software rtu communications
- Example
- Setup 1 ethernet bridging for private networks on different subnets
- Iopac rtu software rtu communications
- Setup 2 ethernet bridging for private networks on the same subnet
- Iopac rtu software rtu communications
- Setup 3 routed ip
- Iopac rtu software rtu communications
- Ntp server client
- Iopac rtu software rtu communications
- Serial configuration
- Port trunking
- Modbus rtu master
- Iopac rtu software rtu communications
- Rtu data acquisition
- I o data access
- Battery backup sram
- Active opc server
- Millisecond timestamp
- Iopac rtu software rtu data acquisition
- Rtu programming
- Using c c
- Steps for installing the linux toolchain
- Programming guide
- Memory usage
- Linux toolchain
- Iopac rtu software rtu programming
- Iopac rtu software rtu programming
- Compilation for applications
- On line debugging with gdb
- Library and apis
- Iopac rtu software rtu programming
- Editor
- A system commands
- System commands
- File manager
- Process
- Network
- Moxa special utilities
- Iopac rtu software system commands
Похожие устройства
-
Moxa ioPAC 5542-HSPA-IEC-TТехнические характеристики -
Moxa ioPAC 5542-HSPA-IEC-TРуководство по аппаратной части -
Moxa ioPAC 5542-HSPA-IEC-TИнструкция по эксплуатации -
Moxa ioPAC 5542-IEC-TТехнические характеристики -
Moxa ioPAC 5542-IEC-TРуководство по аппаратной части -
Moxa ioPAC 5542-IEC-TИнструкция по эксплуатации -
Moxa ioPAC 5542-HSPA-C-TРуководство по аппаратной части -
Moxa ioPAC 5542-HSPA-C-TТехнические характеристики -
Moxa ioPAC 5542-HSPA-C-TИнструкция по эксплуатации -
Moxa ioPAC 5542-C-TРуководство по аппаратной части -
Moxa ioPAC 5542-C-TТехнические характеристики -
Moxa 85M-5401-TТехнические характеристики
Узнайте, как компилировать простые C приложения с помощью кросс-компилятора для ARM. Подробные инструкции и команды для успешной сборки программ.