Submit Search
Upload
手抜き大好きPSoC
•
1 like
•
2,600 views
H
hatris
Follow
2014/9/20に開催されたPSoCまつりにて紹介しました、手抜き工作をする為のPSoCの使い方についてのプレゼン資料です。
Read less
Read more
Devices & Hardware
Report
Share
Report
Share
1 of 23
Download now
Download to read offline
Recommended
P○cでいいって言わないで
P○cでいいって言わないで
hatris
2014年も終わり!?いや...俺たちの戦いは...始まったばかりだッ!!!
2014年も終わり!?いや...俺たちの戦いは...始まったばかりだッ!!!
高広 内山
Iron python と c sharp
Iron python と c sharp
Satoshi Mimura
PSoCまつり「PSoCの美味しい料理法」
PSoCまつり「PSoCの美味しい料理法」
betaEncoder
PSoC4 ことはじめ -BLE版-
PSoC4 ことはじめ -BLE版-
Tetsuya Noguchi
MDK-ARMでPSoC開発
MDK-ARMでPSoC開発
Yoshihiro Tsuboi
オレオレ家電
オレオレ家電
magoroku Yamamoto
PSoC Powered Human Powered Airplane
PSoC Powered Human Powered Airplane
HirakuTOIDA
Recommended
P○cでいいって言わないで
P○cでいいって言わないで
hatris
2014年も終わり!?いや...俺たちの戦いは...始まったばかりだッ!!!
2014年も終わり!?いや...俺たちの戦いは...始まったばかりだッ!!!
高広 内山
Iron python と c sharp
Iron python と c sharp
Satoshi Mimura
PSoCまつり「PSoCの美味しい料理法」
PSoCまつり「PSoCの美味しい料理法」
betaEncoder
PSoC4 ことはじめ -BLE版-
PSoC4 ことはじめ -BLE版-
Tetsuya Noguchi
MDK-ARMでPSoC開発
MDK-ARMでPSoC開発
Yoshihiro Tsuboi
オレオレ家電
オレオレ家電
magoroku Yamamoto
PSoC Powered Human Powered Airplane
PSoC Powered Human Powered Airplane
HirakuTOIDA
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
Skeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
Introduction to Data Science
Introduction to Data Science
Christy Abraham Joy
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
Vit Horky
The six step guide to practical project management
The six step guide to practical project management
MindGenius
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
More Related Content
Featured
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
Skeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
Introduction to Data Science
Introduction to Data Science
Christy Abraham Joy
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
Vit Horky
The six step guide to practical project management
The six step guide to practical project management
MindGenius
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
Featured
(20)
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
Skeleton Culture Code
Skeleton Culture Code
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
How to have difficult conversations
How to have difficult conversations
Introduction to Data Science
Introduction to Data Science
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
The six step guide to practical project management
The six step guide to practical project management
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
手抜き大好きPSoC
1.
手抜き大好きPSoC HATRIS 1
2.
HATRISとは? @HatrisのIDでTwitterに住んでいる 空飛ぶ鉄の塊を好む
よくわからないものが大好き しがないサラリーマンをしながら、稼ぎ を秋月などに流し込む簡単な人生をおくっ ている 仮の姿はFA系エンジニア 以前CYPRESSの呪いを受けてしまい、 以来何かとPSoCを使いたがる 2
3.
鉄の塊たち 3
4.
HATRISが作ると? 4
5.
PSoCで手が抜ける? ちょこちょこ手抜きをしてみました できるだけ部品をつけない
できるだけコードを書かない できるだけ資料を漁らない 5 どんなふうに?
6.
部品を減らしてみる これはL-Knobっていいます。 I2Cでつないでつまみの値を読んだり光らせたりできます。
6
7.
大層な事はしてませんが、 プルアップ・ダウン抵抗を 省いています。
7
8.
GPIOをPull-Up/Downに設定し、該当I/Oピンに0ないし1を 出力することで内蔵抵抗によるPull-Up/Downができます。 8
9.
結果 PULL-UP/DOWN抵抗を入れると総点数10点 となるものが、7点で済みました。
30%の削減! 9
10.
他の物も見てみましょう 出オチ臭のするガオガイガーカウンターです。 GM管が放射線を検出すると、「ガガガッ」っていいます。
10
11.
中はこんな感じになってます 主要部品は、PSoC1・EEPROM・AF-Amp・トランス・ 整流用ダイオード・GM管くらいです。
11
12.
PSoCの中では 12 PWMにてトランスに供給する1次
側電源パルスを作成。 カウンターにてD/Aのクロックを 作成。更にカスケードして D/Aのデータ更新周期も作成。 GMTからの検出パルスを受け割 り込みを発生。 検出音を再生する為のD/AとLPF。 残念ながら出音はザラザラ。 各種設定用のボリュームの値を読 み取るA/D。
13.
ソフトについては 処理を各種モジュールからの割り込みとして 構築すれば、イベントドリブン的な感じで
ソフトを組む事ができ、ソフトがすっきりします。 13 main DetDigBuf _Int DaUpdate C8_Int 各モジュールの初期設定 データ表示 音の再生開始処理及びデータの補充 検出のカウント増加 音データバッファからD/A値の更新
14.
更にIDEの便利機能で資料いらず 14 モジュール配置画面でも、
コード書く画面でも、データ シートを引っ張りだせるので *英語に抵抗がなければ* 資料管理の手間いらず。
15.
他の石でもできるって? 多少PSoCの優位性を活かしてるところで、 HDDを使った時計を紹介します。
15
16.
16 中身はこんな 感じです
17.
動作解説 LED フォトインタラプタ
17 スリット 高速回転するスリット付きの プラッターの裏面から、 タイミングよくLEDを点けて やることで、光の針を表示して います。 ! フォトインタラプタによって スリットの通過を検出し、 そこからの時間経過を高精度に 計る事で、安定した針の表示が 可能になります。 ! PSoCでは多数のカウンターを ハード的に持てるので、精度の 高い時間制御が楽にできます。 7200rpmのHDDなので 1周する時間は8.3ms程
18.
その為に プラッターが1周する時間を250ns 単位で計測。
18 針を表示するタイミングを上と同 じ分解能で計測。 表示する針の太さを調整する為に 1us単位で計測。 時を刻む為の1secタイマー。 針の色を作るRGB各8bitのPWM。 表示のチラツキを無くす為に 48MHzのクロックを供給。 基準点となるスリット検出機構。 センサー出力をコンパレータで受 け、割り込みを発生させる。
19.
PSoCで良かった点 ハードカウンターによる計測 定時割り込みによるソフトカウントではCPUパワーを喰う
割に高い精度が出せないので、表示がふらついてしまう。 割り込みベースでの処理 処理が必要なタイミングで割り込みが発生するので、 カウンターやPWMの設定を変更するような簡単なコード だけで表示ができる。 圧倒的に速い周期で動くPWM 原発の24MHzの2倍の48MHzのクロックを投入することが でき、そのおかげでバックグランドに色を付けた際も、 色むら無く綺麗に表示することが可能に。 遅いクロックを入れると縞模様になってしまった。 19
20.
おまけにもう一つ PSoC1ならでは?の使い方の例を紹介します 20
21.
何の変哲も無いようですが 21 PSoC1の低電圧動作の仕組
みは一風変わっており、 低電圧で動作する代わりに PSoC1がSwitch mode pump 用のコントローラーを内蔵 して動作に必要な電圧まで 昇圧してくれるというもの。 CypressがApplication note で紹介している内容による と、うまくやれば70mA位ま で取れるらしい。 この例では、Eneloop 2本 (実測で約2.6V)にて5Vの LCDを動かしている。
22.
これがSMPブーストの実験の様子。 PSoC1の内部回路ではスイッチン グしきれない為、外部にFETを設
けてやることで電流を増やせる。 ! Application noteによれば、500mA くらいまで出せるそうだ。 22
23.
最後に 他のマイコンと比べ、内部モジュールの自由度が高 く、ピン配置についても自由度が高いPSoCですが、
もちろん制約はあり、なんでも自由になるわけでは ないので、始めはTechnical Refference Manualに目 を通し、罠にはまらないよう楽しみましょう。 手抜き大好き 23 PSoC HATRISでした
Download now