BGS5T character encoding and attaching data in HTTP POST | Thales IoT Developer Community
November 27, 2014 - 11:09am, 8687 views
I have a problem with HTTP request. When I use AT commands module encodes underscore ("_") as \u00a7. So may api key in header is changed and I can't make that POST request.
When I use Java and httpconnection my form is emptey but apikey is correctly encoded. In form data have to be shaped like .csv. Example:
So do you have any advice how can I add data to the form, or change encoding with AT commands. When doing that I tryed with:
But without success.
Here is my Java code:
For the at commands encoding please see the AT+CSCS command. The default character set is GSM. Then the underscore "_" should be send as \11 There's also a separate chapter in the AT commands specification: 1.7 Supported character sets.
For Java I would try to add getResponseCode() first. I'd also recommend you to see the POST example in the HttpConnection API for the module.
I have found the problem. I added ":" to header names, and it looks that BGS5 automaticly adds : to some headers. So when I removed ':' it was ok.
Thank you for your help
Now I can see that...