Hello!
I am completely new to this, so excuse (and correct) any mistakes and please bear with me.
I am developing a packaged chrome app that communicates with a serial device. To make a long story short, here are the facts:
Thanks in advance
I am completely new to this, so excuse (and correct) any mistakes and please bear with me.
I am developing a packaged chrome app that communicates with a serial device. To make a long story short, here are the facts:
- I can open a connection successfully with the serial port when a page loads
- I can execute a particular command that takes about 20-60 seconds to return whether or not it was successful using a button.
- I cannot, consistently, execute the same command as above when a page loads.
- Chaining the function that executes the command with other functions and then firing them onload.
- Using setTimeout to run the function a while after the page loads.
- Using a while loop that checks whether the function has been fired before or not (usually ends up running the command twice or none at all)
- Inserted breakpoints to identify the problem (hint. the function fires but when it is time to connect to the serial port using the Chrome API something goes wrong)
Thanks in advance