I was using a simple sketch to do some firmware troubleshooting and wanted to use the OakTerm to just show that things were running OK w no online/offline loops active. I stuck in a Particle.variable to have something to see in OakTerm as well as using a Particle.print() statement. For the Particle.variable, I threw in a variable name in quotes of "HI! " just to see it and a loopcounter
Particle.variable("HI! ", loopcounter)
and this threw the following errors. Not sure if you want to trap for this or if this is a Particle error message, but didn't like my whimsical variable name with a special character and a space. Changed to Particle.variable ("HI", loopcounter) and all OK. Interestingly, OakTerm dumped the error stuff per below but still followed on with the Particle.print() stuff and didn't crash...
Not sure if a variable name should be filtered and truncated at the last legal character or don't worry about the odd person using an illegal variable name just to pass a message...I will use Particle.println("my message") in the future, but it is an easy way to see a loop counter without any number to string stuff...as long as the variable name is legal.
James
[15:05:15] Event: Hi! - again [15:05:15] Hi 2 [15:05:15] Unknown error encountered: {"stack":"Error: Syntax error, unrecognized expression: .btn-var-HI!\n at Function.ga.error (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:12481)\n at ga.tokenize (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:18408)\n at ga.select (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:21136)\n at Function.ga [as find] (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:7114)\n at n.find (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:23410)\n at n.fn.init (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:23954)\n at n (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:405)\n at http://rawgit.com/kh90909/OakTerm/master/assets/js/app.js:234:11\n at Function.m.each.m.forEach (http://rawgit.com/kh90909/OakTerm/master/assets/vendor/underscore-min.js:5:2410)\n at update_devinfo (http://rawgit.com/kh90909/OakTerm/master/assets/js/app.js:221:9)","message":"Syntax error, unrecognized expression: .btn-var-HI!"} Please consider reporting a bug at https://github.com/kh90909/OakTerm/issues
Thanks for the report! This is a bug in the terminal code that we can remedy. I'll see if I can get this in by tonight, otherwise I can tackle it on Tuesday.
I was using a simple sketch to do some firmware troubleshooting and wanted to use the OakTerm to just show that things were running OK w no online/offline loops active. I stuck in a Particle.variable to have something to see in OakTerm as well as using a Particle.print() statement. For the Particle.variable, I threw in a variable name in quotes of "HI! " just to see it and a loopcounter Particle.variable("HI! ", loopcounter) and this threw the following errors. Not sure if you want to trap for this or if this is a Particle error message, but didn't like my whimsical variable name with a special character and a space. Changed to Particle.variable ("HI", loopcounter) and all OK. Interestingly, OakTerm dumped the error stuff per below but still followed on with the Particle.print() stuff and didn't crash... Not sure if a variable name should be filtered and truncated at the last legal character or don't worry about the odd person using an illegal variable name just to pass a message...I will use Particle.println("my message") in the future, but it is an easy way to see a loop counter without any number to string stuff...as long as the variable name is legal.
James
[15:05:15] Event: Hi! - again [15:05:15] Hi 2 [15:05:15] Unknown error encountered: {"stack":"Error: Syntax error, unrecognized expression: .btn-var-HI!\n at Function.ga.error (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:12481)\n at ga.tokenize (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:18408)\n at ga.select (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:21136)\n at Function.ga [as find] (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:7114)\n at n.find (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:23410)\n at n.fn.init (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:23954)\n at n (https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js:2:405)\n at http://rawgit.com/kh90909/OakTerm/master/assets/js/app.js:234:11\n at Function.m.each.m.forEach (http://rawgit.com/kh90909/OakTerm/master/assets/vendor/underscore-min.js:5:2410)\n at update_devinfo (http://rawgit.com/kh90909/OakTerm/master/assets/js/app.js:221:9)","message":"Syntax error, unrecognized expression: .btn-var-HI!"} Please consider reporting a bug at https://github.com/kh90909/OakTerm/issues