forked from stfc/ardublock
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add block guino pause in communication
- Loading branch information
Showing
6 changed files
with
44 additions
and
1 deletion.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
src/main/java/com/ardublock/translator/block/Duinoedu/Guino_Pause.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package com.ardublock.translator.block.Duinoedu; | ||
|
||
import com.ardublock.translator.Translator; | ||
import com.ardublock.translator.block.TranslatorBlock; | ||
import com.ardublock.translator.block.exception.SocketNullException; | ||
import com.ardublock.translator.block.exception.SubroutineNotDeclaredException; | ||
|
||
public class Guino_Pause extends TranslatorBlock { | ||
|
||
public Guino_Pause (Long blockId, Translator translator, String codePrefix, String codeSuffix, String label) | ||
{ | ||
super(blockId, translator, codePrefix, codeSuffix, label); | ||
} | ||
|
||
//@Override | ||
public String toCode() throws SocketNullException, SubroutineNotDeclaredException | ||
{ | ||
translator.addHeaderFile("EasyTransfer.h"); | ||
translator.addHeaderFile("EEPROM.h"); | ||
translator.addHeaderFile("Guino.h"); | ||
translator.addDefinitionCommand("int GuinoInterrupteurvirtuel = 0 ;"); | ||
translator.addDefinitionCommand("//libraries at http://duinoedu.com/dl/lib/dupont/EDU_Guino/"); | ||
translator.addSetupCommand("GUINO_BRANCHER();"); | ||
translator.addGuinoCommand(" GUINO_AFFICHER_PAUSE(GuinoInterrupteurvirtuel);"); | ||
|
||
return "GUINO_GERER_PAUSE(GuinoInterrupteurvirtuel);" ; | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.