Jump to content

HarisAhmed

Members
  • Content Count

    9
  • Joined

  • Last visited


Reputation Activity

  1. Like
    HarisAhmed reacted to MORA99 in CC3200 bootloader   
    In order for this board to reach its full potential, it needs to be programmable in the field, very much preferably without a usb cable and a laptop at the location.
     
    From what I can gather the code for the chip is stored in the external SPI chip and when we flash new firmware, we are using the ftdi to send uart to the cc3200 which in turn writes the SPI.
     
    Is it possible to replace this bootloader with something that can load a new sketch/hex file over the network ?
    If not then the only remote programming possible would be a lesser language that is interpeted and any firmware upgrades would have to be done locally.
     
    I have a similar issue with the wired launchpad, it uses a seperate chip to do the programming, which does not have network access, but maybe one could store it somewhere and then reset the programming chip.
     
  2. Like
    HarisAhmed reacted to spirilis in CC3200 & SSL   
    I got basic outbound SSL sockets working.  Wasn't that hard, although the File Writing process for uploading a root CA certificate doesn't seem to work so I axed it...
     
    Replace your energia-0101E0013/hardware/cc3200/libraries/WiFi/WiFiClient.cpp and WiFiClient.h files with these:
    https://raw.githubusercontent.com/energia/Energia/issue_472/hardware/cc3200/libraries/WiFi/WiFiClient.cpp
    and
    https://raw.githubusercontent.com/energia/Energia/issue_472/hardware/cc3200/libraries/WiFi/WiFiClient.h
     
    Syntax is just .sslConnect(hostname, port) or .sslConnect(IPAddress, port).
     
    Example sketch:
    #include <WiFiUdp.h> #include <WiFi.h> #include <WiFiClient.h> #include <WiFiServer.h> const char ssid[] = "myWifiSSID"; const char wifipw[] = "blahblahblah"; void setup() { uint32_t msave; Serial.begin(115200); delay(2000); Serial.println("WiFi:"); WiFi.begin((char *)ssid, (char *)wifipw); while (WiFi.status() != WL_CONNECTED) { Serial.print('.'); delay(150); } Serial.println(); Serial.println("Connected- waiting for IP"); msave = millis(); while (WiFi.localIP() == INADDR_NONE) { Serial.print('.'); delay(150); if (millis()-msave > 5000) { Serial.println("Timeout waiting for IP; disconnecting & reconnecting."); WiFi.disconnect(); WiFi.begin((char*)ssid); msave = millis(); } } Serial.print(" done; IP="); IPAddress my_ip = WiFi.localIP(); Serial.println(my_ip); } void loop() { char buf[1025]; int i; size_t total = 0; WiFiClient http; Serial.println("Attempting HTTPS request-"); if (http.sslConnect("www.ti.com", 443)) { Serial.println("Connected to www.ti.com- submitting GET / HTTP/1.0 request"); http.print("GET / HTTP/1.0\r\nHost: www.ti.com\r\n\r\n"); Serial.println("Waiting for response..."); while (http.connected()) { while (!http.available()) delay(50); i = http.read((uint8_t *)buf, 1024); buf[i] = '\0'; total += i; //Serial.print(buf); } Serial.println("Disconnected by remote host."); Serial.print(total); Serial.println(" bytes read in total."); delay(100000000); } else { Serial.println("Error connecting to www.ti.com"); } } Output from serial monitor:
    WiFi: .. Connected- waiting for IP ............... done; IP=192.168.0.195 Attempting HTTPS request- Connected to www.ti.com- submitting GET / HTTP/1.0 request Waiting for response... Disconnected by remote host. 87527 bytes read in total.
×
×
  • Create New...