Trying to move ESP Now from ESP32 to ESP8266, but zero is happening

I copied this ESP Now method from Random Nerd Tutorials, which is usually super-reliable.
It doesn’t work.
This is serial output: Ȥl���Ȥl�ɕ2dO,4
Serial speed is correct.

I haven’t figured out how to use the ESP-Prog. Can you help?

#include <Arduino.h>
  Rui Santos
  Complete project details at

  Permission is hereby granted, free of charge, to any person obtaining a copy
  of this software and associated documentation files.

  The above copyright notice and this permission notice shall be included in all
  copies or substantial portions of the Software.

#include <ESP8266WiFi.h>
#include <espnow.h>
#include <Arduino_JSON.h>
#include "ESPAsyncWebServer.h"

// Structure example to receive data
// Must match the sender structure
typedef struct struct_message
  int id;
  float temperature;
  float humidity;
  float pressure;
  float Gas;
  float CO;
  float smoke;
  float moisture;
  float UV;
  float CO2;
  float NH3;
  float NO2;
  float VOC;
  float H2;
  unsigned int counter;
} struct_message;

// Create a struct_message called myData
struct_message myData;
JSONVar board;
AsyncEventSource events("/events");

// Callback function that will be executed when data is received
void OnDataRecv(uint8_t *mac_addr, uint8_t *incomingData, uint8_t len)
  char macStr[18];
  Serial.print("Packet received from: ");
  snprintf(macStr, sizeof(macStr), "%02x:%02x:%02x:%02x:%02x:%02x",
           mac_addr[0], mac_addr[1], mac_addr[2], mac_addr[3], mac_addr[4], mac_addr[5]);
  memcpy(&myData, incomingData, sizeof(myData));

  board["id"] =;
  board["temperature"] = myData.temperature;
  board["humidity"] = myData.humidity;
  // board["pressure"] = myData.pressure;
  board["counter"] = String(myData.counter);
  String jsonString = JSON.stringify(board);
  events.send(jsonString.c_str(), "new_readings", millis());

  Serial.printf("Board ID %u: %u bytes\n",, len);
  Serial.printf("t value: %4.2f \n", myData.temperature);
  Serial.printf("h value: %4.2f \n", myData.humidity);
  Serial.printf("p value: %4.2f \n", myData.pressure);

void setup()
  // Initialize Serial Monitor

  // Set device as a Wi-Fi Station

  // Init ESP-NOW
  if (esp_now_init() != 0)
    Serial.println("Error initializing ESP-NOW");

  // Once ESPNow is successfully Init, we will register for recv CB to
  // get recv packer info

void loop()