Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
ardublockly
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
ardublockly
Commits
19442b2b
Commit
19442b2b
authored
Feb 23, 2015
by
carlosperate
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added static typing to the time blocks.
parent
7588cbcb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
blocks/arduino/time.js
blocks/arduino/time.js
+14
-0
No files found.
blocks/arduino/time.js
View file @
19442b2b
...
...
@@ -68,6 +68,13 @@ Blockly.Blocks['time_millis'] = {
this
.
setOutput
(
true
,
'
Number
'
);
this
.
setTooltip
(
'
Returns the number of milliseconds since the Arduino
'
+
'
board began running the current program.
'
);
},
/**
* Retrieves the type of the block, should be a long (32bit), but for for
* now an int.
*/
getType
:
function
()
{
return
'
int
'
;
}
};
...
...
@@ -84,5 +91,12 @@ Blockly.Blocks['time_micros'] = {
this
.
setOutput
(
true
,
'
Number
'
);
this
.
setTooltip
(
'
Returns the number of microseconds since the Arduino
'
+
'
board began running the current program.
'
);
},
/**
* Retrieves the type of the block, should be a long (32bit), but for for
* now an int.
*/
getType
:
function
()
{
return
'
int
'
;
}
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment