在线观看www成人影院-在线观看www日本免费网站-在线观看www视频-在线观看操-欧美18在线-欧美1级

電子發燒友App

硬聲App

0
  • 聊天消息
  • 系統消息
  • 評論與回復
登錄后你可以
  • 下載海量資料
  • 學習在線課程
  • 觀看技術視頻
  • 寫文章/發帖/加入社區
會員中心
創作中心

完善資料讓更多小伙伴認識你,還能領取20積分哦,立即完善>

3天內不再提示
電子發燒友網>電子資料下載>電子資料>Neko Punk合成器V2開源分享

Neko Punk合成器V2開源分享

2023-02-10 | zip | 0.11 MB | 次下載 | 免費

資料介紹

描述

大家好,歡迎回來,這是我的 Neko Punk Synth Version 2,它是以貓為主題的合成器,由 Arduino Nano 和 Mozzi 庫提供支持。

?

通過改變 5 個滑動罐的位置,Mozzi 可以產生更加復雜和有趣的咆哮、掃動和合唱聲音。這些聲音可以通過熟悉的合成單元(如振蕩器、延遲和濾波器)快速輕松地構建。

我幾周前制作的 Previous 版本是基于最初的 Atari Punk Console,最初是由Forrest Mims在1980 年制作的。它使用觸發單穩態設置的非穩態多諧振蕩器設置。通過組合這兩個設置,我們得到一個步進音發生器或一個 atari 朋克合成器。

pYYBAGK6XgOATledAAB8WaBT2Zo301.jpg

這很容易做,但我對它的結果不滿意。

一年前,我用 Mozzi Library 制作了一個類似的合成器,效果非常好,所以我想為什么不在 Neko Punk Synth 的 V2 中使用 Mozzi,為了讓事情變得超級酷,我使用了滑動罐,讓這個合成器具有了賽博朋克的感覺——看起來。

所需材料

這些是這個建筑中使用的東西-

阿杜諾納米

PAM8403 音頻放大器

PCBWAY提供的定制PCB

鋰離子 5V 升壓模塊

3.7V 鋰離子電池

3D 打印外殼

4歐喇叭

滑塊盆

電路設計

V2 PCB 可能是我做過的最簡單的電路板。

它使用 Arduino Nano 作為基礎微控制器,五個滑塊盆與 Arduino nano 連接。

poYBAGK6XguAfJ3fAAFca0yEPSg323.jpg

D9 進入 PAM8403 音頻放大器模塊的輸入端,PAM8403 的輸出端與兩個 CON2 引腳相連,因此我們可以用它添加揚聲器。

整個設置需要 5V 才能工作。

要為這個設置供電,我必須使用你可以在網上找到的這個鋰離子電池升壓模塊,這些模塊非常便宜而且工作得很好。

1 / 2

它將 3.7V 的鋰離子電池升壓至恒定的 5V 1A 或 2A,以便我們的 MCU 設置正常工作。

我在我的 OrCad PCB 套件中準備了 PCB,并添加了一些圖形以增加電路板的美感。

從 PCBWAY 獲取電路板

我在這個項目中使用了 PCBWAY PCB 服務。我在PCBWAY的報價頁面上傳了這個項目的Gerber文件。

對于這個 Synth 板,我選擇了白色阻焊層顏色,因為我在板的頂部添加了很多圓形圖形和自定義藝術。

黑色絲印搭配白色阻焊顏色看起來很棒。

我在一周內收到了 PCB,PCB 質量非常好,這個 PCB 很大,我喜歡這些 PCB 的質量沒有因為尺寸而受到影響。

印刷電路板組裝

現在這塊板沒有任何 SMD Componenets 所以我們只需要手動將所有東西放在這塊板上并用烙鐵焊接它們。

我首先收集所有材料并開始使用滑動電位器進行組裝。

然后我將所有的 Pot 從頂部放在它們的位置,并從 PCB 的底部焊接它們的焊盤。

在此之后,我在它們的位置添加了 Arduino Nano 和 PAM8403 模塊,組裝就差不多完成了。

上傳代碼

這是基于 Mozzi 庫的項目的主要草圖。

?

