Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/sphinx/source/projects/power/eval-powrms.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.. include:: ../../../../../projects/eval-powrms/README.rst
4 changes: 2 additions & 2 deletions drivers/display/ssd_1306/ssd_1306.c
Original file line number Diff line number Diff line change
Expand Up @@ -180,13 +180,13 @@ int32_t ssd_1306_init(struct display_dev *device)
return -1;

no_os_udelay(3U);
command[0] = 0xA1;
command[0] = SSD1306_SEG_REMAP_CMD;
ret = ssd1306_buffer_transmit(extra, command, 1U, SSD1306_CMD);
if (ret != 0)
return -1;

no_os_udelay(3U);
command[0] = 0xC8;
command[0] = SSD1306_COM_SCAN_CMD;
ret = ssd1306_buffer_transmit(extra, command, 1U, SSD1306_CMD);
if (ret != 0)
return -1;
Expand Down
20 changes: 20 additions & 0 deletions drivers/display/ssd_1306/ssd_1306.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,27 @@ enum transmit_type {
SSD1306_DATA
};

#ifndef SSD1306_I2C_ADDR
#define SSD1306_I2C_ADDR 0x3C
#endif

/*
* Build-time display orientation, in degrees. Supported values are 0 and 180
* (the SSD1306 can only mirror the segment/COM scan direction in hardware).
*/
#ifndef SSD1306_ROTATION
#define SSD1306_ROTATION 0
#endif

/*
* Command-byte builders derived from SSD1306_ROTATION. A 180-degree rotation
* mirrors both the segment remap (0xA0) and the COM output scan direction
* (0xC0).
*/
#define SSD1306_SEG_REMAP_CMD \
(0xA0U | (((SSD1306_ROTATION) == 180) ? 0x00U : 0x01U))
#define SSD1306_COM_SCAN_CMD \
(0xC0U | (((SSD1306_ROTATION) == 180) ? 0x00U : 0x08U))

/**
* @struct ssd_1306_extra
Expand Down
17 changes: 17 additions & 0 deletions projects/eval-powrms/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
LIBRARIES += lvgl
IIOD=y

PLATFORM=maxim
TARGET=max32662

include ../../tools/scripts/generic_variables.mk

HEAP_SIZE=0x90000
STACK_SIZE=0x10000

include src.mk

CFLAGS += -Os -ffunction-sections -fdata-sections -fno-strict-aliasing
LDFLAGS += -Wl,--gc-sections

include ../../tools/scripts/generic.mk
Loading
Loading