1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
#include <WiFi.h> #include <WiFiUdp.h> #define DAC_PIN 25 // Replace with the GPIO pin you want to use for DAC output const char* ssid = "5435435435"; const char* password = "5435435431"; WiFiUDP udp; IPAddress serverIP(192, 168, 1, 2); // Replace with the IP address of your server ESP32 int serverPort = 6010; // Define the server's UDP port int clientPort = 6020; // Define the client's UDP port (choose a different port) void setup() { pinMode(DAC_PIN, OUTPUT); Serial.begin(115200); // Initialize the DAC (Digital-to-Analog Converter) // Connect to Wi-Fi WiFi.begin(ssid, password); while (WiFi.status() != WL_CONNECTED) { delay(1000); Serial.println("Connecting to WiFi..."); } Serial.println("Connected to WiFi"); udp.begin(serverPort); Serial.print("Local IP address: "); Serial.println(WiFi.localIP()); } void loop() { unsigned char packetBuffer[1045]; // Create a buffer to hold the incoming UDP packet data int packetSize = udp.parsePacket(); // Check if there's a UDP packet available int i =0; if (packetSize) { IPAddress remoteIP = udp.remoteIP(); // Get the source IP address int remotePort = udp.remotePort(); // Get the source port // Serial.printf("Received %d bytes from %s:%d\n", packetSize, remoteIP.toString().c_str(), remotePort); // Read the UDP packet into the buffer udp.read(packetBuffer, sizeof(packetBuffer)); // Null-terminate the buffer to treat it as a C-string packetBuffer[packetSize] = '\0'; for (i=0;i<=1024;i++) { // Set DAC output to 234 (0-255 for 8 bits) dacWrite(DAC_PIN, packetBuffer[i]); } //Serial.println("..."); // Print the received message //Serial.println("Message received: "); //Serial.println(packetBuffer); // Send a response back to the client //udp.beginPacket(remoteIP, clientPort); //#udp.printf("Hello from ESP32 Server"); //udp.endPacket(); //Serial.println("Response sent to client"); } // Your code can continue here, and you can add more functionality as needed } |
קוד שולח בפייתון
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
import socket import wave import numpy as np import time # Define the delay in microseconds (e.g., 1000 microseconds = 1 millisecond) microseconds_delay = 300 # Replace with your desired delay in microseconds # Convert microseconds to seconds (1 second = 1,000,000 microseconds) seconds_delay = microseconds_delay / 1_000_000 # Convert microseconds to seconds (1 second = 1,000,000 microseconds) seconds_delay = microseconds_delay / 1_000_000 # Server IP address and port server_ip = "10.0.0.22" # Replace with the target IP address server_port = 6010 # Replace with the target UDP port # Create a UDP socket client_socket = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) # Specify the path to your WAV file wav_file_path = 'D:/projetcs8/Small-talk/sound/1c.wav' # Chunk size for sending data over UDP chunk_size = 1026 print("send...") # Define a function to send WAV file chunks over UDP def send_wav_chunks(wav_path): try: # Open the WAV file with wave.open(wav_path, 'rb') as wav_file: # Get the audio parameters params = wav_file.getparams() # Read audio data audio_data = wav_file.readframes(params.nframes) # Send the audio data over UDP in chunks for i in range(0, len(audio_data), chunk_size): chunk = audio_data[i:i+chunk_size] client_socket.sendto(chunk, (server_ip, server_port)) time.sleep(seconds_delay) #print(f"Sent {len(chunk)} bytes") except Exception as e: print(f"An error occurred: {str(e)}") # Call the function to send WAV file chunks over UDP send_wav_chunks(wav_file_path) # Close the UDP socket client_socket.close() |
שליחת הודעה ניסוי מוקלטת בצורה פשוטה מ ESP32
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 |
#include <Arduino.h> #include <WiFi.h> #include <WiFiUdp.h> const int DAC_PIN = 25; // DAC output pin (GPIO 25) const int SINE_FREQ = 1200; // Frequency of the sine wave in Hz const int SAMPLE_RATE = 10000; // Sample rate in Hz const uint8_t play3[] = { 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 125, 125, 125, 125, 125, 125, 126, 126, 126, 126, 126, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 128, 128, 128, 128, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 127, 127, 127, 126, 126, 126, 125, 125, 125, 125, 124, 124, 124, 124, 124, 124, 125, 125, 125, 125, 125, 126, 126, 126, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 131, 131, 131, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 128, 128, 127, 127, 127, 126, 126, 126, 126, 126, 126, 125, 125, 125, 125, 125, 125, 126, 126, 126, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 126, 126, 126, 126, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 128, 128, 128, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 126, 126, 126, 126, 126, 125, 125, 125, 125, 124, 124, 124, 124, 124, 124, 124, 124, 124, 125, 125, 125, 125, 125, 126, 126, 126, 127, 127, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 127, 127, 127, 127, 127, 126, 126, 126, 126, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 126, 126, 126, 126, 127, 127, 127, 127, 127, 128, 128, 128, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 131, 131, 131, 131, 131, 131, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 130, 130, 129, 129, 129, 129, 130, 130, 130, 130, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 126, 126, 125, 125, 126, 126, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 128, 127, 127, 127, 127, 128, 128, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 131, 133, 136, 142, 148, 155, 161, 163, 161, 154, 147, 142, 141, 144, 149, 151, 149, 142, 135, 130, 129, 131, 134, 134, 132, 127, 122, 118, 115, 113, 111, 107, 104, 101, 99, 98, 97, 96, 95, 94, 94, 96, 100, 106, 112, 119, 124, 128, 130, 130, 129, 128, 127, 128, 130, 133, 136, 137, 136, 135, 135, 136, 137, 138, 138, 136, 135, 135, 136, 137, 136, 133, 127, 122, 118, 118, 118, 118, 117, 114, 111, 110, 110, 112, 113, 111, 109, 108, 109, 111, 115, 117, 117, 116, 116, 116, 119, 124, 129, 134, 138, 139, 138, 136, 134, 133, 133, 135, 137, 137, 135, 132, 130, 130, 132, 134, 136, 136, 135, 133, 131, 130, 130, 130, 128, 125, 121, 118, 117, 118, 120, 122, 122, 121, 120, 120, 123, 127, 131, 134, 134, 132, 129, 127, 127, 128, 130, 131, 132, 131, 129, 128, 128, 129, 131, 133, 135, 135, 135, 135, 134, 134, 134, 133, 132, 131, 129, 128, 128, 129, 130, 132, 133, 133, 131, 129, 129, 130, 133, 137, 139, 139, 137, 133, 130, 129, 129, 130, 131, 132, 131, 130, 129, 128, 129, 129, 130, 130, 130, 130, 130, 130, 130, 129, 128, 128, 127, 127, 127, 128, 128, 129, 129, 129, 128, 128, 128, 129, 130, 131, 131, 130, 129, 127, 127, 127, 127, 128, 128, 129, 129, 129, 130, 131, 132, 132, 131, 129, 128, 127, 128, 128, 128, 128, 127, 126, 126, 125, 126, 126, 127, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 127, 127, 126, 126, 126, 126, 127, 128, 129, 129, 128, 128, 127, 126, 126, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 130, 130, 130, 130, 129, 129, 128, 129, 129, 129, 128, 127, 126, 126, 125, 124, 124, 124, 125, 126, 127, 127, 126, 125, 124, 124, 124, 125, 125, 125, 125, 125, 124, 124, 124, 123, 123, 123, 123, 125, 126, 128, 128, 128, 126, 125, 125, 125, 125, 125, 125, 125, 126, 127, 127, 127, 126, 126, 126, 127, 129, 130, 130, 130, 129, 129, 129, 130, 130, 129, 128, 127, 126, 126, 126, 127, 129, 129, 130, 130, 129, 129, 129, 130, 130, 130, 130, 130, 129, 129, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 130, 131, 131, 132, 133, 134, 133, 133, 131, 130, 129, 129, 130, 131, 131, 131, 130, 130, 129, 130, 130, 131, 131, 131, 130, 130, 131, 131, 132, 132, 131, 130, 129, 128, 128, 128, 128, 129, 129, 129, 129, 129, 131, 132, 133, 133, 132, 131, 129, 129, 129, 130, 130, 130, 129, 128, 127, 127, 127, 128, 129, 129, 129, 129, 128, 128, 128, 127, 127, 127, 126, 126, 125, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 125, 125, 125, 125, 126, 126, 125, 124, 122, 120, 120, 121, 122, 124, 126, 125, 124, 123, 122, 122, 123, 126, 128, 129, 129, 127, 125, 123, 122, 123, 125, 127, 129, 130, 130, 128, 127, 126, 127, 129, 132, 134, 134, 134, 134, 133, 133, 133, 133, 132, 131, 131, 131, 132, 132, 132, 131, 130, 129, 130, 132, 133, 134, 134, 133, 132, 131, 131, 131, 130, 128, 126, 125, 125, 126, 127, 127, 127, 127, 128, 129, 130, 131, 131, 130, 129, 128, 128, 129, 129, 128, 127, 125, 124, 124, 124, 125, 126, 128, 131, 133, 135, 135, 134, 132, 130, 129, 128, 128, 128, 127, 127, 126, 126, 126, 126, 126, 126, 127, 128, 129, 130, 130, 130, 130, 129, 129, 130, 130, 130, 130, 128, 127, 126, 126, 127, 127, 127, 127, 127, 127, 128, 130, 130, 130, 130, 129, 128, 128, 129, 129, 130, 129, 128, 127, 126, 125, 125, 125, 126, 127, 128, 128, 127, 125, 123, 122, 123, 125, 127, 127, 125, 123, 121, 121, 123, 126, 129, 130, 129, 127, 126, 126, 127, 127, 127, 127, 126, 126, 126, 126, 126, 125, 125, 125, 127, 129, 130, 130, 129, 127, 126, 126, 127, 128, 128, 127, 125, 124, 123, 123, 123, 123, 124, 125, 127, 128, 128, 128, 126, 125, 126, 127, 128, 128, 128, 126, 124, 122, 122, 123, 124, 126, 127, 127, 127, 127, 128, 128, 128, 129, 130, 131, 132, 132, 132, 130, 129, 127, 127, 127, 128, 128, 128, 128, 128, 129, 130, 131, 131, 131, 130, 130, 130, 131, 131, 131, 131, 130, 130, 129, 129, 128, 128, 128, 129, 131, 132, 133, 134, 134, 133, 133, 132, 131, 131, 130, 130, 130, 130, 129, 129, 128, 128, 128, 129, 131, 132, 134, 134, 134, 133, 132, 130, 129, 128, 127, 127, 127, 127, 128, 129, 129, 129, 129, 128, 128, 129, 130, 131, 132, 133, 133, 131, 130, 128, 127, 127, 127, 128, 128, 128, 128, 128, 128, 130, 131, 132, 133, 132, 131, 130, 130, 131, 131, 132, 132, 131, 129, 128, 127, 127, 128, 129, 130, 131, 132, 132, 132, 132, 132, 131, 130, 129, 129, 129, 129, 129, 128, 127, 126, 126, 126, 128, 129, 130, 131, 131, 130, 129, 128, 127, 126, 126, 126, 126, 125, 123, 123, 122, 122, 122, 122, 123, 124, 125, 126, 126, 125, 125, 125, 125, 125, 125, 125, 125, 123, 122, 122, 122, 122, 123, 125, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 125, 124, 122, 122, 122, 122, 123, 124, 123, 123, 122, 123, 124, 126, 127, 128, 129, 129, 128, 127, 127, 126, 125, 124, 124, 126, 127, 129, 129, 128, 128, 128, 128, 129, 130, 131, 131, 130, 130, 129, 129, 128, 127, 127, 127, 127, 128, 129, 130, 131, 131, 131, 131, 131, 132, 132, 132, 132, 132, 131, 130, 130, 129, 129, 128, 128, 128, 128, 129, 130, 131, 132, 133, 134, 134, 134, 133, 132, 131, 130, 129, 129, 128, 127, 127, 126, 126, 126, 126, 126, 127, 127, 128, 129, 130, 130, 130, 130, 129, 129, 128, 127, 127, 127, 127, 127, 127, 127, 128, 128, 129, 129, 130, 130, 131, 132, 132, 131, 131, 130, 129, 129, 129, 129, 128, 128, 127, 127, 127, 127, 128, 129, 130, 130, 130, 130, 129, 128, 128, 128, 128, 128, 128, 127, 126, 125, 125, 124, 125, 125, 126, 127, 128, 129, 128, 128, 127, 127, 126, 126, 125, 124, 123, 122, 122, 121, 121, 122, 122, 122, 122, 123, 123, 124, 125, 125, 126, 126, 126, 125, 124, 123, 122, 122, 122, 123, 124, 124, 124, 124, 124, 124, 125, 126, 127, 128, 129, 130, 130, 129, 129, 128, 128, 128, 128, 129, 130, 131, 132, 132, 131, 130, 129, 129, 129, 130, 131, 131, 131, 131, 131, 130, 129, 129, 129, 129, 130, 130, 131, 131, 131, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 129, 130, 131, 131, 130, 130, 130, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 129, 129, 129, 130, 129, 129, 129, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 125, 124, 124, 124, 124, 125, 126, 127, 127, 127, 127, 127, 127, 127, 127, 128, 127, 127, 127, 126, 126, 126, 125, 126, 126, 126, 127, 127, 128, 128, 128, 128, 129, 129, 129, 129, 129, 128, 127, 126, 126, 125, 125, 125, 125, 125, 125, 125, 125, 125, 126, 127, 127, 128, 128, 128, 128, 127, 127, 127, 128, 128, 129, 130, 130, 130, 130, 129, 129, 129, 130, 131, 131, 132, 131, 131, 131, 131, 131, 131, 132, 132, 133, 133, 133, 133, 133, 133, 132, 132, 131, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 130, 130, 131, 131, 131, 130, 130, 129, 129, 128, 128, 129, 129, 129, 129, 129, 129, 128, 128, 129, 129, 130, 130, 130, 129, 129, 128, 127, 126, 126, 125, 126, 126, 126, 126, 126, 125, 124, 124, 124, 124, 125, 125, 126, 127, 127, 127, 127, 127, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 128, 128, 129, 129, 129, 129, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 127, 127, 126, 126, 126, 126, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 127, 127, 127, 127, 127, 126, 126, 125, 125, 126, 126, 127, 127, 128, 128, 129, 129, 130, 130, 129, 129, 129, 130, 130, 130, 130, 129, 129, 129, 129, 130, 131, 132, 132, 132, 132, 132, 132, 132, 132, 132, 132, 131, 131, 130, 130, 129, 129, 129, 129, 129, 130, 130, 131, 131, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 128, 128, 128, 128, 129, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 127, 127, 128, 128, 128, 129, 129, 128, 128, 128, 128, 128, 128, 127, 127, 127, 127, 127, 127, 127, 126, 125, 125, 124, 125, 125, 125, 126, 126, 126, 126, 125, 125, 125, 125, 126, 126, 126, 127, 127, 127, 126, 126, 126, 126, 126, 126, 127, 127, 127, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, 132, 132, 132, 132, 131, 131, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 127, 127, 127, 128, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 127, 127, 127, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 126, 126, 125, 124, 124, 124, 124, 124, 125, 125, 125, 126, 126, 126, 126, 126, 127, 127, 127, 128, 127, 127, 126, 126, 125, 125, 125, 125, 125, 125, 125, 126, 126, 126, 126, 126, 127, 127, 127, 128, 128, 128, 128, 128, 128, 129, 129, 128, 128, 128, 128, 128, 129, 129, 130, 130, 130, 130, 130, 130, 130, 130, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 127, 127, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 128, 128, 127, 127, 127, 127, 126, 126, 126, 125, 125, 125, 125, 125, 125, 126, 126, 127, 127, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 130, 130, 131, 131, 131, 131, 131, 130, 130, 130, 130, 129, 129, 129, 129, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 128, 128, 128, 128, 128, 128, 128, 128, 128, |