├── gradle.properties ├── fastlane └── metadata │ └── android │ ├── zh-CN │ ├── title.txt │ ├── short_description.txt │ └── full_description.txt │ ├── en-US │ ├── title.txt │ ├── 132.txt │ ├── changelog │ │ ├── 131.txt │ │ ├── 133.txt │ │ ├── 135.txt │ │ ├── 126.txt │ │ ├── 127.txt │ │ ├── 130.txt │ │ ├── 136.txt │ │ ├── 134.txt │ │ ├── 125.txt │ │ ├── 129.txt │ │ └── 128.txt │ ├── short_description.txt │ ├── images │ │ ├── icon.png │ │ ├── featureGraphic.jpg │ │ └── phoneScreenshots │ │ │ └── SigGen.png │ └── full_description.txt │ └── tr-TR │ ├── title.txt │ ├── short_description.txt │ ├── images │ ├── icon.png │ ├── featureGraphic.jpg │ └── phoneScreenshots │ │ └── SigGen.png │ └── full_description.txt ├── ic_launcher.png ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── .gitignore ├── src └── main │ ├── res │ ├── drawable-hdpi │ │ └── ic_launcher.png │ ├── drawable-mdpi │ │ └── ic_launcher.png │ ├── drawable-xhdpi │ │ └── ic_launcher.png │ ├── drawable-xxhdpi │ │ └── ic_launcher.png │ ├── drawable-xxxhdpi │ │ └── ic_launcher.png │ ├── values │ │ ├── ids.xml │ │ ├── integers.xml │ │ ├── arrays.xml │ │ ├── attrs.xml │ │ ├── strings.xml │ │ └── styles.xml │ ├── drawable │ │ ├── ic_transparent.xml │ │ ├── ic_back.xml │ │ ├── ic_back_dark.xml │ │ ├── ic_forward.xml │ │ ├── ic_forward_dark.xml │ │ ├── ic_add_white_24dp.xml │ │ ├── ic_expand_less_black_24dp.xml │ │ ├── ic_expand_less_white_24dp.xml │ │ ├── ic_expand_more_black_24dp.xml │ │ ├── ic_expand_more_white_24dp.xml │ │ ├── ic_chevron_left_black_24dp.xml │ │ ├── ic_chevron_left_white_24dp.xml │ │ ├── ic_chevron_right_black_24dp.xml │ │ ├── ic_chevron_right_white_24dp.xml │ │ ├── ic_menu_white_24dp.xml │ │ ├── ic_arrow_back_black_24dp.xml │ │ ├── ic_arrow_back_white_24dp.xml │ │ ├── ic_arrow_forward_black_24dp.xml │ │ ├── ic_arrow_forward_white_24dp.xml │ │ ├── ic_check_box_outline_blank_black_24dp.xml │ │ ├── ic_check_box_outline_blank_white_24dp.xml │ │ ├── ic_crop_landscape_white_24dp.xml │ │ ├── ic_radio_button_unchecked_black_24dp.xml │ │ ├── ic_radio_button_unchecked_white_24dp.xml │ │ ├── ic_check_box_black_24dp.xml │ │ ├── ic_check_box_white_24dp.xml │ │ ├── ic_info_outline_black_24dp.xml │ │ ├── ic_info_outline_white_24dp.xml │ │ ├── ic_brightness_low_white_24dp.xml │ │ ├── ic_radio_button_checked_black_24dp.xml │ │ ├── ic_radio_button_checked_white_24dp.xml │ │ ├── ic_brightness_high_black_24dp.xml │ │ ├── ic_brightness_high_white_24dp.xml │ │ └── toast_frame.xml │ ├── menu │ │ ├── navigation.xml │ │ └── main.xml │ ├── layout │ │ ├── custom.xml │ │ ├── help.xml │ │ ├── about_dialog.xml │ │ ├── shortcut.xml │ │ └── main.xml │ ├── xml │ │ └── preferences.xml │ ├── values-zh-rCN │ │ └── strings.xml │ ├── values-tr │ │ └── strings.xml │ ├── values-pt-rBR │ │ └── strings.xml │ ├── raw │ │ └── help.html │ ├── layout-large │ │ └── main.xml │ └── layout-small │ │ └── main.xml │ ├── AndroidManifest.xml │ └── java │ └── org │ └── billthefarmer │ └── siggen │ ├── Display.java │ ├── SettingsFragment.java │ ├── AboutPreference.java │ ├── SettingsActivity.java │ ├── SiggenView.java │ ├── HelpActivity.java │ ├── Scale.java │ ├── Shortcut.java │ ├── Knob.java │ └── Main.java ├── .github └── workflows │ ├── build.yml │ └── release.yml ├── gradlew.bat ├── README.md ├── gradlew └── gpl-3.0.txt /gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M -------------------------------------------------------------------------------- /fastlane/metadata/android/zh-CN/title.txt: -------------------------------------------------------------------------------- 1 | 信号发生器 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/title.txt: -------------------------------------------------------------------------------- 1 | Signal Generator 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/tr-TR/title.txt: -------------------------------------------------------------------------------- 1 | Signal Generator 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/132.txt: -------------------------------------------------------------------------------- 1 | * Add navigation menu 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/zh-CN/short_description.txt: -------------------------------------------------------------------------------- 1 | 音频信号发生器 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/131.txt: -------------------------------------------------------------------------------- 1 | * Add system theme 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/133.txt: -------------------------------------------------------------------------------- 1 | * Add shortcuts 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/135.txt: -------------------------------------------------------------------------------- 1 | * Update icons 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/126.txt: -------------------------------------------------------------------------------- 1 | * Add external control 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/127.txt: -------------------------------------------------------------------------------- 1 | * Fix android 13 toasts 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/130.txt: -------------------------------------------------------------------------------- 1 | * Add level buttons 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/tr-TR/short_description.txt: -------------------------------------------------------------------------------- 1 | Ses Sinyal Üreteci 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/short_description.txt: -------------------------------------------------------------------------------- 1 | Audio Signal Generator 2 | -------------------------------------------------------------------------------- /ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/ic_launcher.png -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/136.txt: -------------------------------------------------------------------------------- 1 | * Add Simplified Chinese translation 2 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/134.txt: -------------------------------------------------------------------------------- 1 | * Add duty cycle slider 2 | * Update icons 3 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/125.txt: -------------------------------------------------------------------------------- 1 | * Change exact icon 2 | * Update about dialog 3 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/129.txt: -------------------------------------------------------------------------------- 1 | * Add Turkish translation 2 | * Update level slider 3 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/changelog/128.txt: -------------------------------------------------------------------------------- 1 | * Make volume slider linear in dB 2 | * Save state in preferences 3 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle/ 3 | .idea/ 4 | build/ 5 | data/ 6 | local.properties 7 | *~ 8 | *.apk 9 | *.orig 10 | -------------------------------------------------------------------------------- /src/main/res/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/src/main/res/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/main/res/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/src/main/res/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/main/res/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/src/main/res/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/main/res/drawable-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/src/main/res/drawable-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/main/res/drawable-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/src/main/res/drawable-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/images/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/fastlane/metadata/android/en-US/images/icon.png -------------------------------------------------------------------------------- /fastlane/metadata/android/tr-TR/images/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/fastlane/metadata/android/tr-TR/images/icon.png -------------------------------------------------------------------------------- /src/main/res/values/ids.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/main/res/values/integers.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 0 5 | 6 | 7 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/images/featureGraphic.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/fastlane/metadata/android/en-US/images/featureGraphic.jpg -------------------------------------------------------------------------------- /fastlane/metadata/android/tr-TR/images/featureGraphic.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/fastlane/metadata/android/tr-TR/images/featureGraphic.jpg -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/images/phoneScreenshots/SigGen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/fastlane/metadata/android/en-US/images/phoneScreenshots/SigGen.png -------------------------------------------------------------------------------- /fastlane/metadata/android/tr-TR/images/phoneScreenshots/SigGen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/billthefarmer/sig-gen/HEAD/fastlane/metadata/android/tr-TR/images/phoneScreenshots/SigGen.png -------------------------------------------------------------------------------- /fastlane/metadata/android/zh-CN/full_description.txt: -------------------------------------------------------------------------------- 1 | 带旋钮的音频信号发生器。 2 | 3 | 用手指调节频率旋钮,并使用精细的滑块来微调频率和输出电平。频率旋钮还可以使用左右箭头按钮进行调整。频率按钮下方的书签按钮用于在多个书签之间切换,当书签存在时会显示出来。 4 | 5 | * 频率范围 0.1Hz - 25KHz 6 | * 电平范围 0dB - -80dB 7 | * 设置精确频率 8 | * 频率书签 9 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_transparent.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_back.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_back_dark.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_forward.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/menu/navigation.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_forward_dark.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | # Build on push and PR events 2 | on: 3 | push: 4 | branches: 5 | - master 6 | tags-ignore: 7 | - '*' 8 | pull_request: 9 | 10 | jobs: 11 | build: 12 | runs-on: ubuntu-latest 13 | steps: 14 | - name: Checkout 15 | uses: "actions/checkout@v3" 16 | 17 | - name: Build with Gradle 18 | run: ./gradlew build 19 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_add_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_expand_less_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_expand_less_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_expand_more_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_expand_more_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/values/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Light 6 | Dark 7 | System 8 | 9 | 10 | 11 | 0 12 | 1 13 | 2 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_chevron_left_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_chevron_left_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_chevron_right_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_chevron_right_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_menu_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_arrow_back_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_arrow_back_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_arrow_forward_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_arrow_forward_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_check_box_outline_blank_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_check_box_outline_blank_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_crop_landscape_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_radio_button_unchecked_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_radio_button_unchecked_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_check_box_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_check_box_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_info_outline_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_info_outline_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_brightness_low_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/layout/custom.xml: -------------------------------------------------------------------------------- 1 | 2 | 13 | 14 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_radio_button_checked_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_radio_button_checked_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /fastlane/metadata/android/en-US/full_description.txt: -------------------------------------------------------------------------------- 1 | Audio signal generator with twirly knob. 2 | 3 | The frequency knob responds to finger twirling. The fine frequency and level sliders allow for fine adjustments of frequency and output level. The frequency knob is also adjustable using the left and right arrow buttons. The two bookmark buttons below the frequency knob show if there are bookmarks, and will go to the next lower or higher bookmark if it exists. 4 | 5 | * Frequency range 0.1Hz - 25KHz 6 | * Level range 0dB - -80dB 7 | * Set exact frequency 8 | * Frequency bookmarks 9 | -------------------------------------------------------------------------------- /fastlane/metadata/android/tr-TR/full_description.txt: -------------------------------------------------------------------------------- 1 | İki düğmeli ses sinyali üreteci. 2 | 3 | Frekans düğmesi parmak dönmesine tepki verir. İnce frekans ve seviye kaydırıcıları, frekans ve çıkış seviyesinin hassas bir şekilde ayarlanmasını sağlar. Frekans düğmesi ayrıca sol ve sağ ok düğmeleri kullanılarak ayarlanabilir. Frekans düğmesinin altındaki iki yer işareti düğmesi, yer işaretleri olup olmadığını gösterir ve varsa bir sonraki alt veya daha yüksek yer işaretine gider. 4 | 5 | * Frekans aralığı 0.1Hz - 25KHz 6 | * Seviye aralığı 0dB - -80dB 7 | * Tam frekansı ayarlama 8 | * Frekans yer imleri 9 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_brightness_high_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/drawable/ic_brightness_high_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /src/main/res/layout/help.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/main/res/menu/main.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | 15 | 16 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /.github/workflows/release.yml: -------------------------------------------------------------------------------- 1 | # Release on new tags 2 | on: 3 | push: 4 | tags: 5 | - 'v*' 6 | 7 | jobs: 8 | release: 9 | runs-on: ubuntu-latest 10 | steps: 11 | - uses: "actions/checkout@v3" 12 | 13 | - name: Get the tag version 14 | id: version 15 | run: echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/v} 16 | 17 | - name: Create release 18 | id: create_release 19 | uses: actions/create-release@v1 20 | env: 21 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 22 | with: 23 | tag_name: ${{ github.ref }} 24 | release_name: "Version ${{ steps.version.outputs.VERSION }}" 25 | body: "![Icon](src/main/res/drawable-xhdpi/ic_launcher.png)" 26 | -------------------------------------------------------------------------------- /src/main/res/values/attrs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /src/main/res/drawable/toast_frame.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /src/main/res/xml/preferences.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 9 | 10 | 19 | 20 | 21 | 22 | 25 | 26 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /src/main/res/layout/about_dialog.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 11 | 12 | 20 | 21 | 28 | 29 | 36 | 37 | 45 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /src/main/res/values-zh-rCN/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 信号发生器 4 | "版权所有 \u00A9 2017 Bill Farmer 5 | 6 | "许可证 GNU GPLv3 7 | 8 | 构建于 %s 9 | 10 | 设置 11 | 帮助 12 | 屏幕常亮 13 | 精确频率 14 | 书签 15 | 名称 16 | 频率 17 | 输出电平 18 | 占空比 19 | 输入频率 20 | 取消 21 | 创建 22 | 清除 23 | 确定 24 | 25 | 已添加书签 %1.2f 26 | 已删除书签 %1.2f 27 | 28 | 正弦波 29 | 正弦 30 | 31 | 方波 32 | 方波 33 | 34 | 锯齿波 35 | 锯齿 36 | 齿 37 | 38 | 静音 39 | 40 | 关于 41 | 信号发生器 版本 %s 42 | 43 | 主题 44 | 45 | -------------------------------------------------------------------------------- /src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 9 | 10 | 16 | 17 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 45 | 46 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /src/main/res/values-tr/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Sinyal Üreteci 5 | Telif hakkı \u00A9 2017 Bill Farmer 6 | 7 | Lisans GNU GPLv3 8 | 9 | Oluştur %s 10 | 11 | Ayarlar 12 | Yardım 13 | Uyu 14 | Kesin 15 | Yer işareti 16 | Ad 17 | Frekans 18 | Düzey 19 | Görev 20 | Frekans girin 21 | İptal 22 | Yaratmak 23 | Berrak 24 | Tamam 25 | 26 | Yer işareti eklendi %1.2f 27 | Yer işareti kaldırıldı %1.2f 28 | 29 | Sinüs 30 | Sin 31 | S 32 | Kare 33 | Kar 34 | Q 35 | Testere dişli 36 | Tes 37 | W 38 | 39 | Sesi kapat 40 | 41 | Hakkında 42 | Sinyal Üreteci version %s 43 | 44 | Tema 45 | 46 | 47 | -------------------------------------------------------------------------------- /src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Signal Generator 5 | Copyright \u00A9 2017 Bill Farmer 6 | 7 | Licence GNU GPLv3 8 | 9 | Built %s 10 | 11 | Settings 12 | Help 13 | Sleep 14 | Exact 15 | Bookmark 16 | Name 17 | Frequency 18 | Level 19 | Duty 20 | Enter frequency 21 | Cancel 22 | Create 23 | Clear 24 | OK 25 | 26 | Bookmark added %1.2f 27 | Bookmark removed %1.2f 28 | 29 | Sine 30 | Sin 31 | S 32 | Square 33 | Squ 34 | Q 35 | Sawtooth 36 | Saw 37 | W 38 | 39 | Mute 40 | 41 | About 42 | Signal Generator version %s 43 | 44 | Theme 45 | %s 46 | 47 | 48 | -------------------------------------------------------------------------------- /src/main/res/values-pt-rBR/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Signal Generator 5 | Direitos \u00A9 2017 Bill Farmer 6 | 7 | Licença GNU GPLv3 8 | 9 | Construído %s 10 | 11 | Configurações 12 | Ajuda 13 | Dormir 14 | Exato 15 | Favorito 16 | Nome 17 | Frequência 18 | Nível 19 | Dever 20 | Inserir Frequência 21 | Cancelar 22 | Criar 23 | Claro 24 | OK 25 | 26 | Favorito adicionado %1.2f 27 | Favorito removido %1.2f 28 | 29 | Seno 30 | Sen 31 | S 32 | Quadrada 33 | Qua 34 | Q 35 | Dente de serra 36 | Ser 37 | R 38 | 39 | Mutar 40 | 41 | Tema 42 | 43 | Sobre 44 | Signal Generator versão %s 45 | 46 | 47 | -------------------------------------------------------------------------------- /src/main/res/raw/help.html: -------------------------------------------------------------------------------- 1 |

