跳转至内容
  • 26 主题
    37 帖子
    FrankieF
    Overview

    YUNTU MCAL(Microcontroller Abstract Layer) software package is designed by YTMicro AE team to support customers on AUTOSAR compliant application software development. The YUNTU MCAL is developed according to the AUTOSAR CP Release v4.4.0 standard.

    Package Name Version Release Date YTM32B1ME1_0_8_0 0_8_0 2026-03-06 Support Toolchains

    YUNTU MCAL software package release are tested and validated with the following toolchains/IDE:

    Recommended Configuration Tool:

    YCT(Yuntu Config Tool) v2.7.7 or higher version

    Tips: It can be downloaded from YTMicro Account or updated from the installed older version YCT.

    Recommended IDE/Compilers:

    ARM Keil v5.36 or higher version IDE IAR v8.40 or higher version IDE VSCode v1.80 or higher version IDE with Ninja, CMake and GCC/IAR/Keil as compiler GCC for ARM v10.3 or higher version

    Recommended debuger:

    SEGGER J-INK v9.2 or higher hardware + v6.96 or higher software/driver with required YTM32B1ME05 and YTM32B1MD14 patch installed. Release List [New]-[Platform]-[EL0: ] Init Platform module for YTM32B1ME1, Support BVT and SecureBoot config. [New]-[CddPpu]-[EL0: ] Init CddPpu module for YTM32B1ME1 [New]-[Icu]-[EL0: ] Init Icu module for YTM32BIME1, support eTMR, Port, ACMP and MPWM based Icu channel configuration and code generation. [New]-[CddDma]-[EL0: ] Init CddDma module for YTM32B1ME1 [New]-[Spi]-[EL0: ] Init Spi module for YTM32B1ME1 [New]-[Pwm]-[EL0: ] Init the Pwm module for YTM32BIME1, support eTMR and MPWM based PWM channel configuration and code generation. [New]-[Mcu]-[EL0: ] Init Mcu module for YTM32B1ME1. [New]-[Ocu]-[EL0: ] Init Ocu module for YTM32BIME1 [New]-[Adc]-[EL0: ] Init the Adc module for YTM32B1ME1. [New]-[Port]-[EL0: ] Init Port module for YTM32BIME1. [New]-[Gpt]-[EL0: ] Init Gpt module for YTM32B1ME1. [New]-[Crc]-[EL0: ] Init Crc module for YTM32B1ME1. [New]-[CddI2c]-[EL0: ] Init CDDI2c module for YTM32B1ME1. [New]-[Dio]-[EL0: ] Dio supports reading from and writing to the pins of YTM32B1ME1. [New]-[CddUart]-[EL0: ] Init CddUart module for YTM32B1ME1,update CddUart Idle demo. [New]-[Eep]-[EL0: ] Init the Eep module for YTM32BIME1 [New]-[Lin]-[EL0: ] Init Lin module for YTM32B1ME1. [New]-[Crypto]-[EL0: ] Init the Crypto module for YTM32BIME1 [New]-[Wdg]-[EL0: ] Init the Wdg module for YTM32BIME1 Annex Release list naming rule

    Each release list item shall contain the following elements:

    [Type] - [Sub-Type/Module] - [Effect_Level] [Brief/Overview Description][Reference/Details Link]

    [Type] Fix: Bug fixes / issue resolution Opt: Code performance optimization New: New feature implementation Demo: Example / demonstration project Doc: Documentation updates [Sub-Type/Module] MCAL: Mcu/Dio/Port/Can/Lin/Spi/Gpt/Pwm/Adc/Icu/Ocu/Fls/Fee/Platform/CddUart/CddSai/CddPpu/CddI2c/CddDma/CddTrg SafLib: CorTst/RamTst/FlsTst/IntTst/WdgTst/CrcTst/DmaTst/PpuTst/EfmTst/StkTst/EccTst/FmuTst GUI: the YCT XDM config GUI update for the MCAL/SafLib SW package, the YCT Vue config GUI update for the SDK/Middleware SW package(no code change/modification) [Effect_Level] 0: No effect to the old version SW/project 1: Recommend but optional to update, for example the performance optimization 2: Must update for a specified SW module/components if the customer application used the related feature/functionality 3: Must update for a specified SW module/components if it is used 4: Must update if the SDK/MCAL/SafLib package is used [Brief/Overview Description] [Type] = Fix: Fixed the xxx issue/bug of the yyy HW/SW functionality/feature caused by condition [Type] = Opt: Optimized the performance of the yyy HW/SW functionality/feature [Type] = New: Added the new feature/functionality support of xxx [Type] = Demo: added/updated the demo project: brief description [Reference/Details Link] Errata: give out the detailed Errata number others: the link to the bug/issue analysis, it can be: Link to a YUNTU form post [if it is derived from a FAE/customer feedback] Link to a YUNTU form blog [if it is derived from a YUNTU form blog discussion] Disclaimer

    Copyright and Contact Information

    img

    YTMicro and its subsidiaries reserve the right to change, correct, enhance, modify and improve YTMicro products or this document at any time without notice. Before placing an order, purchasers should obtain and understand the latest relevant information about the products. YUNTU's products are sold according to YUNTU team and sales conditions at the time of order confirmation. Purchasers have the sole responsibility for selecting, choosing and using YUNTU products, and YUNTU has no responsibility for assisting purchasers in product design and application. YUNTU does not grant any express or implied license to any intellectual property herein. Resale of YUNTU products with information different from that described herein will make any warranty of YUNTU for such product void. YTMicro and YTMicro logo are trademarks of YTMicro. All other product or service names are the property of their respective owners. The information in this document replaces and supersedes any previously provided information in any prior version of this document. © 2020 - 2026 YUNTU Microelectronics co.,ltd. All rights reserved.

    Contact us: Website: www.ytmicro.com.

  • 2k 主题
    7k 帖子
    D
    1. 版本

    Config Tool Version:2.7.8
    ME05 SDK version:1.4.0
    EVB version: YTM32B1ME0-EVB-Q144 Rev.C

    2.前言

    有客户需要用MCU引脚输出特定波形进行通信,如下图:
    54fe2b5d-4f3f-43d4-83e2-a5cf1d39d48c-image.png
    MCU没有特定的硬件外设可以输出这种波形,使用IO模拟会很占用CPU资源,但是用SPI进行组帧可以模拟出这种波形
    通过调整SPI的波特率和帧间隔时间去满足它的时序要求。

    3.方案

    固定发送特定的组帧,即用一个SPI帧去模拟一bit时序,如下图:
    c1612f8c-76fe-46d0-ba39-c568f64b541f-image.png
    设定SPI的帧长度(Framesize)为6,0码 高电平/低电平时间:1/2;1码 高电平/低电平时间:2/1.

    3.1 波特率计算

    如上时序中1bit的理想时间是720ns,我们假设是750ns,即SPI一帧750ns,
    那SPI的1bit就是 750ns/6 = 125ns,可得SPI的波特率为1 / 125ns = 1 / 0.000 000 125 = 8M.即设定SPI的波特率为8M最合适。

    4. 示例工程配置 4.1 SPI时钟配置

    功能时钟选择PLL, 120M时钟, 3分频,所以SPI的功能时钟为40M.
    278d4ba8-cd11-4da1-acd5-6dbf5778f475-image.png

    4.2 SPI功能配置

    这里只考虑主机发送的配置:
    fde763e0-db49-4f03-92d5-bb3a8fc4a656-image.png
    因为要尽量满足时钟波形连续无间隔,需要对CS2CLK,CLK2CS,Frame2Frame进行微调,这里都设置1。
    1bdf13d4-bad8-4daf-9b43-187bd7247988-image.png
    设置为Frame2Frame讲个刚好为60ns,与时钟线的负脉宽基本一样
    b8834884-cfc8-48c4-97ae-91e783fa09b5-image.png

    4.3 码元转换函数

    此函数可将16进制数据转化为对应的码元数据,方便SPI发送函数传参。
    比如说0x23,它的二进制数据是0010 0011,转换后的数据数组就是
    {0x30, 0x30,0x3C, 0x30, 0x30, 0x30,0x3C, 0x3C}
    e35dc1bd-fddb-44c8-877b-15305751dd52-image.png

    5. 实测波形 5.1 发送全0数据:

    T0H典型值:250ns。
    T0L典型值:500ns。
    5f946a40-374b-46a4-ab9d-a9daf0cc8f83-image.png

    5.2 发送全1数据:

    T1H典型值:500ns。
    T1L典型值:250ns。
    d79c86bd-3f64-4827-b6dd-3f1b48a23ef5-image.png

    5.3 随机数据

    12f2b216-ff1b-4829-84fc-fb75ba6ab282-image.png

    5.4 Reset码

    249495ab-18ee-414f-8cfa-1859fa161ae5-image.png

    6. 示例工程

    SPI模拟时序波形.zip

  • Blog posts from individual members

    46 主题
    145 帖子
    车友车行

    install对应的middleware

    image.png

  • 云途开发生态介绍

    快速上手云途开发生态

  • 云途论坛规则/Yuntu Forum Rules

    发帖前请查看

  • YT CONFIG TOOL调查问卷

    帮助改进和优化YT CONFIG TOOL,有机会抽取YTM32B1ME0 EVB哦...

  • Online Users