Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nrkno/sofie-mos-connection
Sofie MOS Connection: A Part of the Sofie TV Studio Automation System
https://github.com/nrkno/sofie-mos-connection
automation mos sofie
Last synced: 3 months ago
JSON representation
Sofie MOS Connection: A Part of the Sofie TV Studio Automation System
- Host: GitHub
- URL: https://github.com/nrkno/sofie-mos-connection
- Owner: nrkno
- License: mit
- Created: 2018-03-21T13:53:19.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-04-02T08:31:24.000Z (3 months ago)
- Last Synced: 2024-04-06T14:46:05.720Z (3 months ago)
- Topics: automation, mos, sofie
- Language: TypeScript
- Homepage: https://github.com/nrkno/Sofie-TV-automation/
- Size: 8.26 MB
- Stars: 18
- Watchers: 12
- Forks: 14
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Lists
- awesome-broadcasting - MOS-connection - A JavaScript library for connection and MOS messaging either as MOS device or NRCS. (Video Production)
README
# Sofie MOS-Connection
[![Tests](https://github.com/nrkno/sofie-mos-connection/actions/workflows/node.yaml/badge.svg)](https://github.com/nrkno/sofie-mos-connection/actions/workflows/node.yaml)
[![codecov](https://codecov.io/gh/nrkno/sofie-mos-connection/branch/master/graph/badge.svg?token=LQL02uXajF)](https://codecov.io/gh/nrkno/sofie-mos-connection)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=nrkno_tv-automation-mos-connection&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=nrkno_tv-automation-mos-connection)This is the _MOS-Connection_ library of the [**Sofie** TV Automation System](https://github.com/nrkno/Sofie-TV-automation/), used for connecting to a _MOS_ device using the [MOS Protocol](http://mosprotocol.com/).
## General Sofie System Information
- [_Sofie_ Documentation](https://nrkno.github.io/sofie-core/)
- [_Sofie_ Releases](https://nrkno.github.io/sofie-core/releases)
- [Contribution Guidelines](CONTRIBUTING.md)
- [License](LICENSE)---
## Getting Started
### Installation
```bash
npm install @mos-connection/connector
or
yarn add @mos-connection/connector
```### Usage
_See more examples in the [examples](/packages/examples/src) folder!_
```typescript
import { MosConnection } from '@mos-connection/connector'let mos = new MosConnection(new ConnectionConfig({
mosID: 'my.mos.application',
acceptsConnections: true,
profiles: {
'0': true,
'1': true,
'2': true,
'4': true
},
openRelay: true
debug: false
}))
mos.onConnection((device: MosDevice) => { // called whenever there is a new connection to a mos-device
if (device.hasConnection) { // true if we can send messages to the mos-server
device.getMachineInfo().then((lm) => {
console.log('Machineinfo', lm)
})
}
// Setup callbacks to pipe data:
device.onRequestMachineInfo(() => {})
device.onCreateRunningOrder((ro) => {})
device.onDeleteRunningOrder((RunningOrderID: MosString128) => {})
device.onReadyToAir(() => {})
// ...
})
```### Quick-MOS
"Quick-MOS" is a simple MOS application that can be used to test the MOS-connection library.
It reads data-files from disk and pretends to be an NRCS, so you can connect other MOS-clients to it.
See [Quick-MOS](/packages/quick-mos/README.md) for more information.
## MOS Support
The MOS-Connection library currently supports the [MOS Protocol version **2.8.5**](https://mosprotocol.com/wp-content/MOS-Protocol-Documents/MOS_Protocol_Version_2.8.5_Final.htm).
### Supported MOS Profiles
| Profile | Status |
| --------- | --------------------- |
| Profile 0 | Implemented |
| Profile 1 | Implemented |
| Profile 2 | Implemented |
| Profile 3 | Implemented |
| Profile 4 | Implemented |
| Profile 5 | Not implemented (yet) |
| Profile 6 | Not implemented (yet) |
| Profile 7 | Not implemented (yet) |Pull Requests for the remaining profiles would be happily accepted!
## Packages
MOS-Connection consists of 3 packages:
- **@mos-connection/connector** is a Node.js library is used to connect to MOS devices or act as a MOS Server/NCS.
The `helper` and `model` functionality is included in this library as well.
- **@mos-connection/helper** is a library that provides various functions useful for those that prepare/handle data that will be sent to (or has been received by) the MOS-connection.
The `model` functionality is included in this library as well.
- **@mos-connection/model** is a library that contains types and enums, useful for applications that handles MOS-data.There is also a helper application **quickMos** designed to be a minimal mock MOS server for testing client applications.
---
_The NRK logo is a registered trademark of Norsk rikskringkasting AS. The license does not grant any right to use, in any way, any trademarks, service marks or logos of Norsk rikskringkasting AS._