Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Petite amélioration pour l'usine à bloc ? #143

Open
openelearning opened this issue Jan 8, 2019 · 0 comments
Open

Petite amélioration pour l'usine à bloc ? #143

openelearning opened this issue Jan 8, 2019 · 0 comments

Comments

@openelearning
Copy link

openelearning commented Jan 8, 2019

Hello,

Peut-être une amélioration pour l'usine à bloc :

  1. Aller dans l'usine à bloc : https://technologiescollege.github.io/Blockly-at-rduino/tools/factory/block_factory.html

  2. Dans les blocs connexion, ajouter le bloc name. ok.

  3. Dans le bloc name, ajouter un bloc champs > "variable item, NAME"

  4. Dans la fenêtre Blocks, au milieu à droite, est alors ajouté :
    .appendField(new Blockly.FieldVariable("item"), "NAME");

Suite aux corrections réalisées par Seb sur ce que j'avais proposé on peut observer que le code généré grâce à l'usine à bloc était :
.appendField(new Blockly.FieldVariable("moteurPap1"), "unipolar_stepper_motor_variable");
Alors que Seb l'a corrigé de cette manière (cf. 4641315 ) :
.appendField(new Blockly.FieldInstance('Stepper', Blockly.Msg.STEPPER_DEFAULT_NAME,false, false, false),'unipolar_stepper_motor_variable');

  1. Peut-être y a t'il une piste d'amélioration dans le genre que l'usine à bloc génère quelque chose du genre :
    .appendField(new Blockly.FieldInstance('item',Blockly.Msg.ITEM_DEFAULT_NAME,false, false, false), "NAME");

Pas sûr du tout de ce que j'avance ici...

@openelearning openelearning changed the title Propositions pour l'usine à bloc Petite amélioration pour l'usine à bloc ? Jan 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant