Commit d7f8d7db authored by Patrick Dohmen's avatar Patrick Dohmen

Change hex representation fmt to "0x00, 0x02, 0xff"

parent e2703d26
Pipeline #19172641 passed with stage
in 10 minutes and 41 seconds
......@@ -119,8 +119,8 @@ namespace gr
std::ofstream fd (filename.c_str ());
su = (uint8_t *) pmt::blob_data (msg);
for (size_t i = 0; i < pmt::blob_length (msg); i++) {
fd << std::hex << std::showbase << std::setw (4)
<< (uint32_t) su[i] << " ";
fd << "0x" << std::hex << std::setw (2)
<< std::setfill('0') << (uint32_t) su[i] << " ";
}
fd.close ();
break;
......
......@@ -66,8 +66,8 @@ namespace gr
case 1:
su = (uint8_t *) pmt::blob_data (msg);
for (size_t i = 0; i < pmt::blob_length (msg); i++) {
d_fos << std::hex << std::showbase << std::setw (4)
<< (uint32_t) su[i] << " ";
d_fos << "0x" << std::hex << std::setw (2)
<< std::setfill('0') << (uint32_t) su[i] << " ";
}
d_fos << std::endl;
break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment