+++
title = "Goldydocs"
linkTitle = "Goldydocs"

+++

{{< blocks/cover title="Cyanobyte: An intermediate representation for hardware peripheral I/O" image_anchor="top" height="full" color="orange" >}}
<div class="mx-auto">
	<a class="btn btn-lg btn-primary mr-3 mb-4" href="{{< relref "/docs" >}}">
		Learn More <i class="fas fa-arrow-alt-circle-right ml-2"></i>
	</a>
	<a class="btn btn-lg btn-secondary mr-3 mb-4" href="https://github.com/google/cyanobyte">
		View Source <i class="fab fa-github ml-2 "></i>
	</a>
	<p class="lead mt-5">Automatically generate drivers without writing code!</p>
	<div class="mx-auto mt-5">
		{{< blocks/link-down color="info" >}}
	</div>
</div>
{{< /blocks/cover >}}


{{< blocks/section color="primary" >}}
{{% blocks/feature icon="fa-list" title="Cyanobyte goals:" %}}
<ul style="text-align: left">
	<li>Open source</li>
	<li>Standarized</li>
	<li>Support any embedded platforms</li>
	<li>Easily extensible</li>
</ul>
{{% /blocks/feature %}}

{{% blocks/feature icon="fa-bookmark" title="TL,DR;" %}}
Cyanobyte is a specification that defines the types of hardware configurations and functions that
a hardware peripheral can have.

With a standardized representation, a codegen tool can read the intermediate representation and
convert it into an executable driver in the language and platform of your choice.
{{% /blocks/feature %}}

{{% blocks/feature icon="fa-users" title="Open Spec" %}}
Think of it as a machine-readable datasheet. By placing not just registers, but logic into a
static configration, you don't need to worry about converting a temperature sensor into Celsius,
or finding the exact register values to initialize your device. All the logic is handled for you.

This is an open spec, and we're looking for more feedback.
{{% /blocks/feature %}}

{{< /blocks/section >}}

{{< blocks/section color="dark" >}}
{{% blocks/feature icon="fa-lightbulb" title="Bright idea!" %}}
Just import the library and use an API. Now that's a bright idea.
{{% /blocks/feature %}}


{{% blocks/feature icon="fab fa-github" title="Contributions welcome!" url="https://github.com/google/cyanobyte" %}}
We do a [Pull Request](https://github.com/google/cyanobyte/pulls) contributions workflow on **GitHub**. New users are always welcome!
{{% /blocks/feature %}}


{{% blocks/feature icon="fab fa-twitter" title="Follow me on Twitter!" url="https://twitter.com/handnf" %}}
For announcement of latest features etc.
{{% /blocks/feature %}}


{{< /blocks/section >}}


{{< blocks/section >}}
<div class="col">
	<h2 class="text-center">
		How it works
	</h2>
	<img src="blocks.png" style="text-align: center"/>
	<p>
		Peripherals are defined in yaml files. We've chosen yaml for the ease
		of readability. These peripheral specification files provide metadata,
		along with list of registers, fields, and relevant computational operations.
	</p>
	<p>
		Code generation tools can take these machine-readable files and interpret
		them in many ways. They can be used to generate source code, documentation,
		or other applications.
	</p>
	<p>
		This project includes a series of platform template files based around
		Python and Jinja2. Different groups may decide to use a different templating
		engine, but should ensure it is compatible with the peripheral spec files.
	</p>
	<h4>Benefits</h4>
	<ul>
		<li>Datasheet errata can now be represented with a file diff</li>
		<li>Reduce time in porting for embedded platforms</li>
		<li>Continuous deployment systems can patch libraries straight from source</li>
	</ul>
</div>

{{< /blocks/section >}}

{{< blocks/section >}}
<div class="col">
	<h2 class="text-center">
		Current Status
	</h2>
	At the moment Cyanobyte has support for I2C peripherals across many
	peripherals and embedded platforms. There is early support for other
	serialization protocols like SPI.

	As Cyanobyte provides code generation support, there is
	<a href="https://github.com/google/cyanobyte/tree/master/test/sampleData">
	support for each peripheral on every platform</a>.
	<br><br>
</div>
{{< /blocks/section >}}

{{< blocks/section >}}
	{{% blocks/feature icon="fas fa-memory" title="Supported Peripherals" %}}
	- ADS1015 A2D Converter
	- BH1750FVI Light Sensor
	- BMP180 Temperature Sensor
	- BMP280 Temperature/Pressure Sensor
	- LSM303D IMU
	- MCP4725 D2A Converter
	- MCP9808 Temperature Sensor
	- TCS3472 Light Sensor
	{{% /blocks/feature %}}

	{{% blocks/feature icon="fas fa-microchip" title="Embedded Platforms" %}}
	- Arduino
	- ESP32
	- Espruino (Javascript)
	- KubOS
	- CircuitPython
	- Micropython
	- Pimoroni I2C Device
	- Raspberry Pi
	- Miscellaneous embedded C
	- CMSIS
	- LaTeX Datasheets
	- Markdown documentation
	- Instructional webpage
	{{% /blocks/feature %}}

	{{% blocks/feature icon="fas fa-clipboard-list" title="Next Goals" %}}
	- Investigate other I2C peripherals like displays
	- Investigate support for new programming languages
	- Improve support for other serial peripherals like SPI
	{{% /blocks/feature %}}

{{< /blocks/section >}}

{{< blocks/section >}}
<div class="col">
	<h2 class="text-center">
		Talks
	</h2>
	<ul>
		<li>
			<a href="https://www.youtube.com/watch?v=rIAjqPCg8Ek" style="color: white; text-decoration: underline">
				IEEE Sensor Application Symposium 2020
			</a>
		</li>
	</ul>
</div>

{{< /blocks/section >}}

{{< blocks/section >}}
<div class="col">
	<h2 class="text-center">
		Help Wanted!
	</h2>
	Do you want to volunteer to help make this project come to life?
	There are many technologies we need help with.
	<ul>
		<li>Several embedded platforms are written in C</li>
		<li>Several embedded platforms are written in Python</li>
		<li>Tests are written in Python</li>
		<li>Documentation is written in Markdown</li>
		<li>We're always exploring new avenues of exploration</li>
	</ul>
	Check out <a href="https://github.com/google/cyanobyte/issues" style="color: white; text-decoration: underline">our issues list</a>
	to see areas we may be exploring
</div>

{{< /blocks/section >}}