/* 
  Example using 2 light dependent resistors (LDRs) to change 
  FM synthesis parameters, and a knob for fundamental frequency,
  using Mozzi sonification library.

  Demonstrates analog input, audio and control oscillators, phase modulation
  and smoothing a control signal at audio rate to avoid clicks.
  Also demonstrates AutoMap, which maps unpredictable inputs to a set range.
  
  This example goes with a tutorial on the Mozzi site:
  http://sensorium.github.io/Mozzi/learn/Mozzi_Introductory_Tutorial.pdf
  
  The circuit:
     Audio output on digital pin 9 (on a Uno or similar), or 
     check the README or http://sensorium.github.com/Mozzi/

     Potentiometer connected to analog pin 0.
       Center pin of the potentiometer goes to the analog pin.
       Side pins of the potentiometer go to +5V and ground
  
     Light dependent resistor (LDR) and 5.1k resistor on analog pin 1:
       LDR from analog pin to +5V
       5.1k resistor from analog pin to ground
     
     Light dependent resistor (LDR) and 5.1k resistor on analog pin 2:
       LDR from analog pin to +5V
       5.1k resistor from analog pin to ground
  
  Mozzi help/discussion/announcements:
  https://groups.google.com/forum/#!forum/mozzi-users

  Tim Barrass 2013.
  This example code is in the public domain.
*/

#include 
#include  // oscillator 
#include  // table for Oscils to play
#include 
#include  // maps unpredictable inputs to a range
 
// int freqVal;
 
// desired carrier frequency max and min, for AutoMap
const int MIN_CARRIER_FREQ = 22;
const int MAX_CARRIER_FREQ = 440;

const int MIN = 1;
const int MAX = 10;

const int MIN_2 = 1;
const int MAX_2 = 15;

// desired intensity max and min, for AutoMap, note they're inverted for reverse dynamics
const int MIN_INTENSITY = 700;
const int MAX_INTENSITY = 10;

// desired mod speed max and min, for AutoMap, note they're inverted for reverse dynamics
const int MIN_MOD_SPEED = 10000;
const int MAX_MOD_SPEED = 1;

AutoMap kMapCarrierFreq(0,1023,MIN_CARRIER_FREQ,MAX_CARRIER_FREQ);
AutoMap kMapIntensity(0,1023,MIN_INTENSITY,MAX_INTENSITY);
AutoMap kMapModSpeed(0,1023,MIN_MOD_SPEED,MAX_MOD_SPEED);
AutoMap mapThis(0,1023,MIN,MAX);
AutoMap mapThisToo(0,1023,MIN_2,MAX_2);

const int KNOB_PIN = 0; // set the input for the knob to analog pin 0
const int LDR1_PIN=1; // set the analog input for fm_intensity to pin 1
const int LDR2_PIN=2; // set the analog input for mod rate to pin 2
const int LDR3_PIN=4;
const int LDR4_PIN=3;

Oscil aCarrier(COS2048_DATA);
Oscil aModulator(COS2048_DATA);
Oscil kIntensityMod(COS2048_DATA);

int mod_ratio = 5; // brightness (harmonics)
long fm_intensity; // carries control info from updateControl to updateAudio

// smoothing for intensity to remove clicks on transitions
float smoothness = 0.95f;
Smooth  aSmoothIntensity(smoothness);


void setup(){
//  Serial.begin(115200); // set up the Serial output so we can look at the light level
  startMozzi(); // :))
}