Signal Generator

2 |

3 | A signal generator for Android. The app can be downloaded 4 | from F-Droid 5 | and here. 6 |

7 |   •  Frequency range 0.1Hz – 25KHz
8 |   •  Level range 0dB – -80dB
9 |   •  Set exact frequency
10 |   •  Frequency bookmarks
11 |   •  Square wave duty cycle
12 |   •  Shortcut
13 |   •  External control
14 |

Using

15 |

16 | The frequency knob responds to finger twirling. The duty cycle, fine 17 | frequency and level sliders allow for adjustments of square wave 18 | duty cycle, fine frequency and output level. The frequency knob is 19 | also adjustable using the left and right arrow buttons above. The 20 | two bookmark buttons below the frequency knob show if there are 21 | bookmarks, and will go to the next lower or higher bookmark if it 22 | exists. 23 |

24 |

25 | The toolbar items are, from left to right: 26 |

27 |   •  Exact - Prompt for an exact frequency
28 |   •  Bookmark - Save the current frequency as a bookmark
29 |   •  Sleep - Prevent the device from sleeping
30 |

31 | To remove a bookmark, go to it and touch the toolbar bookmark button. 32 |

33 |

Shortcut

34 |

35 | A shortcut may be created to set the parameters shown below. Empty 36 | frequency, duty cycle and level values and unchecked waveform values 37 | will not be included. The mute value will always be included. The 38 | name of the shortcut will be composed from the set values if the 39 | name field is empty. 40 |

