I am using ESP8266 Arduino ConfigFile.ino as an example to store configuration settings on SPIFFS.
https://github.com/esp8266/Arduino/blob/master/libraries/esp8266/examples/ConfigFile/ConfigFile.ino
From this code segment, configFile cannot be >1024 bytes.
size_t size = configFile.size();
if (size > 1024) {
Serial.println("Config file size is too large");
return false;
}
Why is 1024 bytes the limitation for config file size? If this is indeed a limitation, are there ways to overcome this limitation?
It's a limitation only in this particular example - It's meant to serve as a basis for you to start developing your own configuration file code. Nothing is stopping you from creating a larger buffer for both the raw character data and JsonBuffer. I have several configuration files on production devices around 10-20K with no issues to report.
Related
i would like to get all the data present in the trace window to my text file, even log recording can help but it can't display date and time in that file, so i've a plan to copy entire trace window to file.
i've tried to do ctrl+a and paste in notepad, but it is just copying some sort of area only not all.
i would like to know is there any chance to redirect how trace window is printing like that i can see in text file, or at least is there any way to copy entire file and paste in text file.
The trace windows just display the data, you configure it in the Measurement Setup.
But be aware that this will be only a part of the data anyway. There is a buffer where CANoe stores the data for the Trace window. You can configure the type of this buffer (memory or hard disk) and its size. Go to Options -> Measurement -> Data History to change your settings.
You can also configure the size of the visible data range there. But even with a very long range and a large 200 GB buffer, there might be a possibility that some data will not be available, because the Trace works as a ring buffer deleting the old data on overflow.
If you need the complete data, you should enable the Logging in the Measurement setup. Yes, the data files will be not human-readable. You will then need to open them in the Offline Mode in CANoe to analyze them. The timestamps will be of course logged, so you can easily use them for your analysis.
You could pretty-print it to the write window using CAPL:
on message *
{
int i;
write("[%07.3f] %03X", this.time / 100000.0, this.id);
for (i = 0; i < this.dlc; i++)
writeEx(0, 0, " %02X", this.byte(i));
}
And then export it to a file.
Or you write it directly to a file.
Hi I would suggest logging the necessary data into a CSV and then analyzing using Excel. You can make use of the File Access CAPL functions like openFileWrite for the same
Right now I was printing all of my data into a PDF using FPDF and those data contains pictures with a large image sizes. Then my the XAMPP promt like following text below. What is the following solution in order for me to proceed printing? Is their a solution without changing the images size?
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 50933016 bytes) in C:\xampp\htdocs\techgirl\reports\fpdf.php on line 1449
Even I tried to change the memory limit in my php.ini into 900M nothing happen.
Change the memory_limit option in your php.ini to your needs.
Change the memory_limit option in your php.ini to your needs.
Then Restart the Apache server from XAMPP
Change memory_limit to -1 in php.ini. i.e memory_limit=-1
You can find php.ini file in bin/php/
I need to compress data sent over a secure channel in my iOS app and I was wondering if I could use TLS compression for the same. I am unable to figure out if Apple's TLS implementation, Secure Transport, supports the same.
Does anyone else know if TLS compression is supported in iOS or not?
I was trying to determine if Apple implementation of SSL/TLS did support compression, but I have to say that I am afraid it does not.
At first I was hopeful that having a errSSLPeerDecompressFail error code, there has to be a way to enable the compression. But I could not find it.
The first obvious reason that Apple doesn’t support compression is several wire captures I did from my device (6.1) opening secure sockets in different ports. In all of them the Client Hello packet reported only one compression method: null.
Then I looked at the last available code for libsecurity_ssl available from Apple. This is the implementation from Mac OS X 10.7.5, but something tells me that the iOS one will be very similar, if not the same, but surely it will not be more powerful than the Mac OS X one.
You can find in the file sslHandshakeHello.c, lines 186-187 (SSLProcessServerHello):
if (*p++ != 0) /* Compression */
return unimpErr;
That error code sounds a lot like “if the server sends another compression but null (0), we don’t implement that, so fail”.
Again, the same file, line 325 (SSLEncodeClientHello):
*p++ = 0; /* null compression */
And nothing else around (DEFLATE is the method 1, according to RFC 3749).
Below, lines 469, 476 and 482-483 (SSLProcessClientHello):
compressionCount = *(charPtr++);
...
/* Ignore list; we're doing null */
...
/* skip compression list */
charPtr += compressionCount;
I think it is pretty clear that this implementation only handles the null compression: it is the only one sent in the Client Hello, the only one understood in the Server Hello, and the compression methods are ignored when the Client Hello is received (null must be implemented and offered by every client).
So I think both you and me have to implement an application level compression. Good luck.
my php.ini values
upload_max_size = 14000M
post_max_size = 14000M
if i increase value more than 14000M, $_POST can't be accessed and using that value i can upload a file of 1.5GB only and can't upload a file of 2.14GB.
Here i have three questions
What should i do so $_POST array also keep in working and i can also
upload a file of 2.14 GB.
Why $_POST is not working when i exceed
value more than 14000M
14000M should mean 14GB, isn't so? if so
then why i can't upload file of 2.14GB
i found answer to my question after 2 days work.
This is a bug in PHP which allow us to put *_max_size = 14000M and don't allow us to upload a file of 14000MB.
Reference https://bugs.php.net/bug.php?id=35578
We can't upload file for more than 2047MB, so following values are meaning less
upload_max_size = 14000M
post_max_size = 14000M
and should be converted to its maximum value like
upload_max_size = 2047M
post_max_size = 2047M
So now you can upload about 1.99GB File
THere is no only upload_max_size and post_max_size that affect on file upload. Check this link
The most important is memory_limit. when you tring to upload big file, php run out memory
I have had luck using G (Gigs) in my php.ini file:
upload_max_size = 3G
post_max_size = 3G
Not sure if this will help with the $_POST issue.
There are much more limitations and pitfalls you have to check for, see oficial PHP documentation: http://www.php.net/manual/en/features.file-upload.common-pitfalls.php
Anyway, note that the 2G is also a limit of signed 32bit integer! So this problem might rise from some other limits unrelated to upload itself. Also, what is the maximum file size on the server filesystem? 2G is a limit on some systems.
How the GTP-u content being dissected by Wireshark?
Is the content inside GTP-U also encrypted if i don't have the ipsec over it?
I have some G711 PCMU content with GTP tunneling as shown by Wireshark but i am seeing there are two packets with the same content everywhere but the IPs are different.
I am not able to understand how this has been dis-sected and is the content really encrypted or not as in generally the frame size of the PCMU content is 160 bytes without RTP header but here i am seeing only 32 bytes without header.
Anyone has any idea on this GTP-U content or can provide me some documents or resource to understand the same?
Thanks
Nitin
GTP-U does not specify encryption for the payload; it is encapsulated as-is.
To read about GTP, see 3GPP TS 29.060.