Page 1
ADC Module Using Firmware Integration Technology Dec 01, 2016 Introduction This module provides support for all features of the 12-bit A/D Converter on the RX110, RX111, RX113, RX130, RX210, RX230, RX231, RX631, RX63N, RX64M, RX65N and RX71M. Target Device The following is a list of devices that are currently supported by this API: RX110, RX111, RX113, RX130 Groups •...
RX Family ADC Module Using Firmware Integration Technology 1. Overview This A/D Converter (ADC) driver supports the S12ADa peripheral on the RX63x, the S12ADb peripheral on the RX11x/RX210, the S12ADC peripheral on the RX64M/RX71M, the S12ADE peripheral on the RX130/RX230/RX231 and the S12ADFa peripheral on the RX65x.
RX Family ADC Module Using Firmware Integration Technology 2. API Information This Driver API follows the Renesas API naming standards. Hardware Requirements This driver requires your MCU support the following features: S12ADa, S12ADb, S12ADC, S12ADE or S12ADFa peripheral • Hardware Resource Requirements This section details the hardware peripherals that this driver requires.
ROM (code and constants) and RAM (global data) sizes are determined by the build-time configuration options set in the module configuration header file. ROM and RAM code sizes With Parameter Checking Without Parameter Checking ROM: 1354 bytes ROM: 983 bytes RX110 RAM: 12 bytes RAM: 12 bytes ROM: 1234 bytes ROM: 950 bytes RX111 RAM: 124 bytes...
This section details the data structures that are used with the driver’s API functions. To provide strong type checking and reduce errors, many parameters used in API functions require arguments to be passed using the provided type definitions. Allowable values are defined in the public interface files: r_s12ad_rx_if.h src/targets/rx110/r_s12ad_rx110_if.h src/targets/rx111/r_s12ad_rx111_if.h src/targets/rx113/r_s12ad_rx113_if.h src/targets/rx130/r_s12ad_rx130_if.h src/targets/rx210/r_s12ad_rx210_if.h...
Page 7
R_ADC_Close(uint8_t const unit); uint32_t R_ADC_GetVersion(void); 2.10.2 RX110 Interface Types ( r_s12ad_rx110_if.h ) /* ADC_OPEN() ARGUMENT DEFINITIONS */ typedef enum e_adc_mode ADC_MODE_SS_TEMPERATURE, // single scan temperature sensor ADC_MODE_SS_INT_REF_VOLT, // single scan internal ref voltage sensor ADC_MODE_SS_ONE_CH, // single scan one channel...
Page 8
RX Family ADC Module Using Firmware Integration Technology ADC_TRIG_SYNC_TRG0EN = 4, // MTU0 TRGE ADC_TRIG_SYNC_TRG0FN = 5, // MTU0 TRGF ADC_TRIG_SOFTWARE = 16 // software trigger; not for Group modes // nor double trigger modes // This is not set to TRSA or TRSB } adc_trig_t;...
Page 9
RX Family ADC Module Using Firmware Integration Technology // Commands to poll for scan completion ADC_CMD_CHECK_SCAN_DONE, // for Normal or GroupA scan ADC_CMD_CHECK_SCAN_DONE_GROUPA, ADC_CMD_CHECK_SCAN_DONE_GROUPB, // Advanced control commands ADC_CMD_DISABLE_TRIG, // ADCSR.TRGE=0 for sync/async trigs ADC_CMD_DISABLE_INT, // interrupt disable; ADCSR.ADIE=0 ADC_CMD_ENABLE_INT, // interrupt enable;...
Page 10
RX Family ADC Module Using Firmware Integration Technology uint32_t chan_mask; // channels/bits 0-15 uint32_t chan_mask_groupb; // valid for group modes uint32_t add_mask; // valid if add enabled in Open() adc_ch_cfg_t; /* ADC_READ() ARGUMENT DEFINITIONS */ typedef enum e_adc_reg ADC_REG_CH0 = 0, ADC_REG_CH1 = 1, ADC_REG_CH2 = 2, ADC_REG_CH3 = 3,...
Page 12
RX Family ADC Module Using Firmware Integration Technology // Commands to enable channels or sensors ADC_CMD_ENABLE_CHANS, // enables chans and A & B INT if pri != 0 ADC_CMD_ENABLE_TEMP_SENSOR, // enables sensor and INT if priority != 0 ADC_CMD_ENABLE_VOLT_SENSOR, // enables sensor and INT if priority != 0 // Commands to enable hardware triggers or cause software trigger ADC_CMD_ENABLE_TRIG, // ADCSR.TRGE=1 for sync/async triggers...
Page 13
RX Family ADC Module Using Firmware Integration Technology #define ADC_MASK_CH13 (1<<13) #define ADC_MASK_CH14 (1<<14) #define ADC_MASK_CH15 (1<<15) #define ADC_MASK_GROUPB_OFF #define ADC_MASK_ADD_OFF typedef struct st_adc_ch_cfg // bit 0 is ch0; bit 15 is ch15 uint32_t chan_mask; // channels/bits 0-15 uint32_t chan_mask_groupb; // valid for group modes uint32_t add_mask;...
Page 14
RX Family ADC Module Using Firmware Integration Technology ADC_MODE_SS_MULTI_CH_GROUPED_DBLTRIG_A, ADC_MODE_MAX // This definition DO NOT USE for R_ADC_Open() argument adc_mode_t; typedef enum e_adc_trig // trigger sources (set to TRSA bit or TRSB bit) ADC_TRIG_ASYNC_ADTRG = 0, // ext asynchronous trigger; not for // Group modes nor double trigger modes ADC_TRIG_SYNC_TRG0AN = 1,...
Page 15
RX Family ADC Module Using Firmware Integration Technology adc_cfg_t; /* ADC_CONTROL() ARGUMENT DEFINITIONS */ typedef enum e_adc_cmd // Commands for special hardware configurations ADC_CMD_USE_INT_VOLT_AS_HVREF, ADC_CMD_SET_SAMPLE_STATE_CNT, // Commands to enable channels or sensors ADC_CMD_ENABLE_CHANS, // enables chans and A & B INT if pri != 0 ADC_CMD_ENABLE_TEMP_SENSOR, // enables sensor and INT if priority != 0 ADC_CMD_ENABLE_VOLT_SENSOR,...
Page 16
RX Family ADC Module Using Firmware Integration Technology /* for ADC_CMD_ENABLE_CHANS */ // Bitwise OR these masks together for desired channels #define ADC_MASK_CH0 (1<<0) #define ADC_MASK_CH1 (1<<1) #define ADC_MASK_CH2 (1<<2) #define ADC_MASK_CH3 (1<<3) #define ADC_MASK_CH4 (1<<4) #define ADC_MASK_CH5 (1<<5) #define ADC_MASK_CH6 (1<<6) #define...
Page 17
RX Family ADC Module Using Firmware Integration Technology typedef struct st_adc_data uint16_t chan[ADC_REG_ARRAY_MAX]; // chnls/indexes used depends upon MCU uint16_t temp; uint16_t volt; uint16_t dbltrig; // Not used on RX63x adc_data_t; 2.10.5 RX130 Interface Types (r_s12ad_rx130_if.h) /***** ADC_OPEN() ARGUMENT DEFINITIONS *****/ typedef enum e_adc_mode ADC_MODE_SS_TEMPERATURE,...
Page 19
RX Family ADC Module Using Firmware Integration Technology ADC_CMD_CHECK_SCAN_DONE, // For Normal or GroupA scan ADC_CMD_CHECK_SCAN_DONE_GROUPA, ADC_CMD_CHECK_SCAN_DONE_GROUPB, ADC_CMD_CHECK_CONDITION_MET, // comparator condition // Advanced control commands // ADCSR.TRGE=0 for sync/async trigs ADC_CMD_DISABLE_TRIG, // interrupt disable; ADCSR.ADIE=0 ADC_CMD_DISABLE_INT, // interrupt enable; ADCSR.ADIE=1 ADC_CMD_ENABLE_INT, ADC_CMD_DISABLE_INT_GROUPB, // interrupt disable;...
Page 20
RX Family ADC Module Using Firmware Integration Technology /* for ADC_CMD_CONFIGURE_SCAN */ // Bitwise OR these masks together for desired channels and sensors // Used for all commands containing a "mask" or "flags" field #define ADC_MASK_CH0 (1<<0) #define ADC_MASK_CH1 (1<<1) #define ADC_MASK_CH2 (1<<2)
Page 21
RX Family ADC Module Using Firmware Integration Technology uint32_t add_mask; // valid if add enabled in Open() adc_diag_t diag_method; // self-diagnosis virtual channel adc_elc_t signal_elc; } adc_ch_cfg_t; /* for ADC_CMD_EN_COMPARATOR_LEVEL and ADC_CMD_EN_COMPARATOR_WINDOW */ typedef struct st_adc_cmpwin_cfg // bit-OR ADC_MASK_xxx to indicate channels/sensors uint32_t compare_mask;...
Page 22
RX Family ADC Module Using Firmware Integration Technology 2.10.6 RX210 Interface Types (r_s12ad_rx210_if.h) /* ADC_OPEN() ARGUMENT DEFINITIONS */ typedef enum e_adc_mode ADC_MODE_SS_TEMPERATURE, // single scan temperature sensor ADC_MODE_SS_INT_REF_VOLT, // single scan internal ref voltage sensor ADC_MODE_SS_ONE_CH, // single scan one channel ADC_MODE_SS_MULTI_CH, // 1 trigger source, scan multiple channels ADC_MODE_CONT_ONE_CH,...
Page 23
RX Family ADC Module Using Firmware Integration Technology typedef struct st_adc_cfg adc_add_t add_cnt; adc_align_t alignment; // ignored if addition used adc_clear_t clearing; adc_trig_t trigger; // default and Group A trigger source adc_trig_t trigger_groupb; // valid only for group modes uint8_t priority;...
Page 25
RX Family ADC Module Using Firmware Integration Technology typedef struct st_adc_ch_cfg // bit 0 is ch0; bit 15 is ch15 uint32_t chan_mask; // channels/bits 0-15 uint32_t chan_mask_groupb; // valid for group modes uint32_t add_mask; // valid if add enabled in Open() adc_diag_t diag_method;...
Page 26
RX Family ADC Module Using Firmware Integration Technology ADC_MODE_SS_ONE_CH_DBLTRIG, // on even triggers save to ADDBLDR & // interrupt ADC_MODE_SS_MULTI_CH_GROUPED, // 2 trigger sources, scan multiple channels ADC_MODE_SS_MULTI_CH_GROUPED_DBLTRIG_A, ADC_MODE_MAX // This definition DO NOT USE for R_ADC_Open() argument } adc_mode_t; typedef enum e_adc_align ADC_ALIGN_RIGHT = 0x0000,...
Page 27
RX Family ADC Module Using Firmware Integration Technology typedef struct st_adc_cfg adc_speed_t conv_speed; // ADCSR.ADHSC, rx230 has two // conversion speeds adc_align_t alignment; // ADCER.ADRFMT, Left or Right // alignment,ignored if addition used adc_add_t add_cnt; // ADADC.ADC, Addition/average // count select. adc_clear_t clearing;...
Page 30
RX Family ADC Module Using Firmware Integration Technology uint32_t inside_window_mask; // condition met when within range // default=0 met when outside range uint16_t level_lo; // Low-value of window uint16_t level_hi; // High-value of window bool windowa_enable; // comparison window A enable } adc_cmpwin_t;...
Page 31
RX Family ADC Module Using Firmware Integration Technology /* ADC_READALL() ARGUMENT DEFINITIONS */ typedef struct st_adc_data uint16_t chan[24]; uint16_t temp; uint16_t volt; uint16_t dbltrig; uint16_t self_diag; } adc_data_t; 2.10.8 RX231 Interface Types (r_s12ad_rx231_if.h) /* ADC_OPEN() ARGUMENT DEFINITIONS */ typedef enum e_adc_mode ADC_MODE_SS_TEMPERATURE, // single scan temperature sensor...
Page 35
RX Family ADC Module Using Firmware Integration Technology adc_elc_t signal_elc; } adc_ch_cfg_t; /* for ADC_CMD_EN_COMPARATOR_LEVEL and ADC_CMD_EN_COMPARATOR_WINDOW */ typedef struct st_adc_cmpwin_cfg // bit-OR ADC_MASK_xxx to indicate channels/sensors uint32_t compare_mask; // channels/sensors to compare uint32_t inside_window_mask; // condition met when within range // default=0 met when outside range uint16_t level_lo;...
Page 36
RX Family ADC Module Using Firmware Integration Technology } adc_data_t; 2.10.9 RX63x Interface Types (r_s12ad_rx63x_if.h) /* ADC_OPEN() ARGUMENT DEFINITIONS */ typedef enum e_adc_mode ADC_MODE_SS_TEMPERATURE, // single scan temperature sensor ADC_MODE_SS_INT_REF_VOLT, // single scan internal ref voltage sensor ADC_MODE_SS_ONE_CH, // single scan one channel ADC_MODE_SS_MULTI_CH, // 1 trigger source, scan multiple channels ADC_MODE_CONT_ONE_CH,...
Page 37
RX Family ADC Module Using Firmware Integration Technology typedef struct st_adc_cfg adc_add_t add_cnt; adc_align_t alignment; // ignored if addition used adc_clear_t clearing; adc_speed_t conv_speed; adc_trig_t trigger; uint8_t priority; // for S12ADIO int; 1=lo 15=hi 0=off/polled adc_cfg_t; /* ADC_CONTROL() ARGUMENT DEFINITIONS */ typedef enum e_adc_cmd // Commands for special hardware configurations...
Page 41
RX Family ADC Module Using Firmware Integration Technology ADC_CMD_EN_COMPARATOR_LEVEL, // enable comparator for threshold compare ADC_CMD_EN_COMPARATOR_WINDOW, // enable comparator for range compare // Commands to enable hardware triggers or cause software trigger ADC_CMD_ENABLE_TRIG, // ADCSR.TRGE=1 for sync/async triggers ADC_CMD_SCAN_NOW, // software trigger start scan // Commands to poll for scan completion and comparator results ADC_CMD_CHECK_SCAN_DONE, // for Normal or GroupA scan...
Page 42
RX Family ADC Module Using Firmware Integration Technology typedef struct st_adc_time adc_sst_reg_t reg_id; uint8_t num_states; // ch8-20 use the same value adc_sst_t; /* for ADC_CMD_CONFIGURE_SCAN */ // Bitwise OR these masks together for desired channels and sensors // Used for all commands containing a "mask" or "flags" field #define ADC_MASK_CH0 (1<<0)
Page 43
RX Family ADC Module Using Firmware Integration Technology #define ADC_SST_SH_CNT_DEFAULT (24) // default sample&hold states typedef struct st_adc_ch_cfg // bit 0 is ch0; bit 15 is ch15 uint32_t scan_mask; // channels/bits 0-15 uint32_t scan_mask_groupb; // valid for group modes adc_grpa_t priority_groupa;...
Page 45
RX Family ADC Module Using Firmware Integration Technology ADC_ALIGN_RIGHT = 0x0000, ADC_ALIGN_LEFT 0x8000 adc_align_t; typedef enum e_adc_add ADC_ADD_OFF = 0, // addition is turned off for chans/sensors ADC_ADD_TWO_SAMPLES = 1, ADC_ADD_THREE_SAMPLES = 2, ADC_ADD_FOUR_SAMPLES = 3, ADC_ADD_SIXTEEN_SAMPLES = 5, ADC_ADD_AVG_2_SAMPLES = 0x81, // average 2 samples ADC_ADD_AVG_4_SAMPLES = 0x83, // average 4 samples...
Page 46
RX Family ADC Module Using Firmware Integration Technology adc_res_t resolution; // 8, 10, or 12-bit adc_align_t alignment; // ignored if addition used adc_add_t add_cnt; // add or average samples adc_clear_t clearing; // clear after read adc_trig_t trigger; // default and Group A trigger source adc_trig_t trigger_groupb;...
Page 47
RX Family ADC Module Using Firmware Integration Technology #define ADC_DDA_STATE_CNT_MAX (15) typedef struct st_adc_dda adc_charge_t method; uint8_t num_states; // 2-15 adc_dda_t; /* for ADC_CMD_SET_SAMPLE_STATE_CNT */ typedef enum e_adc_sst_reg // sample state registers ADC_SST_CH0 = 0, ADC_SST_CH1, ADC_SST_CH2, ADC_SST_CH3, ADC_SST_CH4, ADC_SST_CH5, ADC_SST_CH6, ADC_SST_CH7, // end unit 0...
RX Family ADC Module Using Firmware Integration Technology 2.11 Return Values These are the different error codes API functions can return. The enum is found in r_s12ad_rx_if.h along with the API function declarations. typedef enum e_adc_err // ADC API error codes ADC_SUCCESS = 0, ADC_ERR_AD_LOCKED, // Open() call is in progress elsewhere...
RX Family ADC Module Using Firmware Integration Technology 3. API Functions Summary The following functions are included in this design: Function Description R_ADC_Open() Applies power to the A/D peripheral (and TEMPS peripheral on RX210 and RX63x), sets the operational mode, trigger sources, interrupt priority, and configurations common to all channels and sensors.
RX Family ADC Module Using Firmware Integration Technology R_ADC_Open() This function applies power to the A/D peripheral, sets the operational mode, trigger sources, interrupt priority, and configurations common to all channels and sensors. If interrupt priority is non-zero, the function takes a callback function pointer for notifying the user at interrupt level whenever a scan has completed or comparator condition met.
Page 54
No. For MCUs with a single unit this function should only be called once before a call to Close(). For the RX64M/RX71M/RX65x this function may be called once for each unit. Example (RX110, RX111, RX113) adc_cfg_t config; /* Clear all fields of the adc_cfg_t structure */ memset(&config, 0, sizeof(config));...
Page 55
A/D conversion result is not cleared. After the R_ADC_Open function is executed, wait at least 10 ms before executing A/D conversion. Special Notes (RX110/RX111/RX113/RX210/RX130/RX230/RX231/RX65x/RX64M/RX71M): After the R_ADC_Open function is executed, wait at least 1 µs before executing A/D conversion. R01AN1666EJ0220 Rev. 2.20...
RX Family ADC Module Using Firmware Integration Technology R_ADC_Control() This function provides commands for enabling channels and sensors and for runtime operations. These include enabling/disabling trigger sources and interrupts, initiating a software trigger, and checking for scan completion. Format adc_err_t R_ADC_Control(uint8_t unit, adc_cmd_t const cmd, void * const...
Page 57
RX Family ADC Module Using Firmware Integration Technology Reentrant Yes, but in general should not be used as such. A valid case for reentrancy would be in group mode with one task performing the ADC_CMD_CHECK_SCAN_DONE_GROUPA and another performing the ADC_CMD_CHECK_SCAN_DONE_GROUPB. Other commands such as enabling/disabling triggers or interrupts would affect operations being performed by another task and reentrancy of this kind should be avoided.
Page 58
RX Family ADC Module Using Firmware Integration Technology Example 2: Temperature Sensor Polling and Set Sample State Count Unit 1 (RX64M, RX71M, RX65x) uint16_t data; adc_cfg_t config; adc_sst_t sst; // sample state adc_ch_cfg_t ch_cfg; adc_err_t adc_err; /* OPEN ADC */ /* Clear all fields of the adc_cfg_t structure */ memset(&config, 0, sizeof(config));...
Page 59
RX Family ADC Module Using Firmware Integration Technology Example 3: Grouped Channels with Interrupt Triggers, Double Trigger on Group A, and Averaging (RX64M, RX71M, RX65x) adc_cfg_t config; adc_ch_cfg_t ch_cfg; /* INITIALIZE MTU HERE (USED FOR TRIGGER SOURCES) */ /* OPEN ADC */ /* Clear all fields of each structure */ memset(&config, 0, sizeof(config));...
Page 60
RX Family ADC Module Using Firmware Integration Technology args = (adc_cb_args_t *)p_args; /* READ RESULTS */ if (args->event == ADC_EVT_SCAN_COMPLETE) /* From S12ADIO interrupt, Group A scan complete, read registers */ R_ADC_Read(1, ADC_REG_CH8, &data8); R_ADC_Read(1, ADC_REG_DBLTRIG, &dbltrg); else if (args->event == ADC_EVT_SCAN_COMPLETE_GROUPB) /* From GBADI interrupt, Group B scan complete, read registers */ R_ADC_Read(1, ADC_REG_CH2, &data2);...
Page 61
RX Family ADC Module Using Firmware Integration Technology /* Have channel 1 and 2 as Group A, have 3 and 4 as Group B, have 5 and 6 as Group C Perform addition/average on all channels except 9 ch_cfg.scan_mask = ADC_MASK_CH1 | ADC_MASK_CH2; ch_cfg.scan_mask_groupb = ADC_MASK_CH3 | ADC_MASK_CH4;...
Page 62
RX Family ADC Module Using Firmware Integration Technology Example 5: Multiple Channels with Interrupt Trigger and Comparator Checking (RX64M, RX71M) adc_cfg_t config; adc_ch_cfg_t ch_cfg; adc_cmpwin_t cmpwin; /* INITIALIZE MTU HERE (USED FOR TRIGGER SOURCES) */ /* OPEN UNIT 0 */ /* Clear all fields of the adc_cfg_t structure */ memset(&config, 0, sizeof(config));...
Page 63
RX Family ADC Module Using Firmware Integration Technology adc_cb_args_t *args; uint16_t data3,data4,data5; args = (adc_cb_args_t *)p_args; /* READ RESULTS */ if (args->event == ADC_EVT_SCAN_COMPLETE) R_ADC_Read(0, ADC_REG_CH3, &data3); R_ADC_Read(0, ADC_REG_CH4, &data4); R_ADC_Read(0, ADC_REG_CH5, &data5); if (args->event == ADC_EVT_CONDITION_MET) if (args->compare_flags & ADC_MASK_CH3) // processing when channel 3 voltage is too low else // processing when channel 4 voltage is too low...
Page 64
RX Family ADC Module Using Firmware Integration Technology /* HAVE COMPARATOR CHECK ON CHANNELS 3-4 FOR DROPPING BELOW 1.65V */ cmpwin.compare_mask = ADC_MASK_CH3 | ADC_MASK_CH4; cmpwin.compare_maskb = ADC_COMP_WINB_CH5; cmpwin.above_level_mask = 0; // Condition met when below level cmpwin.above_level_maskb = ADC_COMP_WINB_COND_BELOW; cmpwin.level_lo = 0x7FF;...
Page 65
RX Family ADC Module Using Firmware Integration Technology Special Notes (RX Family Common): When the A/D conversion start (ADST) bit is 1, settings such as mode must not be changed using this function. However, the conversion status or the comparison result can be obtained. When switching channels used for A/D conversion or settings, call the R_ADC_Close() function once and then call the R_ADC_Open() function again to start.
Page 66
Only AN008 to AN020 can be used for setting the number of sampling states. AN000 to AN007 are fixed to 20 states regardless of the setting. Special Notes (RX110/RX111/RX113): µ For temperature sensor and internal reference voltage, the number of sampling states must be set to 5 s or greater.
/* Read channel 0 on unit 0 */ R_ADC_Read(0, ADC_CH0_REG, &data); // conversion value placed in “data” Special Notes (RX110/RX111/RX113): For temperature sensor output and internal reference voltage, discard the first A/D conversion result after the open, and use the second and the subsequent A/D conversion results.
RX Family ADC Module Using Firmware Integration Technology R_ADC_ReadAll() This function reads conversion results from all potential sources, enabled or not. Format adc_err_t R_ADC_ReadAll(adc_data_t * const p_data); Parameters p_data Pointer to structure to load register values into. See type adc_data_t in section 2.10 for the MCU being used An example structure for the register values is as follows: typedef struct st_adc_data uint16_t...
RX Family ADC Module Using Firmware Integration Technology R_ADC_Close() This function ends any scan in progress, disables interrupts, and removes power to the A/D peripheral. Format adc_err_t R_ADC_Close(uint8_t unit); Parameters unit 0 or 1. For MCUs with only one unit 0 should be passed (only the RX64M/RX71M/RX65x have 2 units). Return Values ADC_ERR_INVALID_ARG: Unit not 0 or 1...
RX Family ADC Module Using Firmware Integration Technology R_ADC_GetVersion() This function returns the driver version number at runtime. Format uint32_t R_ADC_GetVersion(void) Parameters None Return Values Version number. Properties Prototyped in file “r_s12ad_rx_if.h” Description Returns the version of this module. The version number is encoded such that the top 2 bytes are the major version number and the bottom 2 bytes are the minor version number.
RX Family ADC Module Using Firmware Integration Technology 4. Pin Setting Regarding the pin setting used for this module, it is strictly recommended to perform the pin setting after calling the function R_ADC_Open. R01AN1666EJ0220 Rev. 2.20 Page 71 of 74 Dec 01, 2016...
RX Family ADC Module Using Firmware Integration Technology 5. Demo Projects Demo projects are complete stand-alone programs. They include function main() that utilizes the module and its dependent modules (e.g. r_bsp). The standard naming convention for the demo project is <module>_demo_<board> where <module>...
RX Family ADC Module Using Firmware Integration Technology Adding a Demo to a Workspace Demo projects are found in the FITDemos subdirectory of the e studio installation directory. To add a demo project to a workspace, select File>Import>General>Existing Projects into Workspace, then click “Next”. From the Import Projects dialog, choose the “Select archive file”...
Page 74
This module reflects the content of the following technical updates. TN-RX*-A124A/E • • TN-RX*-A117A/E Website and Support Renesas Electronics Website http://www.renesas.com/ Inquiries http://www.renesas.com/inquiry All trademarks and registered trademarks are the property of their respective owners. R01AN1666EJ0220 Rev. 2.20 Page 74 of 74...
Page 75
- Special Notes (RX64M/RX71M/RX65x): Added a special note regarding operation under Group A Priority Control and modified the table. - Special Notes (RX63x) and Special Notes (RX110/RX111/ RX113): Added. 3.4 R_ADC_Read(): Added Special Notes (RX110/RX111/ RX113). 4. Pin Setting: Added.
Page 76
Description Rev. Date Page Summary 2.20 Dec.01.2016 Program Fixed the following issue: Target Device: RX64M/RX71M/RX230/RX231 Description: There is an error in checking the range of the arguments. Thus, when the trigger source de-selection state is set as the trigger for group B, the R_ADC_Open function returns an error.
Page 77
Description Rev. Date Page Summary 2.20 Dec.01.2016 Program Fixed the following issue: Target Device: RX230/RX231 Description: The numbers of arguments (enum value) for an index of the register table do not match and the indexed value becomes out of range. Then the R_ADC_Read function cannot obtain the result of self-diagnosis.
Page 82
Use Rev. 2.20 or later version of the S12AD FIT module. Added the temperature sensor (temp) and internal reference voltage (volt) to the adc_data_t structure in the RX63x, RX110, RX111, RX113, and RX210 Groups to unify the behavior of the R_ADC_ReadAll function over all MCU groups.
Page 83
Description Rev. Date Page Summary 2.20 Dec.01.2016 Program Fixed the following issue: Target Device: RX130/RX230/RX231 Description: No processing is provided to set the compare window operation enable bit to "disabled". Thus once the compare function is enabled, only the way to disable it is reopening. However, please note that reopening does not work for RX230 and RX231.
Page 84
Description Rev. Date Page Summary 2.20 Dec.01.2016 Program Fixed the following issue: Target Device: RX130/RX230/RX231/RX64M/RX71M Description: An unspecified callback function (NULL) is executed and improper interrupt occurs. Condition: After the R_ADC_Open function is executed with interrupts disabled, the interrupt priority level of the compare interrupt is set to “1”...
Page 85
Description Rev. Date Page Summary 2.20 Dec.01.2016 Program Fixed the following issue: Target Device: RX130/RX230/RX231 Description: An unnecessary error determination is performed. Because of this, when setting the disconnection detection assist function after self-diagnosis is enabled, the R_ADC_Control function returns an error. Condition: Discharge or precharge is selected for the disconnection detection assist function after self-diagnosis is enabled.
Page 86
In RX63x and RX210, the TEMPS register is now modified only when the temperature sensor module is enabled. Added the definition "ADC_CONVERT_SPEED_DEFAULT" for conversion speed of A/D conversion in RX110, RX111, and RX113. "ADC_CONVERT_SPEED_DEFAULT" has the same value as "ADC_CONVERT_SPEED_NORM".
Page 87
General Precautions in the Handling of Microprocessing Unit and Microcontroller Unit Products The following usage notes are applicable to all Microprocessing unit and Microcontroller unit products from Renesas. For detailed usage notes on the products covered by this document, refer to the relevant sections of the document as well as any technical updates that have been issued for the products.
Page 88
10. It is the responsibility of the buyer or distributor of Renesas Electronics products, who distributes, disposes of, or otherwise places the product with a third party, to notify such third party in advance of the contents and conditions set forth in this document, Renesas Electronics assumes no responsibility for any losses incurred by you or third parties as a result of unauthorized use of Renesas Electronics products.
Need help?
Do you have a question about the RX110 and is the answer not in the manual?
Questions and answers