Beta8397 / virtual_robot

A 2D robot simulator to help beginners learn Java programming for FTC Robotics
100 stars 171 forks source link

Telemetry behavior needs to follow FTC SDK more closely #40

Closed jkenney2 closed 3 years ago

jkenney2 commented 3 years ago

@alan412

Currently, update() statement ALWAYS clears telemetry. That means that telemetry written during init() method doesn't persist. It gets cleared immediately by the call to telemetry.update() in the internalPostInitLoop() method.

For example, this breaks the Helloworld example in Learn Java For FTC.

I will do a little testing with the real SDK and Android Studio to figure out how this behaves, and make some changes.

jkenney2 commented 3 years ago

The appropriate behavior seems to be:

  1. If there has been a call to telemetry.addData since the last update, then telemetry.update() will clear existing telemetry, then write new telemetry.

  2. If there has not been a call to telemetry.addData since the last update, then telemetry.update() does nothing.

alan412 commented 3 years ago

I believe that to be correct.

On Mon, Aug 24, 2020 at 9:05 PM jkenney2 notifications@github.com wrote:

The appropriate behavior seems to be:

1.

If there has been a call to telemetry.addData since the last update, then telemetry.update() will clear existing telemetry, then write new telemetry. 2.

If there has not been a call to telemetry.addData since the last update, then telemetry.update() does nothing.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Beta8397/virtual_robot/issues/40#issuecomment-679442675, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAF3Y755RQNKHEUCMP36I5LSCME5TANCNFSM4QJ52TNQ .

jkenney2 commented 3 years ago

Fixed.