Hi
I've had a further look.
First I'd like to say that I haven't yet used the Accelerometer nor Oximeter components myself, so the following is a "best guess" from WiKi / simulation
As mentioned earlier, all initialising settings can be at the beginning and this could include the ESP connecting to WiFi / server too. You don't mention how many samples per second/minute/hour you need, so I assume you will gather as fast as you can? I won't comment on the ESP settings yet as I need to refresh my memory as it was quite a few months since I last used, and I think I just used the UART.
The Accelerometer returns 12-bit readings for x/y/z however you forgot to assign an integer variable, only the default byte, which can only deal with 8-bit values. This would cause incorrect readings. Similarly, the Oximeter needs to deal with 16-bit numbers but again only a default Byte has been assigned. Incidentally it's good practise to assign an initial value to each variable so it always starts at a known value.
Although you initialised both these components, you forgot to include the associated "update" command, which actually obtains all data from sensor(s), before you collect/read samples. Easy to overlook.
Although not necessary for simulation, I see that your set IR/Red values are a bit low, although I stress I am only going on what I've read. I think the IR needs 50mA which equates to 15 and Red needs around 27mA which I guess equates to around 8.
I can't really comment on pulse width nor sampling rate as I haven't used the components, but I guess 20mS and 50Hz are a good match.
I've modified your chart config and to have all initialising at the beginning but I've "disabled" all ESP associated commands as I haven't looked into them yet. If you run the chart in simulation (either Fast with Updates or just Step-Thru) with the Simulation Debugger set to show your x/y/x and hrate/oxm variables, you will see them change as you adjust the respective sliders. Note the accelerometer component only shows integer values of 0/1/2 but the returned readings show the full 12-bit value. A little bug I think
As to creating a string to send, you first need to establish how the receiver demands the data as you must create a string the receiver can read. If you can let us know what format we can help with creation, but it should be an easy enough string calculation.
As an aside, I was playing with Excel DataStreamer with mixed results. Although as documented in an earlier post I can send data and it can accept and display, when it saves the data it somehow screws it up. The CSV formatting gets corrupted so instead of, for example
13.03,24.14(\n)13.04,24.15(\n)
It saves as 13.03,24.14.13,04.24.15 and the data is imported as a very long single row....
Possibly a problem in Excel that an update / patch may fix, still looking into it but it's not a big priority. If I am connecting directly to a PC then I would most likely use Flowcode App Developer as it allows me far greater control over everything, and if I was just wishing to capture data as in your example and I had an Internet connection, I would probably send to ThingSpeak or such like as that eliminates the need for a PC entirely. Data can be read/ viewed online and downloaded.
I hope the attached helps and I'll look at the ESP8266 part later
Regards
EDIT...
Just read your other post re compilation. The above won't compile either for similar reasons but does illustrate how to read the sensors.