cybernetics-library / distributed-gardens

3 stars 0 forks source link

distributed-gardens

Viz

Look in the viz/ folder for more instructions.

Scanner

If you are running the scanner on a raspberry pi, you'll need to enable the camera in preferences and then add the following lines of code.

In terminal sudo nano /etc/modules and add the line bcm2835-v4l2. This makes a reference to a video stream from the native camera module at /dev/video0. This should allow chromium to request the video stream.

Reference

V1 Event message format

Events/transactions are stored as a single entry with timestamp & data

Examples:

Scan - badge 23456 scanning into a kiosk

{
  'ver': 1,
  'ts': 1531764520.1234,
  'from': { name: 'kiosk_2_hallway' },
  'type': 'scan', 
  'msg': { 'gid': 23456' } 
}

Linking between gardens (badges) 11111 and 22222

{
  'ver': 1,
  'ts': 1531764520.1234,
  'from': { name: 'kiosk_1_hallway' },
  'type': 'link',
  'msg': { 'link_from': '11111', 'link_to': '22222' }
}

Seeding - badge 12345 adding data (seeding to) '33333' via a kiosk

{
  'ver': 1,
  'ts': 1531764520.1234,
  'from': { name: 'web_microsite' },
  'type': 'seed', 
  'msg': { 'seed_by': '12345', 'seed_to': '33333', media: [{ .. IA metadata format here}] }
}

Set info - badge 56789 adding info to their own garden

{
  'ver': 1,
  'ts': 1531764520.1234,
  'from': { name: 'kiosk_2_hallway' },
  'type': 'setinfo', 
  'msg': { 'badge_id': 56789', 'name': 'Alice Abbasi', 'email': 'aliceabbasi@example.com' } 
}

Gardens

Eventually, a garden will have this info: