BlinkenArea - GitList
Repositories
Blog
Wiki
flaneth
Code
Commits
Branches
Tags
Search
Tree:
33333f0
Branches
Tags
master
flaneth
firmware
apps_tools.h
added port number to BBM->MCUF output application running two BBM->MCUF output applications at same time
Stefan Schuermans
commited
33333f0
at 2012-05-06 17:54:55
apps_tools.h
Blame
History
Raw
/* flaneth - flash and ethernet Copyright (C) 2007-2012 Stefan Schuermans <stefan@schuermans.info> Copyleft: GNU public license V2 - http://www.gnu.org/copyleft/gpl.html a BlinkenArea project - http://www.blinkenarea.org/ */ #ifndef INC_apps_tools #define INC_spps_tools #include "dosfs.h" /** * @brief read string from file * @param[in] sectorBuf scratch buffer to store a sector * @param[in] vi volume information structure * @param[in] filename name of file to read * @param[out] buf buffer to put string to * @param[in] sz size of buffer * @return 0 on success, -1 on error */ extern char AppsToolsReadStr(uint8_t sectorBuf[SECTOR_SIZE], VOLINFO *vi, const char *filename, char *buf, unsigned int sz); /** * @brief read MAC address from file * @param[in] sectorBuf scratch buffer to store a sector * @param[in] vi volume information structure * @param[in] filename name of file to read * @param[out] mac MAC address read * @return 0 on success, -1 on error */ extern char AppsToolsReadMac(uint8_t sectorBuf[SECTOR_SIZE], VOLINFO *vi, const char *filename, unsigned char mac[6]); /** * @brief read IP address from file * @param[in] sectorBuf scratch buffer to store a sector * @param[in] vi volume information structure * @param[in] filename name of file to read * @param[out] ip IP address read * @return 0 on success, -1 on error */ extern char AppsToolsReadIp(uint8_t sectorBuf[SECTOR_SIZE], VOLINFO *vi, const char *filename, unsigned char ip[4]); /** * @brief read network port from file * @param[in] sectorBuf scratch buffer to store a sector * @param[in] vi volume information structure * @param[in] filename name of file to read * @param[out] port network port read * @return 0 on success, -1 on error */ extern char AppsToolsReadPort(uint8_t sectorBuf[SECTOR_SIZE], VOLINFO *vi, const char *filename, unsigned short *port); #endif // #ifndef INC_apps_tools