41 |

External Control

42 |

43 | The app may be started, the frequency, level, duty cycle, waveform 44 | and mute set externally by sending a suitable 45 | Intent 46 | from an automation app. The app package/activity is 47 | org.billthefarmer.siggen/org.billthefarmer.siggen.Main. The 48 | parameters may be seen in a table in 49 | the README. 50 |

51 |

52 | Any combination of extras or none may be sent. Subsequent intents sent 53 | will update the values from the included extras. 54 |

55 |

56 | This may be tested using 57 | the Android 58 | Debug Bridge. 59 |

60 | -------------------------------------------------------------------------------- /src/main/java/org/billthefarmer/siggen/Display.java: -------------------------------------------------------------------------------- 1 | //////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // Signal generator - An Android Signal generator written in Java. 4 | // 5 | // Copyright (C) 2013 Bill Farmer 6 | // 7 | // This program is free software: you can redistribute it and/or modify 8 | // it under the terms of the GNU General Public License as published by 9 | // the Free Software Foundation, either version 3 of the License, or 10 | // (at your option) any later version. 11 | // 12 | // This program is distributed in the hope that it will be useful, 13 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | // GNU General Public License for more details. 16 | // 17 | // You should have received a copy of the GNU General Public License 18 | // along with this program. If not, see . 19 | // 20 | // Bill Farmer william j farmer [at] yahoo [dot] co [dot] uk. 21 | // 22 | /////////////////////////////////////////////////////////////////////////////// 23 | 24 | package org.billthefarmer.siggen; 25 | 26 | import android.content.Context; 27 | import android.graphics.Canvas; 28 | import android.graphics.Paint; 29 | import android.util.AttributeSet; 30 | 31 | import java.util.Locale; 32 | 33 | // Display 34 | public class Display extends SiggenView 35 | { 36 | private double frequency; 37 | private double level; 38 | 39 | public Display(Context context, AttributeSet attrs) 40 | { 41 | super(context, attrs); 42 | } 43 | 44 | // On measure 45 | @Override 46 | protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) 47 | { 48 | super.onMeasure(widthMeasureSpec, heightMeasureSpec); 49 | 50 | int w = (parentWidth - MARGIN) / 2; 51 | int h = parentHeight / 5; 52 | 53 | setMeasuredDimension(w, h); 54 | } 55 | 56 | // Set frequency 57 | protected void setFrequency(double f) 58 | { 59 | frequency = f; 60 | invalidate(); 61 | } 62 | 63 | // Set level 64 | protected void setLevel(double l) 65 | { 66 | level = l; 67 | invalidate(); 68 | } 69 | 70 | // On draw 71 | @Override 72 | protected void onDraw(Canvas canvas) 73 | { 74 | super.onDraw(canvas); 75 | String s = String.format(Locale.getDefault(), "%5.2fHz", frequency); 76 | paint.setTextAlign(Paint.Align.LEFT); 77 | paint.setTextSize(height / 2); 78 | paint.setTextScaleX(0.9f); 79 | paint.setColor(textColour); 80 | paint.setStyle(Paint.Style.FILL_AND_STROKE); 81 | canvas.drawText(s, MARGIN, height * 2 / 3, paint); 82 | 83 | s = String.format(Locale.getDefault(), "%5.2fdB", level); 84 | paint.setTextAlign(Paint.Align.RIGHT); 85 | canvas.drawText(s, width - MARGIN, height * 2 / 3, paint); 86 | } 87 | } 88 | -------------------------------------------------------------------------------- /gradlew.bat: -------------------------------------------------------------------------------- 1 | @rem 2 | @rem Copyright 2015 the original author or authors. 3 | @rem 4 | @rem Licensed under the Apache License, Version 2.0 (the "License"); 5 | @rem you may not use this file except in compliance with the License. 6 | @rem You may obtain a copy of the License at 7 | @rem 8 | @rem https://www.apache.org/licenses/LICENSE-2.0 9 | @rem 10 | @rem Unless required by applicable law or agreed to in writing, software 11 | @rem distributed under the License is distributed on an "AS IS" BASIS, 12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | @rem See the License for the specific language governing permissions and 14 | @rem limitations under the License. 15 | @rem 16 | 17 | @if "%DEBUG%"=="" @echo off 18 | @rem ########################################################################## 19 | @rem 20 | @rem Gradle startup script for Windows 21 | @rem 22 | @rem ########################################################################## 23 | 24 | @rem Set local scope for the variables with windows NT shell 25 | if "%OS%"=="Windows_NT" setlocal 26 | 27 | set DIRNAME=%~dp0 28 | if "%DIRNAME%"=="" set DIRNAME=. 29 | set APP_BASE_NAME=%~n0 30 | set APP_HOME=%DIRNAME% 31 | 32 | @rem Resolve any "." and ".." in APP_HOME to make it shorter. 33 | for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi 34 | 35 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 36 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" 37 | 38 | @rem Find java.exe 39 | if defined JAVA_HOME goto findJavaFromJavaHome 40 | 41 | set JAVA_EXE=java.exe 42 | %JAVA_EXE% -version >NUL 2>&1 43 | if %ERRORLEVEL% equ 0 goto execute 44 | 45 | echo. 46 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 47 | echo. 48 | echo Please set the JAVA_HOME variable in your environment to match the 49 | echo location of your Java installation. 50 | 51 | goto fail 52 | 53 | :findJavaFromJavaHome 54 | set JAVA_HOME=%JAVA_HOME:"=% 55 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 56 | 57 | if exist "%JAVA_EXE%" goto execute 58 | 59 | echo. 60 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 61 | echo. 62 | echo Please set the JAVA_HOME variable in your environment to match the 63 | echo location of your Java installation. 64 | 65 | goto fail 66 | 67 | :execute 68 | @rem Setup the command line 69 | 70 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 71 | 72 | 73 | @rem Execute Gradle 74 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* 75 | 76 | :end 77 | @rem End local scope for the variables with windows NT shell 78 | if %ERRORLEVEL% equ 0 goto mainEnd 79 | 80 | :fail 81 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 82 | rem the _cmd.exe /c_ return code! 83 | set EXIT_CODE=%ERRORLEVEL% 84 | if %EXIT_CODE% equ 0 set EXIT_CODE=1 85 | if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% 86 | exit /b %EXIT_CODE% 87 | 88 | :mainEnd 89 | if "%OS%"=="Windows_NT" endlocal 90 | 91 | :omega 92 | -------------------------------------------------------------------------------- /src/main/java/org/billthefarmer/siggen/SettingsFragment.java: -------------------------------------------------------------------------------- 1 | //////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // Signal Generator - An Android Signal Generator written in Java. 4 | // 5 | // Copyright (C) 2013 Bill Farmer 6 | // 7 | // This program is free software; you can redistribute it and/or modify 8 | // it under the terms of the GNU General Public License as published by 9 | // the Free Software Foundation; either version 3 of the License, or 10 | // (at your option) any later version. 11 | // 12 | // This program is distributed in the hope that it will be useful, 13 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | // GNU General Public License for more details. 16 | // 17 | // You should have received a copy of the GNU General Public License 18 | // along with this program. If not, see . 19 | // 20 | // Bill Farmer william j farmer [at] yahoo [dot] co [dot] uk. 21 | // 22 | /////////////////////////////////////////////////////////////////////////////// 23 | 24 | package org.billthefarmer.siggen; 25 | 26 | import android.content.Intent; 27 | import android.content.SharedPreferences; 28 | import android.os.Build; 29 | import android.os.Bundle; 30 | import android.preference.ListPreference; 31 | import android.preference.Preference; 32 | import android.preference.PreferenceManager; 33 | 34 | // SettingsFragment 35 | @SuppressWarnings("deprecation") 36 | public class SettingsFragment extends android.preference.PreferenceFragment 37 | implements SharedPreferences.OnSharedPreferenceChangeListener 38 | { 39 | private static final String KEY_PREF_ABOUT = "pref_about"; 40 | 41 | // onCreate 42 | @Override 43 | public void onCreate(Bundle savedInstanceState) 44 | { 45 | super.onCreate(savedInstanceState); 46 | 47 | // Load the preferences from an XML resource 48 | addPreferencesFromResource(R.xml.preferences); 49 | 50 | SharedPreferences preferences = 51 | PreferenceManager.getDefaultSharedPreferences(getActivity()); 52 | 53 | // Get about summary 54 | Preference about = findPreference(KEY_PREF_ABOUT); 55 | 56 | // Set version in text view 57 | if (about != null) 58 | { 59 | String sum = about.getSummary().toString(); 60 | String s = String.format(sum, BuildConfig.VERSION_NAME); 61 | about.setSummary(s); 62 | } 63 | } 64 | 65 | // on Resume 66 | @Override 67 | public void onResume() 68 | { 69 | super.onResume(); 70 | getPreferenceScreen().getSharedPreferences() 71 | .registerOnSharedPreferenceChangeListener(this); 72 | } 73 | 74 | // on Pause 75 | @Override 76 | public void onPause() 77 | { 78 | super.onPause(); 79 | getPreferenceScreen().getSharedPreferences() 80 | .unregisterOnSharedPreferenceChangeListener(this); 81 | } 82 | 83 | // On shared preference changed 84 | @Override 85 | public void onSharedPreferenceChanged(SharedPreferences preferences, 86 | String key) 87 | { 88 | if (key.equals(Main.PREF_THEME)) 89 | { 90 | if (Build.VERSION.SDK_INT != Build.VERSION_CODES.M) 91 | getActivity().recreate(); 92 | } 93 | } 94 | } 95 | -------------------------------------------------------------------------------- /src/main/java/org/billthefarmer/siggen/AboutPreference.java: -------------------------------------------------------------------------------- 1 | //////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // Signal Generator - An Android Signal Generator written in Java. 4 | // 5 | // Copyright (C) 2013 Bill Farmer 6 | // 7 | // This program is free software: you can redistribute it and/or modify 8 | // it under the terms of the GNU General Public License as published by 9 | // the Free Software Foundation, either version 3 of the License, or 10 | // (at your option) any later version. 11 | // 12 | // This program is distributed in the hope that it will be useful, 13 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | // GNU General Public License for more details. 16 | // 17 | // You should have received a copy of the GNU General Public License 18 | // along with this program. If not, see . 19 | // 20 | // Bill Farmer william j farmer [at] yahoo [dot] co [dot] uk. 21 | // 22 | /////////////////////////////////////////////////////////////////////////////// 23 | 24 | package org.billthefarmer.siggen; 25 | 26 | import android.content.Context; 27 | import android.preference.DialogPreference; 28 | import android.text.SpannableStringBuilder; 29 | import android.text.method.LinkMovementMethod; 30 | import android.util.AttributeSet; 31 | import android.view.View; 32 | import android.widget.TextView; 33 | 34 | import java.text.DateFormat; 35 | 36 | @SuppressWarnings("deprecation") 37 | public class AboutPreference extends DialogPreference 38 | { 39 | 40 | // Constructor 41 | public AboutPreference(Context context, AttributeSet attrs) 42 | { 43 | super(context, attrs); 44 | } 45 | 46 | // On bind dialog view 47 | @Override 48 | protected void onBindDialogView(View view) 49 | { 50 | super.onBindDialogView(view); 51 | 52 | // Get version text view 53 | TextView version = view.findViewById(R.id.about); 54 | 55 | // Set version in text view 56 | if (version != null) 57 | { 58 | SpannableStringBuilder builder = 59 | new SpannableStringBuilder(version.getText()); 60 | int st = builder.toString().indexOf("%s"); 61 | int en = builder.length(); 62 | builder.replace(st, en, BuildConfig.VERSION_NAME); 63 | version.setText(builder); 64 | version.setMovementMethod(LinkMovementMethod.getInstance()); 65 | } 66 | 67 | // Get built text view 68 | TextView built = view.findViewById(R.id.built); 69 | 70 | // Set built date in text view 71 | if (built != null) 72 | { 73 | String d = built.getText().toString(); 74 | DateFormat dateFormat = DateFormat.getDateTimeInstance(); 75 | String s = 76 | String.format(d, dateFormat.format(BuildConfig.BUILT)); 77 | built.setText(s); 78 | } 79 | 80 | // Get copyright text view 81 | TextView copyright = view.findViewById(R.id.copyright); 82 | 83 | // Set movement method 84 | if (copyright != null) 85 | copyright.setMovementMethod(LinkMovementMethod.getInstance()); 86 | 87 | // Get licence text view 88 | TextView licence = view.findViewById(R.id.licence); 89 | 90 | // Set movement method 91 | if (licence != null) 92 | licence.setMovementMethod(LinkMovementMethod.getInstance()); 93 | } 94 | } 95 | -------------------------------------------------------------------------------- /src/main/java/org/billthefarmer/siggen/SettingsActivity.java: -------------------------------------------------------------------------------- 1 | //////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // Signal Generator - An Android Signal Generator written in Java. 4 | // 5 | // Copyright (C) 2013 Bill Farmer 6 | // 7 | // This program is free software; you can redistribute it and/or modify 8 | // it under the terms of the GNU General Public License as published by 9 | // the Free Software Foundation; either version 3 of the License, or 10 | // (at your option) any later version. 11 | // 12 | // This program is distributed in the hope that it will be useful, 13 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | // GNU General Public License for more details. 16 | // 17 | // You should have received a copy of the GNU General Public License 18 | // along with this program. If not, see . 19 | // 20 | // Bill Farmer william j farmer [at] yahoo [dot] co [dot] uk. 21 | // 22 | /////////////////////////////////////////////////////////////////////////////// 23 | 24 | package org.billthefarmer.siggen; 25 | 26 | import android.app.ActionBar; 27 | import android.app.Activity; 28 | import android.content.SharedPreferences; 29 | import android.content.res.Configuration; 30 | import android.os.Bundle; 31 | import android.preference.PreferenceManager; 32 | import android.view.MenuItem; 33 | 34 | // SettingsActivity 35 | @SuppressWarnings("deprecation") 36 | public class SettingsActivity extends Activity 37 | { 38 | // On create 39 | @Override 40 | @SuppressWarnings("deprecation") 41 | protected void onCreate(Bundle savedInstanceState) 42 | { 43 | super.onCreate(savedInstanceState); 44 | 45 | // Get preferences 46 | SharedPreferences preferences = 47 | PreferenceManager.getDefaultSharedPreferences(this); 48 | 49 | int theme = Integer.parseInt(preferences.getString(Main.PREF_THEME, "0")); 50 | 51 | Configuration config = getResources().getConfiguration(); 52 | int night = config.uiMode & Configuration.UI_MODE_NIGHT_MASK; 53 | 54 | switch (theme) 55 | { 56 | case Main.LIGHT: 57 | setTheme(R.style.AppTheme); 58 | break; 59 | 60 | case Main.DARK: 61 | setTheme(R.style.AppDarkTheme); 62 | break; 63 | 64 | case Main.SYSTEM: 65 | switch (night) 66 | { 67 | case Configuration.UI_MODE_NIGHT_NO: 68 | setTheme(R.style.AppTheme); 69 | break; 70 | 71 | case Configuration.UI_MODE_NIGHT_YES: 72 | setTheme(R.style.AppDarkTheme); 73 | break; 74 | } 75 | break; 76 | } 77 | 78 | // Display the fragment as the main content. 79 | getFragmentManager().beginTransaction() 80 | .replace(android.R.id.content, new SettingsFragment()) 81 | .commit(); 82 | 83 | // Enable back navigation on action bar 84 | ActionBar actionBar = getActionBar(); 85 | actionBar.setDisplayHomeAsUpEnabled(true); 86 | setTitle(R.string.settings); 87 | } 88 | 89 | // On options item selected 90 | @Override 91 | public boolean onOptionsItemSelected(MenuItem item) 92 | { 93 | // Switch on item id 94 | switch (item.getItemId()) 95 | { 96 | case android.R.id.home: 97 | finish(); 98 | return true; 99 | 100 | default: 101 | return super.onOptionsItemSelected(item); 102 | } 103 | } 104 | } 105 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ![Logo](src/main/res/drawable-hdpi/ic_launcher.png) Signal Generator [![.github/workflows/main.yml](https://github.com/billthefarmer/sig-gen/workflows/.github/workflows/build.yml/badge.svg)](https://github.com/billthefarmer/sig-gen/actions) [![Release](https://img.shields.io/github/release/billthefarmer/sig-gen.svg?logo=github)](https://github.com/billthefarmer/sig-gen/releases) 2 | [Get it on F-Droid](https://f-droid.org/packages/org.billthefarmer.siggen) 3 | 4 | A signal generator for Android. The app can be downloaded from [F-Droid](https://f-droid.org/packages/org.billthefarmer.siggen) 5 | and [here](https://github.com/billthefarmer/sig-gen/releases). 6 | 7 | ![](https://github.com/billthefarmer/billthefarmer.github.io/raw/master/images/SigGen.png) 8 | 9 | * Frequency range 0.1Hz - 25KHz 10 | * Level range 0dB - -80dB 11 | * Set exact frequency 12 | * Frequency bookmarks 13 | * Square wave duty cycle 14 | * Shortcut 15 | * External control 16 | 17 | ### Using 18 | The frequency knob responds to finger twirling. The duty cycle, fine 19 | frequency and level sliders allow for adjustments of square wave duty 20 | cycle, fine frequency and output level. The frequency knob is also 21 | adjustable using the left and right arrow buttons above. The two 22 | bookmark buttons below the frequency knob show if there are bookmarks, 23 | and will go to the next lower or higher bookmark if it exists. 24 | 25 | The toolbar items are, from left to right: 26 | * **Exact** - Prompt for an exact frequency 27 | * **Bookmark** - Save the current frequency as a bookmark 28 | * **Sleep** - Prevent the device from sleeping 29 | 30 | To remove a bookmark, go to it and touch the toolbar bookmark button. 31 | 32 | ### Shortcut 33 | A shortcut may be created to set the parameters shown below. Empty 34 | frequency, duty cycle and level values and unchecked waveform values 35 | will not be included. The mute value will always be included. The name 36 | of the shortcut will be composed from the set values if the name field 37 | is empty. 38 | 39 | ### External Control 40 | The app may be started, the frequency, level, duty cycle, waveform and 41 | mute set externally by sending a suitable 42 | [Intent](https://developer.android.com/reference/android/content/Intent) 43 | from an automation app. The app package/activity is 44 | `org.billthefarmer.siggen/org.billthefarmer.siggen.Main`. The 45 | parameters may be: 46 | 47 | | Parameter | Action/Category/Extra | Type | Value | 48 | | --------- | --------------------- | ---- | ----- | 49 | | Action | android.intent.action.MAIN | 50 | | | android.intent.action.DEFAULT | 51 | | Category | android.intent.category.LAUNCHER | 52 | | | android.intent.category.DEFAULT | 53 | | Extras | org.billthefarmer.siggen.SET_FREQ | int, float | 0.1 – 25000 | 54 | | | org.billthefarmer.siggen.SET_LEVEL | int, float | -80 – 0 | 55 | | | org.billthefarmer.siggen.SET_DUTY | int, float | 0 – 100 | 56 | | | org.billthefarmer.siggen.SET_WAVE | int | 0 = Sine | 57 | | | | | 1 = Square | 58 | | | | | 2 = Sawtooth | 59 | | | org.billthefarmer.siggen.SET_MUTE | boolean | true, false | 60 | 61 | Any combination of extras or none may be sent. Subsequent intents sent 62 | will update the values from the included extras. 63 | 64 | This may be tested using the [Android Debug 65 | Bridge](https://developer.android.com/studio/command-line/adb#am). 66 | ```shell 67 | $ adb shell am start --ef org.billthefarmer.siggen.SET_FREQ 257.3 --ef org.billthefarmer.siggen.SET_LEVEL -25.2 org.billthefarmer.siggen/.Main 68 | Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=org.billthefarmer.siggen/.Main (has extras) } 69 | $ adb shell am start --ez org.billthefarmer.siggen.SET_MUTE true org.billthefarmer.siggen/.Main 70 | Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=org.billthefarmer.siggen/.Main (has extras) } 71 | Warning: Activity not started, its current task has been brought to the front 72 | ``` 73 | -------------------------------------------------------------------------------- /src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 15 | 16 | 17 | 38 | 39 | 46 | 47 | 48 | 69 | 70 | 77 | 78 | 85 | 86 | 92 | 93 | 94 | 100 | 101 | 102 | -------------------------------------------------------------------------------- /src/main/res/layout/shortcut.xml: -------------------------------------------------------------------------------- 1 | 2 | 12 | 13 | 21 | 22 | 30 | 31 | 39 | 40 | 48 | 49 | 55 | 56 | 61 | 62 | 67 | 68 | 73 | 74 | 75 | 76 | 83 | 84 | 91 | 92 |