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::FTDI_Writer ( )
inline

A constructor, that more elaborated..

Definition at line 61 of file writer.hpp.

Member Function Documentation

◆ reset_flags()

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 75 of file writer.hpp.

◆ write() [1/3]

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 87 of file writer.hpp.

◆ write() [2/3]

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 103 of file writer.hpp.

◆ write() [3/3]

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 121 of file writer.hpp.

Member Data Documentation

◆ log_level

int FTDI_Writer::log_level
private

currently unused.

Definition at line 287 of file writer.hpp.

◆ product_id

const unsigned short FTDI_Writer::product_id
private

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

Definition at line 299 of file writer.hpp.

◆ serial_only

bool FTDI_Writer::serial_only
private

flags to control internal behavior of writer class.

Definition at line 288 of file writer.hpp.

◆ use_first_device

bool FTDI_Writer::use_first_device
private

flags to control internal behavior of writer class.

Definition at line 289 of file writer.hpp.

◆ vendor_id

const unsigned short FTDI_Writer::vendor_id
private

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

Definition at line 294 of file writer.hpp.


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


kobuki_ftdi
Author(s): Younghun Ju
autogenerated on Wed Mar 2 2022 00:26:19