Change primary postcode interface to byte array

Change primary code to std::vector<uint8_t> to meet the changes in
phosphor-dbus-interface.

[1] https://gerrit.openbmc.org/c/openbmc/phosphor-dbus-interfaces/+/74633

Change-Id: Ib5822973a1dbc6aa8c52f4e81b56091dc33b5f08
Signed-off-by: Cosmo Chou <cosmo.chou@quantatw.com>
Signed-off-by: Potin Lai <potin.lai@quantatw.com>
diff --git a/example.cpp b/example.cpp
index b3549d0..95cc7a4 100644
--- a/example.cpp
+++ b/example.cpp
@@ -25,8 +25,14 @@
 static void printPostcode(FILE*, postcode_t postcode)
 {
     /* Print output to verify the example program is receiving values. */
-    std::printf("recv: 0x%" PRIx64 "\n",
-                std::get<primary_post_code_t>(postcode));
+    auto code = std::get<0>(postcode);
+    std::string hexCode;
+    hexCode.reserve(2 * code.size());
+    for (const auto& byte : code)
+    {
+        hexCode += std::format("{:02x}", byte);
+    }
+    std::printf("recv: 0x%s\n", hexCode.c_str());
 }
 
 /*