广播命令可以接收各个从机的返回数据
This commit is contained in:
@@ -272,7 +272,7 @@ void selfdev_slaveupdate::timeout(){
|
||||
qDebug("slave update timeout");
|
||||
}
|
||||
|
||||
void selfdev_slaveupdate::slave_end_slot(int addr,int ack, myarray data)
|
||||
void selfdev_slaveupdate::slave_end_slot(int addr,int ack, slave_data data)
|
||||
{
|
||||
qDebug("slave update end,ack=%d",ack);
|
||||
busy=0;
|
||||
@@ -348,7 +348,7 @@ void selfdev_update_scheme::timeout(){
|
||||
qDebug("slave update timeout");
|
||||
}
|
||||
|
||||
void selfdev_update_scheme::slave_end_slot(int addr,int ack, myarray data)
|
||||
void selfdev_update_scheme::slave_end_slot(int addr,int ack, slave_data data)
|
||||
{
|
||||
qDebug("slave update end,ack=%d",ack);
|
||||
busy=0;
|
||||
@@ -563,6 +563,27 @@ static myarray slave_to_bootinfo_byte(myarray data){
|
||||
return data;
|
||||
}
|
||||
|
||||
//void selfdev_bootinfo::slave_end_slot(int addr,int ack, slave_data data)
|
||||
//{
|
||||
// if(addr<=0||addr>slave_acked.size()){
|
||||
// qWarning("slave addr err:%d",addr);
|
||||
// return;
|
||||
// }
|
||||
// for(int i=0;i<data.size();i++){
|
||||
// slave_ret slave=data.at(i);
|
||||
// slave_acked.replace(slave.addr-1,slave.data);
|
||||
// slave_acked_num++;
|
||||
// myarray r;
|
||||
// r.append(char(0));
|
||||
// r+=bootinfo_fill_local();
|
||||
// for(int i=0;i<slave_acked.size();i++){
|
||||
// r.append(slave_to_bootinfo_byte(slave_acked[i]));
|
||||
// }
|
||||
// emit send_data_signal(0x34,r);
|
||||
// busy=0;
|
||||
// }
|
||||
//}
|
||||
|
||||
void selfdev_bootinfo::slave_end_slot(int addr,int ack, myarray data)
|
||||
{
|
||||
if(addr<=0||addr>slave_acked.size()){
|
||||
@@ -583,6 +604,8 @@ void selfdev_bootinfo::slave_end_slot(int addr,int ack, myarray data)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
static HandlePc *get_selfdev_bootinfo(){
|
||||
return new selfdev_bootinfo();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user