Skip to content

serial value compilation problem #4

@kuldeepdhaka

Description

@kuldeepdhaka

SerialPortToolForm.cpp: In member function ‘void SerialPortToolForm::initData()’:
SerialPortToolForm.cpp:64:27: error: ‘BAUD128000’ was not declared in this scope
map_int_baud_[128000] = BAUD128000;
^
SerialPortToolForm.cpp:66:27: error: ‘BAUD256000’ was not declared in this scope
map_int_baud_[256000] = BAUD256000;
^
make: *** [.obj/SerialPortToolForm.o] Error 1
[kuldeep@localhost Mindplus-Desktop]$ find .|grep SerialPortToolForm.cpp

_solved: [qtextserialport.h]

if defined(Q_OS_WIN) || defined(qdoc)

BAUD14400 = 14400,          //WINDOWS ONLY
BAUD56000 = 56000,          //WINDOWS ONLY
BAUD128000 = 128000,        //WINDOWS ONLY
BAUD256000 = 256000,        //WINDOWS ONLY

endif //Q_OS_WIN

BAUD110 = 110,
BAUD300 = 300,
BAUD600 = 600,
BAUD1200 = 1200,
BAUD2400 = 2400,
BAUD4800 = 4800,
BAUD9600 = 9600,
BAUD19200 = 19200,
BAUD38400 = 38400,
BAUD57600 = 57600,
BAUD115200 = 115200,

// BAUD128000 = 128000, //WINDOWS ONLY
BAUD250000 = 250000, //WINDOWS ONLY
//BAUD256000 = 256000 //WINDOWS ONLY
};

or add using compile time condition in [SerialPortToolForm.cpp]
SerialPortToolForm::initData()
{
{
map_int_baud_[110] = BAUD110;
map_int_baud_[300] = BAUD300;
map_int_baud_[600] = BAUD600;
map_int_baud_[1200] = BAUD1200;
map_int_baud_[2400] = BAUD2400;
map_int_baud_[4800] = BAUD4800;
map_int_baud_[9600] = BAUD9600;
map_int_baud_[19200] = BAUD19200;
map_int_baud_[38400] = BAUD38400;
map_int_baud_[57600] = BAUD57600;
map_int_baud_[115200] = BAUD115200;
map_int_baud_[128000] = BAUD128000;
map_int_baud_[250000] = BAUD250000;
map_int_baud_[256000] = BAUD256000;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions