Cast as integer

43 views
Skip to first unread message

Tim Semmelhaack

unread,
Dec 4, 2017, 3:49:07 PM12/4/17
to Open Roberta
I'm looking for a function that cast float into integer int() in python, because the repeat function only accepts integer.

Is it not available in the GUI at the moment or is there a workaround?

Tim

Kostadin Cvejoski

unread,
Dec 5, 2017, 2:29:45 AM12/5/17
to Open Roberta
Hi Tim,

At the moment we do not have a cast block, and I think there is no workaround at the moment.

However, we will discuss the problem and maybe we will add a cast block in our language.

Thank you

Stefan Sauer

unread,
Dec 5, 2017, 3:59:02 AM12/5/17
to Kostadin Cvejoski, Open Roberta
I think the codegen for the loops should implicitely cast, right? Tim, which robot type is it?


--
You received this message because you are subscribed to the Google Groups "Open Roberta" group.
To unsubscribe from this group and stop receiving emails from it, send an email to open-roberta...@googlegroups.com.
To post to this group, send email to open-r...@googlegroups.com.
Visit this group at https://groups.google.com/group/open-roberta.
To view this discussion on the web visit https://groups.google.com/d/msgid/open-roberta/f2a4e3f3-f4ee-4a59-906a-4adc71d9f62e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Stefan Sauer | Software Engineer | ens...@google.com

Google Germany GmbH | Erika-Mann-Str 33 | 80636 München | Germany
Geschäftsführer: Paul Manicle, Halimah DeLaine Prado
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg

Diese E-Mail ist vertraulich. Wenn Sie nicht der richtige Adressat sind, leiten Sie diese bitte nicht weiter, informieren Sie den Absender und löschen Sie die E-Mail und alle Anhänge. Vielen Dank.
       
This e-mail is confidential. If you are not the right addressee please do not forward it, please inform the sender, and please erase this e-mail including any attachments. Thanks.

Tim Semmelhaack

unread,
Dec 5, 2017, 4:38:02 PM12/5/17
to Open Roberta
I work with the EV3 ev3dev.
The robot shows a float error when I use the loop with a division, so I don't think there an implicitely cast.

Stefan Sauer

unread,
Dec 6, 2017, 1:42:03 PM12/6/17
to semme...@gmail.com, Open Roberta
Filed a new ticket here:
We'll need to check all python based code generators for this.



For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages