2.10.0 Firmware Won't Print(integer)

Report any thing that looks like a bug or problem in the system here

Moderators: JeffC, stieg

Post Reply
JJLudemann
Posts: 16
Joined: Thu Apr 14, 2016 12:53 pm
Location: Pattaya, Thailand
Contact:

2.10.0 Firmware Won't Print(integer)

Post by JJLudemann »

I just upgraded to 2.10.0 and my working script no longer works. So I downgraded to 2.9.2, and the script started working again.

One issue appears to be that print() and println() no longer automatically convert integers to strings as expected in standard Lua. Instead, I get an error about initSer expecting a string in position 1. So I added a tostring(integer) to convert the contents of the variable to a string before printing, and that works.

More importantly, there seems to be another problem in comparison of an integer to a hex constant, such that my script never finds the header its looking for. I didn't have the time to chase this one all the way down, but here's some of the script below. The script is reading packets from the auxiliary serial port and storing the values in the virtual channels.

-JJ

P.S. I have to complete a Captcha every time I preview this post, even though I'm not logged in. This is not optimal...
Attachments
Kline2Arduino.txt
(2.67 KiB) Downloaded 345 times
LudemannEngineering.com

JJLudemann
Posts: 16
Joined: Thu Apr 14, 2016 12:53 pm
Location: Pattaya, Thailand
Contact:

Replicated the problem, now bluetooth is dead

Post by JJLudemann »

It's definitely a firmware upgrade problem. My bluetooth connection also stopped working, so I upgraded again to 2.10.0 to see if that fixes the bluetooth, and the script stopped working again but not the bluetooth. So I downgraded the firmware to 2.9.0 and the script started working again. Still didn't fix the bluetooth, which is a real problem for me as I have to get on the track next week and won't have a lap time display. If I could connect the RaceCapturePro2 to my Android phone over USB that would be fine, but that's not implemented as far as I can tell.

My bluetooth connection is showing as "Initialized" in System Status. Bluetooth is "On" in Setup>Wireless. The LED on the bluetooth module is blinking steadily about 4 times per second. The RaceCapturePro shows up in available bluetooth devices on my Android phone, but when I try to pair, it asks for the code, I enter it, and it says "Unable to communicate with RaceCapturePro". I've reloaded the passcode via Setup>Wireless>Advanced, powered down and rebooted several times, and restarted the RaceCapture app several times. I've also tried a virgin smartphone with the same result.

-JJ
LudemannEngineering.com

JJLudemann
Posts: 16
Joined: Thu Apr 14, 2016 12:53 pm
Location: Pattaya, Thailand
Contact:

Bluetooth problem is a hardware failure

Post by JJLudemann »

A friend sent me his RaceCapturePro2 (the only two in Thailand are now in my garage?) and with a second unit it was easy to determine that my bluetooth module has failed. How do I get a replacement? Or can I cobble one together from off-the-shelf components I can source in Asia?

-JJ
LudemannEngineering.com

brentp
Site Admin
Posts: 6282
Joined: Wed Jan 24, 2007 6:36 am

Post by brentp »

Hi,

With your bluetooth module, can you paste the unit's log file when you first power up the unit? We'll be looking for messages related to bluetooth initialization.

also, can you create a simple script that reproduces your scripting problem on 2.10.0 so we can test over here?

Thanks,
Brent Picasso
CEO and Founder, Autosport Labs
Facebook | Twitter

JJLudemann
Posts: 16
Joined: Thu Apr 14, 2016 12:53 pm
Location: Pattaya, Thailand
Contact:

Post by JJLudemann »

brentp wrote:Hi,

With your bluetooth module, can you paste the unit's log file when you first power up the unit? We'll be looking for messages related to bluetooth initialization.

also, can you create a simple script that reproduces your scripting problem on 2.10.0 so we can test over here?

Thanks,
When I paste the log into Windows Notepad, I only get Chinese characters, so here's a photo of the screen. One thing that might be interesting is that my friend's bluetooth module is larger and made more recently than mine.

I'll send you a simpler script soon.

Thanks in advance,

-JJ
Attachments
RaceCapture Pro Mk. 2 startup log
RaceCapture Pro Mk. 2 startup log
RaceCaptureLog1.jpg (160.88 KiB) Viewed 12189 times
LudemannEngineering.com

JJLudemann
Posts: 16
Joined: Thu Apr 14, 2016 12:53 pm
Location: Pattaya, Thailand
Contact:

Post by JJLudemann »

brentp wrote:Hi,

With your bluetooth module, can you paste the unit's log file when you first power up the unit? We'll be looking for messages related to bluetooth initialization.

also, can you create a simple script that reproduces your scripting problem on 2.10.0 so we can test over here?

Thanks,
Here's a script that works under 2.9.2 and doesn't work under 2.10.0 . I also tried putting in a print statement to check if I ever get a valid compare, and I never do. The problem is not that the print statement is not working, as the virtual channel never gets updated, either.
Attachments
Kline2ArduinoMimimalTest.txt
Script to read aux serial, look for header, read data packet, update virtual channel
(1.42 KiB) Downloaded 370 times
LudemannEngineering.com

Post Reply