Hello,
that's my first post here, so hi everybody I'm writing a small extension to BYOB that will talk to the Arduino board over serial. I want BYOB to receive data from Arduino every 100ms (exact timing is not critical), so I thought I'll go with Morph stepping to do that. If I'm correct, I have to add a morph to the World, to use stepping. Unfortunately, when I try to do that, VM crashes and goes to emergency evaluator. What am I doing wrong? The code for test class is below:
Morph subclass: #StepTest instanceVariableNames: 'c1 ' classVariableNames: '' poolDictionaries: '' category: 'Test'
StepTest>>initialization
initialize super initialize. c1 _ 0. World addMorphBack: self
It crashes when I call StepTest new. Oh, BTW, with normal Scratch it works just fine.
Of course, if there's a way to do some periodic activity without stepping, it will be ok also.
Offline
I think mactro accidentally hit report rather than quote Here's what he said:
mactro wrote:
I have found a mistake - the code above was copied from working Scrach version - in BYOB it lacked "super initialize". After adding it, all works fine, so the topic can be deleted.
Offline