void updateControl(){
  
//  freqVal = map(LDR3_PIN, 0, 1023, 1, 100);
  
   int freqVal = mozziAnalogRead(LDR3_PIN); // value is 0-1023
   int FRQ = mapThis(freqVal);
   
   int knob2 = mozziAnalogRead(LDR4_PIN); // value is 0-1023
   int knob2Val = mapThis(knob2);
  
  // read the knob
  int knob_value = mozziAnalogRead(KNOB_PIN); // value is 0-1023
  
  // map the knob to carrier frequency
  int carrier_freq = kMapCarrierFreq(knob_value);
  
  //calculate the modulation frequency to stay in ratio
  int mod_freq = carrier_freq * mod_ratio * FRQ;
  
  // set the FM oscillator frequencies
  aCarrier.setFreq(carrier_freq); 
  aModulator.setFreq(mod_freq);
  
  // read the light dependent resistor on the width Analog input pin
  int LDR1_value= mozziAnalogRead(LDR1_PIN); // value is 0-1023
  // print the value to the Serial monitor for debugging
  //Serial.print("LDR1 = "); 
 // Serial.print(LDR1_value);
 // Serial.print("\t"); // prints a tab

  int LDR1_calibrated = kMapIntensity(LDR1_value);
 // Serial.print("LDR1_calibrated = ");
 // Serial.print(LDR1_calibrated);
//  Serial.print("\t"); // prints a tab
  
 // calculate the fm_intensity
  fm_intensity = ((long)LDR1_calibrated * knob2Val * (kIntensityMod.next()+128))>>8; // shift back to range after 8 bit multiply
//  Serial.print("fm_intensity = ");
 // Serial.print(fm_intensity);
//  Serial.print("\t"); // prints a tab
  
  // read the light dependent resistor on the speed Analog input pin
  int LDR2_value= mozziAnalogRead(LDR2_PIN); // value is 0-1023
//  Serial.print("LDR2 = "); 
//  Serial.print(LDR2_value);
//  Serial.print("\t"); // prints a tab
  
  // use a float here for low frequencies
  float mod_speed = (float)kMapModSpeed(LDR2_value)/1000;
  //Serial.print("   mod_speed = ");
 // Serial.print(mod_speed);
  kIntensityMod.setFreq(mod_speed);
  
 // Serial.println(); // finally, print a carraige return for the next line of debugging info
}


int updateAudio(){
  long modulation = aSmoothIntensity.next(fm_intensity) * aModulator.next();
  return aCarrier.phMod(modulation);
}


void loop(){
  audioHook();
}

?

代碼很長,但基本上,它在 Mozzi 庫上運行,無需額外的屏蔽、消息傳遞或外部合成器即可生成算法音樂。這個庫有很好的文檔記錄,所以你可以從這里查看并下載它。在上傳這個草圖之前安裝這個庫。

https://sensorium.github.io/Mozzi/

?

const int KNOB_PIN = 0; // set the input for the knob to analog pin 0
const int LDR1_PIN=1; // set the analog input for fm_intensity to pin 1
const int LDR2_PIN=2; // set the analog input for mod rate to pin 2
const int LDR3_PIN=4;
const int LDR4_PIN=3;

?

POT 連接在 A0、A1、A2、A3、A4 上,音頻輸出為 D9。

測試

現在上傳草圖后,我添加了一個 4ohm 揚聲器和 PAM8403 模塊的 CON2。

為了暫時為這個設置供電,我使用了一個移動電源為 Arduino Nano 提供 5V 2A。

要調制聲音,我們只需更改所有 5 個滑動罐的位置,這幾乎就是整個測試過程。

接下來,我們進入最后的組裝過程。

3D 打印外殼

至于 Body of the Synth,我們通常使用類似盒子的外殼來容納揚聲器和電子設備。

我的想法是在正面制作一張貓臉,讓它看起來像一只 BOX CAT,我在正面添加了貓的面部特征,如胡須、鼻子和眼睛。

我在 fusion360 中對身體建模,然后在我的 ender 3 上 3D 打印每個部分。

我用橙色 PLA 準備了主體,用黑色 PLA 準備了瞳孔、眉毛、胡須和鼻子,用白色 PLA 準備了眼睛。

打印設置也很正常,我使用了一個 0.8mm 的噴嘴,層高為 0.32mm,填充率為 20%,并為基體提供了支撐。

打印完所有部件后,我用強力膠將所有面部部件連接到基體上。

最后組裝

現在我們開始主要組裝,首先添加我們用螺母和螺栓將揚聲器添加到底座上。

接下來,我將 DC 插孔和翹板開關添加到基體中。

然后我們將 Lithium Boost 模塊與 DC 插孔和開關連接起來。

然后我把所有的東西都放在身體里,用一些 M2 螺絲從底部添加主 PCB,組裝就完成了。

結果

要打開此設置,我們只需按下翹板開關并更改滑動罐位置即可調制聲音。

感謝您閱讀這篇文章,我很快就會帶著另一個項目回來。

和平

?

下載該資料的人也在下載 下載該資料的人還在閱讀
更多 >

評論

查看更多

下載排行

