Particle.io in Canada?

Correct, you need one that can do TTL (UART?) through the RX and TX pins, Raspberry cam’s won’t work.

PHP script for the server is super simple: (ref: https://stackoverflow.com/a/26679604)

$uploaddir = '/usr/share/nginx/html/';
$upload_filename = date('Y-m-d_H-i-s') . '.jpg';
$uploadfile = $uploaddir . $upload_filename;

if(move_uploaded_file($_FILES['picture']['tmp_name'], $uploadfile)){
  http_response_code(202);
  echo "OK.\n";
}else{
  http_response_code(406);
  echo "NOK!\n";
}

for the Firmware, you can refer to: Electron with serial jpeg camera sending partial images to the server

1 Like