Skip to main content

A Python library for decoding FastNet protocol data streams.

Project description

pyfastnet

Fastnet is the propriatory protocol used by B&G on some older instruments, tested on Hydra/H2000. It might work on other systems. I developed this for personal use and publishing for general interest only.

Purpose

This library can be fed a stream of fastnet data, it will decode and return structured instrument data for further processing. Syncronisation, checksum and decoding is handled by the library.

Example input/output

Byte string from Fastnet including "FF051601E555610030566100185903A86B7F8700BB00016D08CD0DCB"

to_address: Entire System
from_address: Normal CPU (Wind Board in H2000)
command: Broadcast

  • True Wind Speed (Knots):

    • channel_id: 0x55
    • interpreted: 4.8
  • True Wind Speed (m/s):

    • channel_id: 0x56
    • interpreted: 2.4
  • True Wind Angle:

    • channel_id: 0x59
    • interpreted: 107.0
  • Velocity Made Good (Knots):

    • channel_id: 0x7F
    • interpreted: 0.01
  • True Wind Direction:

    • channel_id: 0x6D
    • interpreted: 269.0

Important library calls - function

  • fastnetframebuffer.add_to_buffer(raw_input_data)
  • fastnetframebuffer.get_complete_frames()

# Important library calls - debug

  • set_log_level(DEBUG)
  • fastnetframebuffer.get_buffer_size()
  • fastnetframebuffer.get_buffer_contents()

Companion App

  • A full implementation can be found here, it takes input from a serial port or dummy file and broadcasts NMEA messages via UDP fastnet2ip

Installation

pip3 install pyfastnet

On a raspberry pi and some other systems this is done from with a virtual env

source ~/python_environment/bin/activate
pip3 install pyfastnet
deactivate
~/python_environment/bin/python3 pyfastnet.py -h 

Acknowledgments / References

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyfastnet-1.1.4.tar.gz (14.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyfastnet-1.1.4-py3-none-any.whl (13.2 kB view details)

Uploaded Python 3

File details

Details for the file pyfastnet-1.1.4.tar.gz.

File metadata

  • Download URL: pyfastnet-1.1.4.tar.gz
  • Upload date:
  • Size: 14.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for pyfastnet-1.1.4.tar.gz
Algorithm Hash digest
SHA256 85e4f4b5e439ed1e235c4bc30e5363bef905b9e3c4f465eb5c22a0ab1d35768c
MD5 cee732731d74f4b3eef9618fa4050224
BLAKE2b-256 7a7eb27755140ff18a55459f2e8b713cb9ae7058a2d635bce805807ebae87e6e

See more details on using hashes here.

File details

Details for the file pyfastnet-1.1.4-py3-none-any.whl.

File metadata

  • Download URL: pyfastnet-1.1.4-py3-none-any.whl
  • Upload date:
  • Size: 13.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for pyfastnet-1.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 c9cef8e790d435bed1d903011ef0d196f66c2420044e3fb557803f937b055509
MD5 353b8cb2da2a01b5ee8c9c820804f86f
BLAKE2b-256 b2db2e3c10084474c60ccf15aeb5d96f4eb8db3929107538d4c73b1b2a32cfcd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page