本周

  1. 1九陽豆漿機高清原理圖
  2. 2.47 MB   |  12次下載  |  1 積分
  3. 2數能NU501系列恒流芯片型號選型表
  4. 0.04 MB   |  2次下載  |  免費
  5. 3AIWA J470維修手冊 (可直接打?。?/a>
  6. 3.16 MB   |  2次下載  |  10 積分
  7. 4基于51/32單片機按鍵控制步進電機正反轉,A4988驅動
  8. 2.05 MB   |  2次下載  |  1 積分
  9. 5STM32F10xxx單片機編程手冊
  10. 0.29 MB   |  2次下載  |  免費
  11. 6HR1124S/9110S單通道低壓H橋電機驅動芯片中文手冊
  12. 1.30 MB   |  1次下載  |  免費
  13. 7MOSFET講解-02(可下載)
  14. 263.46 KB  |  1次下載  |  免費
  15. 8MOSFET講解-03(可下載)
  16. 501.18 KB  |  1次下載  |  免費

本月

  1. 1晶體三極管的電流放大作用詳細說明
  2. 0.77 MB   |  30次下載  |  2 積分
  3. 2雙極型三極管放大電路的三種基本組態的學習課件免費下載
  4. 4.03 MB   |  23次下載  |  1 積分
  5. 3第十一屆 藍橋杯 單片機設計與開發項目 省賽 程序設計試題及源碼
  6. 90.88KB   |  23次下載  |  3 積分
  7. 4Python從入門到精通背記手冊
  8. 18.77 MB   |  22次下載  |  1 積分
  9. 5多級放大電路的學習課件免費下載
  10. 1.81 MB   |  20次下載  |  2 積分
  11. 6STM32F103C8T6開發板最小系統原理圖
  12. 0.78 MB   |  20次下載  |  免費
  13. 7九陽豆漿機高清原理圖
  14. 2.47 MB   |  12次下載  |  1 積分
  15. 81875功放原理圖
  16. 0.04 MB   |  11次下載  |  免費

總榜

  1. 1matlab軟件下載入口
  2. 未知  |  935127次下載  |  10 積分
  3. 2開源硬件-PMP21529.1-4 開關降壓/升壓雙向直流/直流轉換器 PCB layout 設計
  4. 1.48MB  |  420063次下載  |  10 積分
  5. 3Altium DXP2002下載入口
  6. 未知  |  233089次下載  |  10 積分
  7. 4電路仿真軟件multisim 10.0免費下載
  8. 340992  |  191382次下載  |  10 積分
  9. 5十天學會AVR單片機與C語言視頻教程 下載
  10. 158M  |  183337次下載  |  10 積分
  11. 6labview8.5下載
  12. 未知  |  81585次下載  |  10 積分
  13. 7Keil工具MDK-Arm免費下載
  14. 0.02 MB  |  73814次下載  |  10 積分
  15. 8LabVIEW 8.6下載
  16. 未知  |  65988次下載  |  10 積分
主站蜘蛛池模板: 亚洲1页 | 看片久久| 亚洲毛片网 | 色婷婷综合在线视频最新 | 国产免费高清福利拍拍拍 | 四虎影院在线网址 | 1024人成网色www| 色噜噜狠狠狠狠色综合久一 | 五月婷婷在线视频 | 黄色的网站在线观看 | 日日夜夜爽 | 2020年亚洲天天爽天天噜 | 久久草在线视频国产一 | 国产一区中文字幕 | 国产午夜精品理论片在线 | 欧美一级免费观看 | 久久成人网18网站 | 毛片新网址 | 色天使久久综合给合久久97色 | 国产精品视频一区国模私拍 | 好男人社区www在线资源视频 | 视频网站免费看 | 伊人网视频 | 久青草国产在线视频_久青草免 | 四虎传媒| 国产精品www视频免费看 | 加勒比黑人喝羽月希奶水 | 久久久噜噜噜久久 | 免费一级欧美片片线观看 | 午夜性爽快 | 日本在线亚洲 | 国产精品怡红院永久免费 | 欧美在线视频免费 | 国产成人精品本亚洲 | 美女扒开下面让男人捅 | 久久国产精品99久久久久久老狼 | 久久波多野结衣 | 国产v69| 日本人亚洲人成人 | 亚洲第一黄色网 | 欲香欲色天天综合和网 |