THE POSSIBILITIES ARE INFINITE


MB90340 Series

SMPL16

DESCRIPTION

Example Projects for MB90340 MCU
NOTE:
The header-file will cover all features of the Emulation chip MB90V340/S. No Flash- or Mask- version of the MB90340series will support all features! Limitaions can be found in UARTs, CANs, I2C, ADC, etc. Please DO NOT USE resources / registers others than specified for the dedicated Flash-/Mask-version. Please refer to the datasheet and hardwaremanual of the MB90340series.

To install the Software Sample Files please download the compressed self-extracting file. The Standard Installation Target Directory is:

C:\Softune\sample\smpl16

FEATURES

  • ADC_EI2OS:
    This example will use the EIIOS-transfer to move the conversion-data from ADC-channel 0 .. 31 automatically without MCU intervention to RAM. After the last conversion an interrupt is called and the RAM-data is displayed on the LEDs, in case that the Flash-CAN-100-340 evaluation board is used.
    Note: Different bit name of register in Header files
address register name bit name hardware-manual bit name header file
0x3F CKOE CKOE OE
0x3F CKOE CKXOE XO
  • ADconv:
    This sample uses an Analoge - Digital conversation. The AD converter catches a digital value from signal on Pin 37 (AN1). The value from the AD converter is shown on Port 0 (LED´s).
  • ADC-RLT1:
    The ADC_RLT1 example project will convert continously the ADC channel 0..2. The sample rate (ADC trigger) is defined by the Reload-Timer 1. The channel-number and value will be send via UART1 (38400Baud @ 16MHz). No interrupt is used.

    The ADC_uDMA example is using ADC interface. Continuous mode, AN0. Via uDMA the conversion results are transfered to an buffer. After 20 measurements the ADC is stopped. Datas are ouput via UART0 interface. (38400 bd, 8N1).
  • AD-Uart:
    This sample uses an Analoge - Digital conversation and UART0 The AD converter catches a digital value from signal on Pin 37 (AN1). The value from the AD converter is shown on Port 0 (LED´s). With the value a subroutine calculates the impressed voltage on Pin 37 (AN1) and sends it to the terminal.
  • Adr-Match:
    This project demonstrates the address match function. LED-D1 of Flash-Can-100P-340 is set on, when address match ISR is executed. LED-D2 is set on, after RETI. Note, that the code is located at 0xFE0000, because address match is defined by absolute address via MATCH_ADDRESS define. Please also note, that security feature is disabled.
  • BOOTLOADER:
    This project contains a boot strap loader. It can be used to create application specific bootloaders. This example use the UART0 interface to download the software to the internal Flash memory without changing the mode-pins.
  • CAN0:
    This example uses the CAN0 and UART0 interface. The UART0 is initialised to 9600Baud @ 4MHz-crystal (internal 24MHz). Each received character will be echoed. Each received character will be send to CAN0 with ID #3 Each data that will be received by CAN0 will be send to UART0
  • CAN1:
    This example uses the CAN1 and UART0 interface. The UART0 is initialised to 9600Baud @ 4MHz-crystal (internal 24MHz).
    Note: This example is only valid for dual-CAN devices of the MB90340series, e.g.: MB90F342, MB90F344
    • Each received character will be echoed.
    • Each received character will be send to CAN1 with ID #3
    • Each data that will be received by CAN1 will be send to UART0
  • CAN_Uart:
    The CAN_UART example show functionality of the CAN-controller (Can0). The program is controlled by a PC-terminal-program via UART1 (9600Baud)
  • CaptureCompare1:
    Input Capture and Output Compare sample with independent calculating for Output Compare 0 and Output Compare 1. Timbase is set to 5ms/DIV. Every rising flag of the Input Capture port 0 is setting the timer for the 2 Output Compare register. The Input Capture signal is generated by a Reload Timer. Connect pin 77 ( reload timer ) with pin 1 ( Interrupt 0 ).
  • CaptureCompare2:
    Input Capture and Output Compare sample. Output Compare 1 depends on Output Compare 0. Timbase is set to 5ms/DIV Every rising flag of the Input Capture port 0 is setting the timer for the 2 Output Compare register. The Input Capture signal is generated by a Reload Timer. Connect pin 77 ( reload timer ) with pin 1 ( Interrupt 0 ).
  • ExtINT:
    The extIRQ-demo is running on startkit 'Flash-CAN-100P-340'. The project simply shifts a '1' up and down on port0, controlled by INT0 and INT1. LEDs are connected to port0 on startkit 'Flash-CAN-100P-340' . Interrupts are used.
  • FlashCan100P340:
    Demo-software of the Evaluation-Board for the MB90340series: Flash-Can-100P-340 running LED light on User-LEDs (P00-P07)
    • initialisation of UART0 (UART"A") and send out welcome-string (9600Baud)
    • initialisation of UART2 (UART"B") and send out welcome-string (9600Baud)
    • initialisation of optional LCD at P00-P07 (same as LED-Port !)
    • Each character received via UART0 (UART"A") will be echoed
    • Each character received via UART2 (UART"B") will be echoed
    • Key-buttons INT0, INT1, TIN1, IN0 and ADTG will be confirmed by UART-message
    • Received UART"B"-data will be send to CAN0 (CAN"A") to ID #3
    • All received CAN0 (CAN"A")-data will be send to UART "B"
  • I2C:
    The I2C-Interface0 of the MB90340(C)-Series is used to write and read data from an external EEPROM 24C16. In the first part three bytes (65,66,67 = 'A','B','C') are written to memory address 0..2 Next step is to read out EEPROM starting at address 0. The Data are stored in an array result, that can be observed by the emulator. Finally you can communicate with UART0: Datatransferrate is 9600Baud@16MHz. By pressing "w" up to 16 characters can be stored to the EPROM. With "carriage return" the input can be finished. By pressing "r" all 16 stored bytes will be read out. No interrupts are used.
  • IOPort:
    IOPort-project simply counts an internal variable and outputs the counter value to port0. PPG16: All PPG-modules are used as 16Bit-PPGs: PPG01, PPG23, PPG45, PPG67, PPG89, PPGAB, PPGCD and PPGEF. PPG23 .. PPGEF have fixed PWM-output with different high-/low-durations, that can be measured on their outputs by an oscilloscope. PPG01 is used to produce a triangel-ramp. If the output (pin 36) is connected to an LED (e.g. pin 77) this ramp can be seen as a dimming of the LED. No interrupts are used.
  • PPG8+8:
    PPG-modules PPG01 and PPG23 are used in 8bit prescaler + 8bit PPG 1ch-mode. The output signals can be measured on their output pins by an oscilloscope. PPG0- (PPG2-) signal is the 8bit prescaler-signal, whereas PPG1- (PPG3-) signal is the respective signal of the 8bit PPG. Its high- / low-duration is x times longer than the prescaler signal. In this example, factor x is 5 for ch1 and 10 for ch3, which can be easily controlled by oscilloscope. No interrupts are used.
  • PPG8:
    All PPG-modules are used as 8Bit-PPGs: PPG0, PPG1, PPG2, PPG3, PPG4, PPG5, PPG6, PPG7, PPG8, PPG9, PPGA, PPGB, PPGC, PPGD, PPGE and PPGF. PPG1 .. PPGF have fixed PWM-outputs with different high-/low-durations at different clock speeds that can be measured on their output pins by oscilloscope. PPG0 is used to produce a triangel-ramp. If the output (pin 36) is connected to an LED (e.g. pin 77) this ramp can be seen as a dimming of the LED. No interrupts are used.
  • ReloadTimer:
    This project uses interrupts of reload-timers 0-3 to toggle LEDs.
  • SPI_NM93CS46:
    This example shows how to communicate with an NM93CS46-EEPROM via SPI and UART. The program code writes 64 Data-Words to the EEPROM and reads them back. Then the reception data is compared with the source data. If an error occurred all LEDs are blinking on the FLASH-CAN-100P-340 board.
  • Stop:
    The Stop project is using external interrupts channel 0 and 1. Rising edge detection. Via external interrupt 1 the mcu is set to stop mode. The value 0x0F is output to port0. Via external Interrupt 0 the mcu can be wakeup from stop mode. Value 0xAA at port 0. Within the ISR the external Interrupts are enabled. (ISR of external int. 1 enables external interrupt 0 and vice versa.)
  • Template:
    This is a project template for the MB90340 Series. It includes some basic settings for e.g. Linker, C-Compiler which must be checked and modified in detail, corresponding to the user application.
  • UART0_async:
    It is a test application to send an welcome string via UART0 and echoes all received characters. Baud rate 9600 @ 24MHz, no parity, 1 stop bit and a data length of 8 bit. No interrupts are used.
  • UART1_async:
    It is a test application to send an welcome string via UART1 and echoes all received characters. Baud rate 9600 @ 24MHz, no parity, 1 stop bit and a data length of 8 bit. No interrupts are used.
  • UART2_async:
    It is a test application to send an welcome string via UART2 and echoes all received characters. Baud rate 9600 @ 24MHz, no parity, 1 stop bit and a data length of 8 bit. No interrupts are used.
  • UART3_async:
    It is a test application to send an welcome string via UART3 and echoes all received characters. Baud rate 9600 @ 24MHz, no parity, 1 stop bit and a data length of 8 bit. No interrupts are used.
  • History of the MB90340:
