Public Member Functions | Private Attributes | List of all members
FTDI_Writer Class Reference

A Writer class. More...

#include <writer.hpp>

Public Member Functions

 FTDI_Writer ()
 
void reset_flags ()
 
int write (const std::string &new_id_)
 
int write (const std::string &old_id_, const std::string &new_id_)
 
int write (const std::string &old_id_, const std::string &new_id_, const std::string &manufacturer_, const std::string &product_)
 

Private Attributes

int log_level
 
const unsigned short product_id
 
bool serial_only
 
bool use_first_device
 
const unsigned short vendor_id
 

Detailed Description

A Writer class.

A Writer class for FTDI devices, especially for FTDI FT232R chip.

Definition at line 52 of file writer.hpp.

Constructor & Destructor Documentation

FTDI_Writer::FTDI_Writer ( )
inline

A constructor, that more elaborated..

Definition at line 57 of file writer.hpp.

Member Function Documentation

void FTDI_Writer::reset_flags ( )
inline

reset flags to default state.

See also
write(const std::string&), write(const std::string&, const std::string&)

Definition at line 69 of file writer.hpp.

int FTDI_Writer::write ( const std::string &  new_id_)
inline

Write new serial name to ftdi device what first detected.

Parameters
[in]new_id_new serial number for ftdi device
Returns
0 on success
negative number on failure
See also
write(const std::string&, const std::string&), write(const std::string&, const std::string&, const std::string&, const std::string&)

Definition at line 81 of file writer.hpp.

int FTDI_Writer::write ( const std::string &  old_id_,
const std::string &  new_id_ 
)
inline

Write new serial name to ftdi device what have specified serial name.

Parameters
[in]old_id_serial number of target device
[in]new_id_new serial number for ftdi device
Returns
0 on success
negative number on failure
See also
write(const std::string&), write(const std::string&, const std::string&, const std::string&, const std::string&)

Definition at line 97 of file writer.hpp.

int FTDI_Writer::write ( const std::string &  old_id_,
const std::string &  new_id_,
const std::string &  manufacturer_,
const std::string &  product_ 
)
inline

Write new serial name to ftdi device what have specified serial name, manufacturer and product name also.

Parameters
[in]old_id_serial number of target device
[in]new_id_new serial number for ftdi device
[in]manufacturer_new manufacture name for ftdi device
[in]product_new product name for ftdi device
Returns
0 on success
negative number on failure
See also
write(const std::string&), write(const std::string&, const std::string&)

Definition at line 115 of file writer.hpp.

Member Data Documentation

int FTDI_Writer::log_level
private

currently unused.

Definition at line 281 of file writer.hpp.

const unsigned short FTDI_Writer::product_id
private

product ID of FTDI chip. Fixed to 0x6001 for FT232R chip.

Definition at line 293 of file writer.hpp.

bool FTDI_Writer::serial_only
private

flags to control internal behavior of writer class.

Definition at line 282 of file writer.hpp.

bool FTDI_Writer::use_first_device
private

flags to control internal behavior of writer class.

Definition at line 283 of file writer.hpp.

const unsigned short FTDI_Writer::vendor_id
private

vendor ID of FTDI chip. Fixed to 0x0403 for FTDI company.

Definition at line 288 of file writer.hpp.


The documentation for this class was generated from the following file:


roch_ftdi
Author(s): Younghun Ju
autogenerated on Mon Jun 10 2019 14:41:09