BeRTOS
Data Structures | Functions
keytag.h File Reference

Tag protocol. (interface). More...

#include "cfg/cfg_keytag.h"
#include <cfg/compiler.h>
#include <io/kfile.h>

Go to the source code of this file.

Data Structures

struct  TagPacket
 Structure of a Tag packet. More...

Functions

void keytag_init (struct TagPacket *pkt, struct KFile *comm, struct KFile *tag)
 Init the keytag module.
int keytag_recv (struct TagPacket *pkt, uint8_t *tag, size_t len)
 Receive the tag message from channel, and if the tag is good put the converted string into given buffer.
DEPRECATED void keytag_poll (struct TagPacket *pkt)
 DEPRECATED FUCNTIONS To read the tag string from device you shoul use the keytag_recv fuction, that return the string if we had received it.

Detailed Description

Tag protocol. (interface).

Author:
Andrea Grandi <andrea@develer.com>

Definition in file keytag.h.


Function Documentation

int keytag_recv ( struct TagPacket pkt,
uint8_t *  tag,
size_t  len 
)

Receive the tag message from channel, and if the tag is good put the converted string into given buffer.

The fuction return the len of found tag string, otherwise EOF.

Definition at line 95 of file keytag.c.