Skip to content

Commit ecd1835

Browse files
committed
Merge pull request #6 from jadonk/master
Update to 0.2.2
2 parents f7a8fc6 + 031adc9 commit ecd1835

14 files changed

Lines changed: 1314 additions & 10 deletions

File tree

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,14 @@ There's still a lot of development going on, so be sure to check back on a
4141
frequent basis. Many of the fancier peripherals aren't yet supported
4242
except through performing file I/O.
4343

44+
Directory layout
45+
----------------
46+
* attic: Stuff not to throw away, but not in a good state
47+
* demo: Examples showing how to use the BoneScript library
48+
* etc: Configuration files to be placed in target distro
49+
* node\_modules: Library code
50+
* systemd: Configuration files for systemd to start services
51+
* test: Automated test code
4452

4553
Template
4654
========
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

extras/edid.js

Lines changed: 1041 additions & 0 deletions
Large diffs are not rendered by default.

extras/readedid.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
var b = require('bonescript');
2+
var fs = require('fs');
3+
var Edid = require('./edid');
4+
fs.readFile('/sys/class/drm/card0/card0-HDMI-A-1/edid', printStatus);
5+
function printStatus(err, data) {
6+
//b.readTextFile('/sys/class/drm/card0/card0-HDMI-A-1/edid', printStatus);
7+
//function printStatus(x) {
8+
// var data = string2Bin(x.data);
9+
for(var i = 0; i < data.length && i < 100; i++) {
10+
//console.log(i + ': ' + data.charCodeAt(i));
11+
console.log(i + ': ' + data[i]);
12+
}
13+
var edid = new Edid();
14+
edid.setEdidData(data);
15+
edid.parse();
16+
console.log('valid = ' + edid.validHeader);
17+
console.log('eisaId = ' + edid.eisaId);
18+
console.log('productCode = ' + edid.productCode);
19+
console.log('serialNumber = ' + edid.serialNumber);
20+
console.log('manufactureDate = ' + edid.manufactureDate);
21+
console.log('edidVersion = ' + edid.edidVersion);
22+
console.log('bdp = ' + JSON.stringify(edid.bdp));
23+
console.log('chromaticity = ' + JSON.stringify(edid.chromaticity));
24+
console.log('exts = ' + JSON.stringify(edid.exts));
25+
}
26+

node_modules/bonescript/index.js

Lines changed: 18 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)