*** 1 - Anviz Global

Download Report

Transcript *** 1 - Anviz Global

Anviz Online Training Lesson 5:SDK
Anviz Overseas Technical Support Team
Copyright © 2001-2013 Anviz Global Inc. USA
Training
5th/Sep/2013
Embedded System
What is Embedded System?
An embedded system is a computer system with a
dedicated function within a larger mechanical or electrical
system.It is embedded hardware and mechanical parts.
Embedded system contains processing cores that are
either microcontrollers or digital signal processors (DSP).
ADSL modem router
1. Telephone Decoupling Electronics
10. Power Connector
2. Multi Color LED
11. Reset Button
3. Single Color LED
12. Quartz Crystal
4. Main Processor
13. Ethernet Port
5. JTAG Test and Programming Port
14. Ethernet Transformer
6. RAM
15. Ethernet PHY Transmitter/Receiver
7. Flash Memory
16. USB Port
8. Power Supply Regulator
17. Telephone Port
9. Main Power Supply Fuse
18. Telephone Connector Fuses
Mainboard
VF30
Various kinds of devices belonging to Embedded System
are commonly found in consumer, cooking, industrial,
automotive, medical, commercial and military applications.
Communication Structure
Interface Type:
Serial
USB
Ethernet
 Device:
Device
Display
User
Data
Firmware
Protocol
Packet
SDK
User
Data
 PC:
Hardware
Interface
Protocol
Packet
Device
Interface
SDK
What is SDK?
SDK is abbreviation of Software Development Kit,which is
also typical a set of software development tool for:
Creating Applications for Software Package
Software Framework
Operating System/Video Game Console
General Files
• API for Compilation
Common Tool
• Debugging Aids
IDE
Support Document
• Sample Code
Technical Notes
API specifies a set of functions or routines that accomplish
a specific task or allow to interact with a specific software
component. For example:
SYNOPSIS
DESCRIPTION
RETURNS
#include <math.h>
double sqrt(double X) / float sqrtf(float X);
sqrt computes the positive square root of the argument. ...
on success, the square root is returned. If X is real and positive...
DLL(Dynamic-link library) containing any combination of
code,data and resources is the concept of shared library in
the Win OS. These libraries have file extensions such
as DLL,OCX, or DRV.
DLL provides a mechanism for shared code and data,
allowing a developer to share code or upgrade data without
re-compiling the interlinkage of applications.
SDK
DLL
API
Win32
Available
Win64
System
Platform
Linux
Others
Unix
Mac OS
API Example
CKT_GetDeviceInfo
[Funciton] retrieve device’s system information
[Prototype] CKT_RESULT WINAPI CKT_GetDeviceInfo (int
sno,LPDEVICEINFO devinfo)
[Parameter] sno :Device ID,scope:1 —— 99999999
devinfo:Structure pointing receiving system information
[Return] success return1(TRUE)
fail return 0(FALSE)
•
•
•
•
•
•
•
•
•
•
•
•
•
•
typedef struct CKT_DeviceInfo
{
int ID; // Device serial number
int MajorVersion; // Device firmware version
int MinorVersion; // Device firmware version
int DoorLockDelay; // Lock control delay
int SpeakerVolume; // Speaker volume
int Parameter; //
int DefaultAuth; //
int Capacity;
// Capacity for the staffer information
int RealTimeAllow;//Allow to transfer data real-time.
int RingAllow;//Allow to make ringing
int LockDelayTime;//Lock delay time
int FixWGHead;//Fixed wiegand area code
• int WGOption;//wiegand option
• int AutoUpdateAllow;//Allow to update the fingerprint template intelligently
• int KQRepeatTime;//Options for the repeated clocking
• char[8] AdminPassword; // Commuinication password
• } DEVICEINFO, *LPDEVICEINFO;
[Sample]
• DEVICEINFO devinfo;
• if (CKT_GetDeviceInfo(12345678, &devinfo))
• {
•
printf("(CKT_GetDeviceInfo success.\n");
• }
[Note]
The returned structure members Parameter, DefaultAuth is no sense, just keeping
compatible with OA200.
Thank You
Anviz Overseas Technical Support Team