Email send question.

That code won't send. Port 465 (and for Gmail it is 587) are not open connections. They both have security on them. You must authenticate with your Gmail user/password before sending anything.

  Serial.println ("connecting");
  if (client.connect (server,465)) {
    Serial.println ("connected");
    client.println ("Hello @gmail.com");
// server replies with "Hello. Start your TLS"
    delay (x);
// you don't start your TLS, so the server sends "400 error - If no TLS, then no send"
// you continue to attempt the send anyway, and it keeps replying with 400 errors.