Skip to content
/ binjs Public

Reading and writing structured binary files to transfer over http protocol.

Notifications You must be signed in to change notification settings

meracan/binjs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

binjs

Read and write binary files to transfer data over http protocol.

Installation

npm i -s @meracan/binjs
# or
git clone 

Test

Using node, only works with >12

npm start

Bundler and transcompiler

Webpack is used to bundle the code. Babel can be used to transcompile the code but commented out at the moment.

npm run build

File format

1H - Should be 1 (This is to check the endiness of the file)
1B - Number of variables

For each variable:
16s       - Variable name
1s        - Type (e.g. B,H,I,b,h,i)
1I        - Size of array
1B        - Number of dimension (e.g. 1D, 2D)
ndim*I    - Shape of array
size*Type - data

Type reminder

"B":Uint8Array,
"H":Uint16Array,
"I":Uint32Array,
"Q":BigUint64Array,
"b":Int8Array,
"h":Int16Array,
"i":Int32Array,
"q":BigInt64Array,
"f":Float32Array,
"d":Float64Array,

About

Reading and writing structured binary files to transfer over http protocol.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published