/* Hello.c : Reads library version and flash memory size. Compiler: BC++ 3.1, Turbo C ++ 1.01(3.01) (free from http://community.borland.com/museum) MSC 6.0, MSVC 1.52. Compile mode: large Project: Hello.c ..\Lib\(8000E.Lib,7188XAL.Lib,7188XBL.Lib,7188XL.Lib or 7188EL.Lib) Detail description: User can use MiniOs utility to load hello.exe to 7188XA/7188XB/7188XC/8000. Hardware: 7188/8000 [24 May,2005] by Bill */ #include"..\..\lib\P821.h" void main(void) { int iType,iVer; InitLib(); iType=IsP821(); if(iType) { iVer=GetLibVersion(); Print("Hello 8000! (Flash memory is %d K)\n\r",iType); Print("Library version is %d.%02d\n\r\n\r",iVer>>8,iVer&0xff); if (FlashGetWpStatus()) Print ("Flash is in Write-Protected mode \n\r"); else Print ("Flash is in Write-Enabled mode \n\r"); } else { Print("Hello PC!, this program is not run under 8000."); } }