Transform the live positions of the BVG autonomous shuttle into a GTFS-Realtime vehicle positions feed.
npm install bvg-shuttle-gtfs-rt-feed
const fs = require('fs')
const csvParser = require('csv-parser')
const toGtfsRt = require('bvg-shuttle-gtfs-rt-feed')
const convert = toGtfsRt()
fs.createReadStream('vehicle_states.csv')
.pipe(csvParser())
.pipe(convert)
.pipe(…)
convert
ist a transform stream that emits Protobuffer GTFS-Realtime VehiclePosition
updates.
Download the data from https://hackathon.innoz.de/data and extract it. In the future, this library will fetch liva data from a server.
cat vehicle_states.csv | node example.js >positions.pbf
If you have a question or have difficulties using bvg-shuttle-gtfs-rt-feed
, please double-check your code and setup first. If you think you have found a bug or want to propose a feature, refer to the issues page.