⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 build.bat

📁 使用Jungo Windriver開發的USB driver 及其firmware,類型為mass storage,應用於FX2(Cypress CY68013A)上.
💻 BAT
字号:
@echo off
REM # command line switches
REM # ---------------------
REM # clean delete temporary files

REM # Set environement variables
set path=C:\Keil\c51\bin;%path%
set CYUSB=c:\Cypress\USB
set C51INC=%CYUSB%\Target\inc;C:\Keil\c51\inc;%WD_BASEDIR%\wdf\cypress\fx2lp\include

REM ### usage: build -clean
if "%1" == "-clean" goto CLEAN

set TARGET=l123456
:ALL
    REM ### Compile main framework
    c51 main.c DB OE CODE MODDP2 DF(FX2LP) DF(FX2LP_NEW)

    REM ### Compile utility code ###
    REM ### Note: This code does not generate interrupt vectors ###
    c51 wdf_cypress_lib.c DB OE CODE MODDP2 NOIV DF(FX2LP) DF(FX2LP_NEW)

    REM ### Compile user peripheral code ###
	   REM ### Note: This code does not generate interrupt vectors ###
    c51 periph.c DB OE CODE MODDP2 NOIV DF(FX2LP) DF(FX2LP_NEW)

    REM ### Assemble descriptor table ###
    a51 wdf_dscr.a51 ERRORPRINT DEBUG

    REM ### Link object code (includes debug info) ###
    REM ### Note: XDATA and CODE must not overlap ###
    REM ### Note: using a response file here for line longer than 128 chars

    echo wdf_dscr.obj, periph.obj, > tmp.rsp
    echo main.obj, wdf_cypress_lib.obj  >> tmp.rsp
    echo ,"%CYUSB%\Target\Lib\LP\USBJmpTb.obj", >> tmp.rsp
    echo "%CYUSB%\Target\Lib\LP\EZUSB.lib" >> tmp.rsp
    echo TO %TARGET% RAMSIZE(256) PL(68) PW(78) CODE(80h) XDATA(1000h) DW(16) >> tmp.rsp
    bl51 @tmp.rsp

    REM ### Generate intel hex image of binary (no debug info) ###
    oh51 %TARGET% HEXFILE(%TARGET%.hex)

    goto DONE

:CLEAN
    if exist tmp.rsp del tmp.rsp
    if exist *.lst del *.lst
    if exist *.obj del *.obj
    if exist *.m51 del *.m51
    if exist *.hex del *.hex
    if exist %TARGET% del %TARGET%

:DONE

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -