- Holographic Christmas TreePosted 7 days ago
- Segstick: Build Your Own Self-Balancing Vehicle in Just 2 Days with ArduinoPosted 3 weeks ago
- ZSWatch: An Open-Source Smartwatch Project Based on the Zephyr Operating SystemPosted 1 month ago
- What is IoT and which devices to usePosted 2 months ago
- Maker Faire Rome Unveils Thrilling “Padel Smash Future” Pavilion for Sports EnthusiastsPosted 2 months ago
- Make your curtains smartPosted 2 months ago
- Configuring an ESP8266 for Battery PowerPosted 2 months ago
- Creating a Telegram Bot for ESP32Posted 2 months ago
- Mini Course on BlynkPosted 3 months ago
- Creating a Unique Electronic Musical Instrument: The Sound WallPosted 3 months ago
PRO MIDI 1284P developer’s board
We develop and test applications with the Pro midi 1284P board.
Recently we have introduced and described a new prototyping board called PRO midi 1284, based on an ATmega 1284P microcontroller; after this presentation, made in a previous post, we start to work with it and we explain how to interface it in a practical and immediate way to the external world, at least in terms of hardware. For this purpose, in this article, we will propose what, in the perspective of the development platform, is its natural complement, that is a board created to allow and facilitate the study, development and debugging of applications based on it. The board in question is the PRO midi 1284P Developer’s Board shown in Fig. 1.
This board provides a housing for the “PRO midi 1284P” and a whole series of connectors to connect or host various electronic devices (also in the form of a breakout board) that allow you to develop applications that exploit the various resources of the Atmega1284P, such as analogue ports, digital ports, serial ports, I²C bus, SPI bus, etc., etc..
Not only that, for those who want to develop in an MPLAB X environment and perform both the code loading and the real debugging, there is also a JTAG connector where to connect the cheap SNAP programmer/debugger from Microchip; in this regard, we point out that the board, available from Open Electronics (also online at www.open-electronics.org) is already assembled but with the two LEDs LD1 and LD2 not soldered, but present in the package. Those who are not interested in using the MPLAB X development environment and the JTAG programmer/debugger, but intend to use the Arduino environment and programming via a serial port through the bootloader, can easily solder these LEDs (respecting the polarity, cathode on the left, anode on the right, looking at the board with the power connector on the left). On the other hand, if you want to use JTAG programming and debugging, it would be better to avoid soldering these LEDs, since they correspond to the TCK and TMS pins of the JTAG connector and could interfere with correct operation.
At the top you can clearly see the power supply section with the input (blackjack, top left of the board), where you can apply a voltage from 7V DC to 12V DC, connected first to a 5V voltage regulator and then to a 3.3V voltage regulator. These two voltage regulators provide the two respective voltages to the entire board.
Note that since several devices can be connected to the board and the power consumption can be quite high, the following limitations must be applied, otherwise some components may be damaged.
- Do not power the “PRO midi 1284P Developer’s Board” through the USB <-> serial adapter present on the “PRO midi 1284P”, but only through the black Jack. This means that, if you use Arduino IDE to program the MCU and you interface via serial with an adapter, you must connect all pins, except the +Vcc pin (so you must connect: GND, TX, RX and RST/DTR, but not +Vcc).
- Limit the total absorption (+5V together with +3.3V) to a maximum of 1,000 mA. Higher absorptions may cause the 5V regulator to overheat, resulting in possible damage.
- The power supply coming to the MCU is +5V, so all direct I/Os of the Atmega1284P will be with that voltage. There are already some connectors on the board that have level translators from 5V to 3.3V (for example for the I²C pins).
Just below the power supply section, on the left side, you can see two MOSFETs (Q1 and Q2) that have the task to act as level shifters, between +5V and +3,3V, for the signals going to the I²C bus and to some connectors already prepared for a specific use, such as the one to connect a breadboard with a BMP180 sensor (temperature, humidity and atmospheric pressure) or those to connect a 0.96″ OLED display (there are two versions of the 0.96″ OLED display and one has the power pins reversed compared to the other, so you have to be very careful in which connector to insert the display).
Another connector allows the connection of other I²C devices operating at 3.3V, in fact, it makes available the GND pin, the +3.3V pin and the two SCL and SDA pins connected to the level shifter MOSFETs.
Note that pull-up resistors for the I²C bus are already present on the board and are connected to the SDA and SCL pins of the MCU (pin 16 and 17 of the “PRO midi 1284P” board).
Continuing downwards, always on the left side of the diagram, we find some other connectors. Two of them allow the connection of I²C devices operating at 5V, while the last one at the bottom is prepared for the insertion of a breadboard with the RTC DS3231 module.
In the centre of the diagram, there is the MCU (ATmega1284P microcontroller) that is mounted on the PRO midi 1284P board and that must be inserted in the space reserved for it on the PRO midi 1284P Developer’s Board.
Continuing to examine the diagram of the board, on the right side of the MCU, proceeding from top to bottom, we find a connector marked NEOPIXEL, on which connector there are the power supplies, +5V and GND, as well as pin D0 to be used for connecting a strip of LEDs WS2812 or similar, called NeoPixel.
There is also a connector labelled ANALOG that makes available the analogue inputs A1, A2 and A3 as well as providing +5V and GND; this can be used to connect sensors that provide an analogue signal output between 0V and +5V.
In the wiring diagram we have, then, a connector marked APA102; it makes accessible the power supply line (+5V and GND), as well as the two pins D7 and D5 that can be used to control a strip of LEDs APA102 both with the management totally software of the two necessary signals (Clock and Data), and delegating this management to the SPI library with which these LEDs are controlled at high speed.
Let’s proceed with the analysis arriving at trimmer R5, connected on one side to +5V and on the other to GND, with the cursor connected to analogue input A0. This trimmer can be used to learn the operation of an analogue port, in fact, when you rotate the slider from right to left, the value returned by the function analogRead (A0) of Arduino, will vary from 0 to 1023 in a proportional way to the value of voltage present on that pin A0.
A connector marked “SPI” that makes available the MOSI (D5), SCK (D7), MISO (D6) and SS (D4) pins, in addition to the usual +5V and GND, to connect objects that talk to the microcontroller through the SPI bus. If you do not use the SPI bus, some of these pins can be used with the “Servo” library to drive servomotors. In the latter case, we recommend that you consult Table 1, which shows the correspondence between the internal timers and their contacts on the board.
The circuit has two pushbuttons named P1 and P2, complete with R/C debouncing network, connected respectively to digital inputs D15 and D14; for their use keep in mind that these buttons are close to the ground (LOW value of Arduino). In order to use them, they must be defined in the program as inputs with an active pull-up resistor, or, using the Arduino syntax, you must make the: pinMode(pin, INPUT_PULLUP) so that, when the button is not pressed, the input will have a high value (HIGH), while when the button is pressed, it will have a low value (LOW).
Just below these buttons, in the diagram, we find the JTAG connector. The use or not of such connector is a function of the development environment that is intended to use.
For those who will work in a pure Arduino environment, with the use of the IDE and programming via serial port, through the use of the external converter USB <-> Serial, and the “bootloader” present in the “PRO midi 1284P”, this JTAG connector will serve only to have available pins D18, D19, D20 and D21 in addition to the RESET pin and power supply, +5V and GND.
For those who will work in the MPLAB X environment of Microchip, this JTAG connector will make available all the signals for the use of a programmer/debugger as SNAP, that is, in addition to the power supply +5V and GND, also the signals of TCK, TDI, TMS and RESET. Note that the connector on the board is directly connectable to the aforementioned SNAP programmer, with a straight 7-conductor cable since the pin position is the same as the programmer connector.
Finally, at the bottom of the circuit under the JTAG connector, we find four light-emitting diodes, identified by the initials LD1, LD2, LD3 and LD4. As mentioned earlier, only the two LEDs LD3 and LD4 will be soldered on the board, while the remaining two LEDs, LD1 and LD2, will be supplied unsoldered. It will be up to the end-user to choose whether to leave only two LEDs on the board or to mount all four, depending on whether or not the JTAG programmer/debugger is used. In order to facilitate low-level programming, we show in Table 2 the correspondence of some of the pins used in the PRO midi 1284P Developer’s Board.
Fig. 2 shows the arrangement of the described connectors. The serigraphy on the board clearly indicates the meaning of each single pin. As it is clear from the availability of connectors both generic (SPI, I÷C, ANALOG, etc.) and specific (OLED Display, RTC DS3231, BMP180 module, etc.) the PRO midi 1284P Developer’s Board allows to use of all the resources of the Atmega1284P and to learn the use and programming of them allowing the experimentation on the use of various additional hardware components.
Fig. 3 shows the development board with the PRO midi 1284 and an RTC module installed; instead in Fig. 4 you see the board applied to an Arduino Mega (by virtue of the presence of the strips on the bottom, which match the Arduino Mega headers), just to give you an idea of the versatility of the development system that it forms with the ProMidi 1284P.
List of Components:
R1, R2, R3, R4: 4,7 Kohm
R5: Trimmer 10 Kohm MV
R6, R7: 1kohm
R8, R9, R10, R11, R12: 470 ohms
C1, C7, C9: 100 F 35 VL Electrolytic
C2, C5, C6, C8: 100 nF Ceramic
C3, C4: 100 nF 100 VL polyester
LD1: 5 mm LED green (see text)
LD2 LED 5 mm yellow (see text)
LD3 LED 5 mm red
LD4 LED 5 mm green
P1, P2: Microswitch
Q1, Q2: BS170
BMP180: BMP180 module
OLED1: OLED display 0.96″ I2C
LCD: I2C LCD display
DS3231: DS3231 RTC Module
SERVO: Servomotor 6V
NEOPIXEL: LED WS2812B
APA102: LED APA102
– Strip female 3-way (1 pc.)
– Strip female 4 ways (7 pcs.)
– Strip female 5 ways (1 pc.)
– Strip female 6 ways (2 pcs.)
– Strip female 7 ways (1 pc.)
– Strip female 20 ways (2 pcs)
– Strip Arduino 8 ways (5 pcs.)
– Strip Arduino 10 ways (1 pc.)
– Arduino strip 2×18 ways (1 pc.)
– Power supply plug
– PCB S1393 (102×73 mm)