Error when going to scripting page in 2.8.3

Discussion on the Lua Scripting capabilities for RaceCapture/Pro. Also see the <a href="http://autosportlabs.net/RaceCapturePro_Lua_Scripting">Lua Scripting Guide</a>

Moderators: JeffC, stieg

Post Reply
Ls_Rx7
Posts: 23
Joined: Tue Jan 08, 2013 12:18 am
Location: Washington

Error when going to scripting page in 2.8.3

Post by Ls_Rx7 »

When I click on the scripting tab in V 2.8.3 I get an error that shows up on the screen.

"module" object has no attibute "pythonlexer"

Is scripting disabled in 2.8.3?
Attachments
Scripting error.jpg
Scripting error.jpg (165.1 KiB) Viewed 3872 times

toga94m
Posts: 127
Joined: Wed Jun 05, 2013 1:57 am
Location: Upstate NY

Post by toga94m »

Same here. http://www.autosportlabs.org/viewtopic.php?t=4521 But it's not 2.8.3, it's the app. Go back to 1.3.5 and you should be fine (mine works again). Scripting in 1.3.6 works on my Android tablet though...
------------
Learning Race Capture Pro... on someone else's car
Learning Python/Kivy on my own PC

Ls_Rx7
Posts: 23
Joined: Tue Jan 08, 2013 12:18 am
Location: Washington

Post by Ls_Rx7 »

Thanks. For the tip. I will try the script on my android tablet and if it doesn't work I will try 1.3.5.

Ls_Rx7
Posts: 23
Joined: Tue Jan 08, 2013 12:18 am
Location: Washington

Post by Ls_Rx7 »

I went back to 1.3.5 and the scripting tab worked. When I tried to write to my mk1 with the script it would get 1/2 to 2/3 of the way done And fail writing.

GTIspirit
Posts: 249
Joined: Wed Jan 09, 2013 11:20 am
Location: SE Michigan

Post by GTIspirit »

Ls_Rx7 wrote:I went back to 1.3.5 and the scripting tab worked. When I tried to write to my mk1 with the script it would get 1/2 to 2/3 of the way done And fail writing.
I see you found the bug report I filed on similar situation. I assume when it fails for you it locks up and stops working until you power cycle the unit.

Somehow I got the App and unit to accept my script, but only after writing config changes one by one, flashing after each one. It appears with the V2 firmware only incremental changes are flashed, not the entire config each time. Potential workaround may be to write all the config changes except for the script, then copy and paste the script in from a text editor and try flashing at that point. Somehow that got my script uploaded, but now I can't make changes to the script because then it locks up.

toga94m
Posts: 127
Joined: Wed Jun 05, 2013 1:57 am
Location: Upstate NY

Post by toga94m »

I'm just now starting to work with scripting. What I was seeing last night was similar- I'd edit script on the app, push the new config up to my RCP MK1, and 75% of the time it would hang, crash, reboot with red LED on (showing it was bypassing the script) and would come back online. At that point I could do edits and push them up again, and I'd have a better success rate. Then after a successful write, I'd powercycle the hardware to get the new script running again.

I'm guessing that the script engine is still processing the script while the config change is pushing the new script on top of the running script, and it gets confused.
------------
Learning Race Capture Pro... on someone else's car
Learning Python/Kivy on my own PC

Ls_Rx7
Posts: 23
Joined: Tue Jan 08, 2013 12:18 am
Location: Washington

Post by Ls_Rx7 »

GTIspirit wrote:
Ls_Rx7 wrote:I went back to 1.3.5 and the scripting tab worked. When I tried to write to my mk1 with the script it would get 1/2 to 2/3 of the way done And fail writing.
I see you found the bug report I filed on similar situation. I assume when it fails for you it locks up and stops working until you power cycle the unit.

Somehow I got the App and unit to accept my script, but only after writing config changes one by one, flashing after each one. It appears with the V2 firmware only incremental changes are flashed, not the entire config each time. Potential workaround may be to write all the config changes except for the script, then copy and paste the script in from a text editor and try flashing at that point. Somehow that got my script uploaded, but now I can't make changes to the script because then it locks up.
I installed the sequential shift light and was trying to load the script you wrote to control it. I was able to get the script to load once. But every time I tried to edit the script it would get 2/3rds of the way and error. I was able to delete the script and change the analog outputs one by one but still had no luck with the script. I thought about trying to write the script in small segments but I wasn't able to test it.

GTIspirit
Posts: 249
Joined: Wed Jan 09, 2013 11:20 am
Location: SE Michigan

Post by GTIspirit »

Ls_Rx7 wrote:
I installed the sequential shift light and was trying to load the script you wrote to control it. I was able to get the script to load once. But every time I tried to edit the script it would get 2/3rds of the way and error.
I have exactly the same problem. I can confirm that the script actually works in the V2 firmware, but I can't edit it in the app to change say blink frequency or rpm limits, same experience as you described. Maybe the workaround is as you described, delete it and reload it new with the changed values.

Ls_Rx7
Posts: 23
Joined: Tue Jan 08, 2013 12:18 am
Location: Washington

Post by Ls_Rx7 »

GTIspirit wrote:
Ls_Rx7 wrote:
I installed the sequential shift light and was trying to load the script you wrote to control it. I was able to get the script to load once. But every time I tried to edit the script it would get 2/3rds of the way and error.
I have exactly the same problem. I can confirm that the script actually works in the V2 firmware, but I can't edit it in the app to change say blink frequency or rpm limits, same experience as you described. Maybe the workaround is as you described, delete it and reload it new with the changed values.
I have been playing around with scripts more and found out that after the error displays my race capture will restart. Once it restarts and connects to the app I can load a script and have it complete.

Ls_Rx7
Posts: 23
Joined: Tue Jan 08, 2013 12:18 am
Location: Washington

Post by Ls_Rx7 »

Ls_Rx7 wrote:
GTIspirit wrote:
Ls_Rx7 wrote:
I installed the sequential shift light and was trying to load the script you wrote to control it. I was able to get the script to load once. But every time I tried to edit the script it would get 2/3rds of the way and error.
I have exactly the same problem. I can confirm that the script actually works in the V2 firmware, but I can't edit it in the app to change say blink frequency or rpm limits, same experience as you described. Maybe the workaround is as you described, delete it and reload it new with the changed values.
I have been playing around with scripts more and found out that after the error displays my race capture will restart. Once it restarts and connects to the app I can load a script and have it complete.
This method worked a few times but does not work anymore. I have been trying 2.8.1 and 2.8.3 on 3 different computers and my tablet. Anytime I have a script loaded I get an error message and cannot save the script.

dvsu12
Posts: 18
Joined: Sun May 17, 2015 11:02 pm

Post by dvsu12 »

Guys, am having the same issue but with version 2.8.4 firmware. App is ver1.3.7.

Is there a fix for this?

dvsu12
Posts: 18
Joined: Sun May 17, 2015 11:02 pm

Post by dvsu12 »

Never mind, app ver was 1.3.6. Upgraded to ver 1.3.7 and was all good.

Post Reply