Mikroelektronika d.o.o.
PAC1954 Click Board
PAC1954 Click Board
Couldn't load pickup availability
The PAC1954 Click Board™ is a compact add-on board that contains an energy monitoring solution. This board features the PAC1954, a four-channel DC power/energy monitor from Microchip Technology. It uses real-time calibration to minimize offset and gain errors with no input filters required for this device. One major feature of the PAC1954 design is a set of digital comparators that allows the user to detect over/under voltage, over/undercurrent, and overpower against user-programmed limits for each channel and generate an alert when the threshold is exceeded.
The PAC1954 Click Board™ performs power calculations and energy accumulation, enabling energy monitoring with integration periods up to one year or longer.
![Mikroelektronika d.o.o. MIKROE-4291 PAC1954 Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-pac1954-click-board-29108470874301.jpg?v=1685084149&width=1445)
![Mikroelektronika d.o.o. MIKROE-4291 PAC1954 Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-pac1954-click-board-29108470710461.jpg?v=1685036272&width=1445)
![Mikroelektronika d.o.o. MIKROE-4291 PAC1954 Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-pac1954-click-board-29108470677693.jpg?v=1685143727&width=1445)
![Mikroelektronika d.o.o. MIKROE-4291 PAC1954 Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-pac1954-click-board-29108470743229.jpg?v=1685143736&width=1445)
![Mikroelektronika d.o.o. MIKROE-4291 PAC1954 Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-pac1954-click-board-30233168281789.jpg?v=1685036276&width=1445)
![Mikroelektronika d.o.o. MIKROE-4291 PAC1954 Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-pac1954-click-board-30233167560893.jpg?v=1685036281&width=1445)
![Mikroelektronika d.o.o. MIKROE-4291 PAC1954 Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-pac1954-click-board-29108470907069.jpg?v=1685084147&width=1445)
How Does The PAC1954 Click Board™ Work?
The PAC1954 Click Board™ as its foundation uses the PAC1954, a four-channel energy monitoring solution with bus voltage monitors and current sense amplifiers that feed high-resolution ADCs from Microchip Technology. Its real-time calibration minimizes offset and gain errors. Built-in 8x averaging feature makes low noise high-resolution measurement results. There are four current sense shunt resistors connected to PAC1954's integrated current sense amplifier. Electricity is brought to shunts via screw terminals where the middle screw connector represents GND used for bus voltage monitoring. Bus voltage, sense resistor voltage, and accumulated proportional power are stored in registers for retrieval by the MCU.
One major feature of the PAC1954 design is a set of digital comparators that allows the user to detect over/under voltage, over/undercurrent, and overpower against user-programmed limits for each channel and generate an alert when the threshold is exceeded. Digital circuitry of the PAC1954 performs power calculations and energy accumulation, which enables energy monitoring with integration periods up to one year or longer. After the Start-Up sequence, the PAC1954 is in the Active state and begins sampling the inputs sequentially. Voltage and current are sampled for all active channels at 1024 samples/second by default, and power is calculated and accumulated.
The PAC1954 Click Board™ communicates with MCU using the standard I2C 2-Wire interface to read data and configure settings, supporting Fast Mode operation with a clock frequency up to 1MHz. Besides, it also allows the choice of the least significant bit of its I2C slave address by positioning the SMD jumper labelled as ADDR SEL to an appropriate position marked as 0 and 1. The Power-Down pin, labelled as EN and routed to the CS pin of the mikroBUS™ socket, optimizes power consumption and is used for power on/off purposes. All circuits, including the interface pins, are inactive in this state, and the PAC1954 is in the form of minimum power dissipation.
The SLW pin, routed to the RST pin of the mikroBUS™ socket, serves as the conversion rate control. If the SLW pin is asserted, the sample rate is eight samples per second. For sampling rates lower than 1024 samples/second, the PAC1954 is in a Sleep mode for a portion of the conversion cycle, which results in lower power dissipation. No matter the programmed sample rate, this new sample rate will affect the following conversion cycle.
The alert functionality, routed to the INT pin of the mikroBUS™ socket, has multiple purposes; to notify the system that a conversion cycle for all active channels is complete, or to notify the system that the accumulator or accumulator count has overflowed, or that an electrical parameter is outside the programmed limit. Besides the INT pin, the SLW pin can function as another alert feature by attaching a pull-up resistor to it, which is done via onboard SMD jumper labelled as SLW PULL by positioning 10k resistor to an appropriate position marked as DOWN or UP.
The PAC1954 Click Board™ can operate with both 3.3V and 5V logic voltage levels selected via the VCC SEL jumper. This way, it is allowed for both 3.3V and 5V capable MCUs to use the I2C communication lines properly. However, the Click board™ comes equipped with a library containing easy-to-use functions and an example code that can be used, as a reference, for further development.
SPECIFICATIONS
Type | Measurements |
Applications | The PAC1954 Click Board™ performs power calculations and energy accumulation, enabling energy monitoring with integration periods up to one year or longer. |
On-board modules | PAC1954 - four-channel energy monitoring solution with bus voltage monitors and current sense amplifiers that feed high-resolution ADCs from Microchip Technology |
Key Features | High-side current monitor, real-time auto-calibration of offset and gain errors for voltage and current, 1% power measurement accuracy over a wide dynamic range, alert feature, and more. |
Interface | I2C |
Compatibility | mikroBUS |
Click board size | M (42.9 x 25.4 mm) |
Input Voltage | 3.3V or 5V |
PINOUT DIAGRAM
This table shows how the pinout of the PAC1954 Click Board™ corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Notes | Pin | ![]() |
Pin | Notes | |||
---|---|---|---|---|---|---|---|
NC | 1 | AN | PWM | 16 | NC | ||
Conversion Rate Control | SLW | 2 | RST | INT | 15 | INT | Interrupt |
Chip Enable | EN | 3 | CS | RX | 14 | NC | |
NC | 4 | SCK | TX | 13 | NC | ||
NC | 5 | MISO | SCL | 12 | SCL | I2C Clock | |
NC | 6 | MOSI | SDA | 11 | SDA | I2C Data | |
Power Supply | 3.3V | 7 | 3.3V | 5V | 10 | 5V | Power Supply |
Ground | GND | 8 | GND | GND | 9 | GND | Ground |
ONBOARD SETTINGS AND INDICATORS
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | - | Power LED Indicator |
JP1 | VCC SEL | Left | Logic Level Voltage Selection 3V3/5V: Left position 3V3, Right position 5V |
JP2 | ADDR SEL | Left | I2C Address Selection 0/1: Left position 0, Right position 1 |
JP3 | SLW SEL | Left | SLW pin ALERT Function Selection DOWN/UP: Left position DOWN, Right position UP |
PAC1954 CLICK ELECTRICAL SPECIFICATIONS
Description | Min | Typ | Max | Unit |
---|---|---|---|---|
Supply Voltage | 3.3 | - | 5 | V |
Analog Input Voltage Range | 0 | - | 32 | V |
ADC Data Resolution | - | - | 16 | bits |
Operating Temperature Range | -40 | +25 | +125 | °C |
Software Support
We provide a library for the PAC1954 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
This library offers a full control of the PAC1954 Click Board™. The main functions are: modification of any configuration register; status, configuration and data registers reading; executing an all necessary conversions and calculations to get entire data in standard units. For more details, please, check the full documentation.
Key Functions
void pac1954_single_write( uint8_t reg_addr, uint8_t data_in );
- This function writes single data byte to the selected register.void pac1954_refresh_cmd( void );
- The readable registers for the VBUS, VSENSE, Power, accumulator outputs and accumulator count are updated by the REFRESH command and the values will be static until the next REFRESH command.float pac1954_get_calc_measurement( uint8_t meas_sel, uint8_t ch_sel, uint8_t avg_sel, uint8_t meas_mode );
- This function will call function for getting the selected measurement data and will perform all necessary calculations to get measurement value in standard unit.
Example Description
The application is composed of three sections :
- System Initialization - Performs the configuration for all necessary pins and peripherals.
- Application Initialization - Performs the driver initialization and executes a default configuration of the PAC1954 Click Board™.
- Application Task - (code snippet) - First calls a REFRESH command to allow all measurement and config registers to be updated. After that reads the calculated measurement results of channel 1 and sends the results to the USB UART port every 1 second.
void application_task( ) { pac1954_refresh_cmd( ); vsource = pac1954_get_calc_measurement( PAC1954_MEAS_SEL_V_SOURCE, PAC1954_CH_SEL_CH_1, PAC1954_AVG_SEL_ENABLE, PAC1954_MEAS_MODE_BIPOLAR_FSR ); isense = pac1954_get_calc_measurement( PAC1954_MEAS_SEL_I_SENSE, PAC1954_CH_SEL_CH_1, PAC1954_AVG_SEL_ENABLE, PAC1954_MEAS_MODE_BIPOLAR_FSR ); power = pac1954_get_calc_measurement( PAC1954_MEAS_SEL_P_SENSE, PAC1954_CH_SEL_CH_1, PAC1954_NULL, PAC1954_MEAS_MODE_BIPOLAR_FSR ); FloatToStr( vsource, log_txt ); Ltrim( log_txt ); float_cut( ); mikrobus_logWrite( "V(source) is ", _LOG_TEXT ); mikrobus_logWrite( log_txt, _LOG_TEXT ); mikrobus_logWrite( " V", _LOG_LINE ); FloatToStr( isense, log_txt ); Ltrim( log_txt ); float_cut( ); mikrobus_logWrite( "I(sense) is ", _LOG_TEXT ); mikrobus_logWrite( log_txt, _LOG_TEXT ); mikrobus_logWrite( " A", _LOG_LINE ); FloatToStr( power, log_txt ); Ltrim( log_txt ); float_cut( ); mikrobus_logWrite( "P(sense) is ", _LOG_TEXT ); mikrobus_logWrite( log_txt, _LOG_TEXT ); mikrobus_logWrite( " W", _LOG_LINE ); mikrobus_logWrite( "", _LOG_LINE ); Delay_ms( 1000 ); }
Additional Functions :
float_cut
- Uses the converted string with the measurement result and cut it to be rounded on two decimal places.
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- Conversions
- C_String
- I2C
- UART
Additional Notes and Information
Depending on the development board you are using, you may need USB UART Click Board™, USB UART 2 Click Board™ or RS232 Click Board™ to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
MIKROSDK
The PAC1954 Click Board™ is supported with mikroSDK - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
PAC1954 Click Board
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.