Date Revision Description
11.09.06 V01R13 Updated sample package released
07.06.05 V01R12 sample package released
07.06.05 1 I2C example added
25.05.05 V01R11 sample package released
25.05.05 1 Address Match example added
19.01.05 V01R10 sample package released
19.01.05 - Example STOP added
18.01.05 - Example uDMA added
05.01.05 - Example ADC-RLT1 added
16.11.04 V01R09 sample package released
21.10.04 1 ADC with EIIOS sample added
09.08.04 V01R08 sample package released
23.06.04 - Example CANUart added
14.06.04 1 SPI with MAX 1286 ADC
06.05.04 V01R07 sample package released
06.05.04 1 SPI_NM93CS46 sample project added
16.04.04 V01R06 sample package released
15.04.04 - Template: start-up updated
13.04.04 - Example Bootloader added
01.04.04 1.7 new Header-File, Template updated
26.03.04 - LIN examples removed, new LIN examples in 90xxx samples
23.10.03 V01R05 sample package released
23.10.03 - CaptureCompare2 example added
23.10.03 - CaptureCompare1 example added
23.10.03 - ADUART example added
23.10.03 - ADConv example added
24.09.03 - PPG8 example added
24.09.03 - PPG8+8 example added
24.09.03 - PPG16 example added
18.09.03 - new Header-File, Template updated
16.09.03 V01R04 sample package released
16.09.03 1.4 new Header-File, Template updated
09.09.03 V01R03 sample package released
08.09.03 1.3 new Header-File, Template updated
05.09.03 V01R02 sample package released
02.09.03 1.2 new Header-File, Template updated
18.08.03 - Header-File updated (Security Feature support)
12.05.03 1.01 sample package released
28.04.03 - Example ExtINT added
12.02.03 1 sample package release
11.02.03 - Example UART3_async added
11.02.03 - Example UART2_async added
11.02.03 - Example UART1_async added
11.02.03 - Example UART0_async added
11.02.03 - Example ReloadTimer added
11.02.03 - Example LIN_slave added
11.02.03 - Example LIN_master added
11.02.03 - Example IOPort added
11.02.03 - Example FlashCan100P340 added
11.02.03 - Example CAN1 added
11.02.03 - Example CAN0 added
11.02.03 - new Header-File, new Template project

DOWNLOAD

Note: Netscape Navigator 4.xx does not allow direct execution of ".exe" files. Saving them to a temporary folder and executing them there is recommended.

EXESelf-extracting Sample Files for MB90340 Series V01R13 (1530 KB, 11. September 2006)

ZIP90340_wdt-v10.zip (72 KB)