| # Copyright 2023 Google LLC |
| # Licensed under the Apache License, Version 2.0, see LICENSE for details. |
| # SPDX-License-Identifier: Apache-2.0 |
| |
| load("//rules:matcha.bzl", "bin_to_c_file") |
| |
| package(default_visibility = ["//visibility:public"]) |
| |
| bin_to_c_file( |
| name = "i2s_440hz_audio_tx", |
| srcs = [ |
| "//sw/device/tests/testdata:i2s_440hz_audio_tx.raw", |
| ], |
| var_name = "i2s_440hz_audio_tx", |
| ) |
| |
| genrule( |
| name = "test_image", |
| srcs = [ |
| "//sw/device/examples/testdata/hps_images:hps_0.jpg", |
| ], |
| outs = [ |
| "test_image.h", |
| ], |
| cmd = """\ |
| $(location //util:image_to_c) \ |
| --input_shape 320 240 \ |
| --input_mode L \ |
| --input=$(location //sw/device/examples/testdata/hps_images:hps_0.jpg) \ |
| --output=$@ |
| """, |
| tools = [ |
| "//util:image_to_c", |
| ], |
| ) |